From 5bead9db964d37647169df71279e57d3dbc20509 Mon Sep 17 00:00:00 2001 From: Piotr Marcinkiewicz Date: Tue, 23 Mar 2021 11:51:20 +0100 Subject: Move local dev files and add Changelog Issue-ID: SDC-3185 Signed-off-by: Piotr Marcinkiewicz Change-Id: Ic5d8b89dc0e69721c47b5fdec459bbd70e48f746 --- Changelog.md | 9 +++++ Dockerfile-local | 21 ---------- README.md | 2 +- charts/correct-apiVersion-v1.tgz | Bin 393 -> 0 bytes charts/correct-apiVersion-v2.tgz | Bin 651 -> 0 bytes charts/error-bad-chart-yaml.tar.gz | Bin 209 -> 0 bytes charts/one-lint-one-render-error-apiVersion-v1.tgz | Bin 413 -> 0 bytes charts/one-lint-one-render-error-apiVersion-v2.tgz | Bin 668 -> 0 bytes charts/one-lint-warning-apiVersion-v2.tgz | Bin 738 -> 0 bytes charts/two-lint-warnings-apiVersion-v1.tgz | Bin 311 -> 0 bytes deployment.yaml | 44 --------------------- dev-resources/Dockerfile-local | 21 ++++++++++ dev-resources/deployment.yaml | 44 +++++++++++++++++++++ .../sample-charts/correct-apiVersion-v1.tgz | Bin 0 -> 393 bytes .../sample-charts/correct-apiVersion-v2.tgz | Bin 0 -> 651 bytes .../sample-charts/error-bad-chart-yaml.tar.gz | Bin 0 -> 209 bytes .../one-lint-one-render-error-apiVersion-v1.tgz | Bin 0 -> 413 bytes .../one-lint-one-render-error-apiVersion-v2.tgz | Bin 0 -> 668 bytes .../one-lint-warning-apiVersion-v2.tgz | Bin 0 -> 738 bytes .../two-lint-warnings-apiVersion-v1.tgz | Bin 0 -> 311 bytes pom.xml | 2 +- 21 files changed, 76 insertions(+), 67 deletions(-) create mode 100644 Changelog.md delete mode 100644 Dockerfile-local delete mode 100644 charts/correct-apiVersion-v1.tgz delete mode 100644 charts/correct-apiVersion-v2.tgz delete mode 100644 charts/error-bad-chart-yaml.tar.gz delete mode 100644 charts/one-lint-one-render-error-apiVersion-v1.tgz delete mode 100644 charts/one-lint-one-render-error-apiVersion-v2.tgz delete mode 100644 charts/one-lint-warning-apiVersion-v2.tgz delete mode 100644 charts/two-lint-warnings-apiVersion-v1.tgz delete mode 100644 deployment.yaml create mode 100644 dev-resources/Dockerfile-local create mode 100644 dev-resources/deployment.yaml create mode 100644 dev-resources/sample-charts/correct-apiVersion-v1.tgz create mode 100644 dev-resources/sample-charts/correct-apiVersion-v2.tgz create mode 100644 dev-resources/sample-charts/error-bad-chart-yaml.tar.gz create mode 100644 dev-resources/sample-charts/one-lint-one-render-error-apiVersion-v1.tgz create mode 100644 dev-resources/sample-charts/one-lint-one-render-error-apiVersion-v2.tgz create mode 100644 dev-resources/sample-charts/one-lint-warning-apiVersion-v2.tgz create mode 100644 dev-resources/sample-charts/two-lint-warnings-apiVersion-v1.tgz diff --git a/Changelog.md b/Changelog.md new file mode 100644 index 0000000..d2f18e1 --- /dev/null +++ b/Changelog.md @@ -0,0 +1,9 @@ +# Change Log +All notable changes to this project will be documented in this file. + +The format is based on [Keep a Changelog](http://keepachangelog.com/) +and this project adheres to [Semantic Versioning](http://semver.org/). + +## [0.0.1] - 23/03/2021 + +- Init Helm client validator project, which is dedicated to be used during Helm packages validation in time of VSP creation \ No newline at end of file diff --git a/Dockerfile-local b/Dockerfile-local deleted file mode 100644 index b1b378a..0000000 --- a/Dockerfile-local +++ /dev/null @@ -1,21 +0,0 @@ -FROM nexus3.onap.org:10001/onap/integration-java11:8.0.0 - -ARG VERSION=${version} -ENV HELM_SUPPORTED_VERSIONS=${HELM_SUPPORTED_VERSIONS} - -USER root -RUN adduser -G onap -D validator - -RUN apk add --no-cache bash vim curl wget - -#Installing Helm -COPY scripts/helm_versions/* /usr/local/bin/ - -RUN mkdir /charts -RUN chown -R validator:onap /charts - -USER validator:onap - -COPY target/sdc-helm-validator-${VERSION}.jar ./opt/helmvalidator/helmvalidator.jar - -ENTRYPOINT ["java","-XX:+UseParallelGC","-XX:MinRAMPercentage=50","-XX:MaxRAMPercentage=50","-XX:MinHeapFreeRatio=10","-XX:MaxHeapFreeRatio=20","-jar","./opt/helmvalidator/helmvalidator.jar"] diff --git a/README.md b/README.md index bb506c0..a8c469c 100644 --- a/README.md +++ b/README.md @@ -31,7 +31,7 @@ make run-docker ``` Example charts are located in the following directory: ``` -./charts +./dev-resources/sample-charts ``` ## Available endpoints diff --git a/charts/correct-apiVersion-v1.tgz b/charts/correct-apiVersion-v1.tgz deleted file mode 100644 index 9782071..0000000 Binary files a/charts/correct-apiVersion-v1.tgz and /dev/null differ diff --git a/charts/correct-apiVersion-v2.tgz b/charts/correct-apiVersion-v2.tgz deleted file mode 100644 index a1a99ba..0000000 Binary files a/charts/correct-apiVersion-v2.tgz and /dev/null differ diff --git a/charts/error-bad-chart-yaml.tar.gz b/charts/error-bad-chart-yaml.tar.gz deleted file mode 100644 index b7ce4e5..0000000 Binary files a/charts/error-bad-chart-yaml.tar.gz and /dev/null differ diff --git a/charts/one-lint-one-render-error-apiVersion-v1.tgz b/charts/one-lint-one-render-error-apiVersion-v1.tgz deleted file mode 100644 index d17c118..0000000 Binary files a/charts/one-lint-one-render-error-apiVersion-v1.tgz and /dev/null differ diff --git a/charts/one-lint-one-render-error-apiVersion-v2.tgz b/charts/one-lint-one-render-error-apiVersion-v2.tgz deleted file mode 100644 index 874dd3c..0000000 Binary files a/charts/one-lint-one-render-error-apiVersion-v2.tgz and /dev/null differ diff --git a/charts/one-lint-warning-apiVersion-v2.tgz b/charts/one-lint-warning-apiVersion-v2.tgz deleted file mode 100644 index 51f4dd1..0000000 Binary files a/charts/one-lint-warning-apiVersion-v2.tgz and /dev/null differ diff --git a/charts/two-lint-warnings-apiVersion-v1.tgz b/charts/two-lint-warnings-apiVersion-v1.tgz deleted file mode 100644 index 54422c9..0000000 Binary files a/charts/two-lint-warnings-apiVersion-v1.tgz and /dev/null differ diff --git a/deployment.yaml b/deployment.yaml deleted file mode 100644 index 43b6f15..0000000 --- a/deployment.yaml +++ /dev/null @@ -1,44 +0,0 @@ -apiVersion: apps/v1 -kind: Deployment -metadata: - name: helm-client-validator - namespace: onap - labels: - app: helm-client-validator -spec: - replicas: 1 - selector: - matchLabels: - app: helm-client-validator - template: - metadata: - labels: - app: helm-client-validator - spec: - containers: - - name: helm-client-validator - imagePullPolicy: IfNotPresent - image: onap-dev-local.esisoj70.emea.nsn-net.net/towrobel/helm-client-validator:1.5.0 - resources: - requests: - memory: "256Mi" - limits: - memory: "256Mi" - - ---- -apiVersion: v1 -kind: Service -metadata: - name: helm-client-validator-service - namespace: onap - labels: - app: helm-client-validator -spec: - selector: - app: helm-client-validator - type: NodePort - ports: - - port: 8244 - targetPort: 8080 - nodePort: 32244 diff --git a/dev-resources/Dockerfile-local b/dev-resources/Dockerfile-local new file mode 100644 index 0000000..b1b378a --- /dev/null +++ b/dev-resources/Dockerfile-local @@ -0,0 +1,21 @@ +FROM nexus3.onap.org:10001/onap/integration-java11:8.0.0 + +ARG VERSION=${version} +ENV HELM_SUPPORTED_VERSIONS=${HELM_SUPPORTED_VERSIONS} + +USER root +RUN adduser -G onap -D validator + +RUN apk add --no-cache bash vim curl wget + +#Installing Helm +COPY scripts/helm_versions/* /usr/local/bin/ + +RUN mkdir /charts +RUN chown -R validator:onap /charts + +USER validator:onap + +COPY target/sdc-helm-validator-${VERSION}.jar ./opt/helmvalidator/helmvalidator.jar + +ENTRYPOINT ["java","-XX:+UseParallelGC","-XX:MinRAMPercentage=50","-XX:MaxRAMPercentage=50","-XX:MinHeapFreeRatio=10","-XX:MaxHeapFreeRatio=20","-jar","./opt/helmvalidator/helmvalidator.jar"] diff --git a/dev-resources/deployment.yaml b/dev-resources/deployment.yaml new file mode 100644 index 0000000..6cc52fe --- /dev/null +++ b/dev-resources/deployment.yaml @@ -0,0 +1,44 @@ +apiVersion: apps/v1 +kind: Deployment +metadata: + name: helm-client-validator + namespace: onap + labels: + app: helm-client-validator +spec: + replicas: 1 + selector: + matchLabels: + app: helm-client-validator + template: + metadata: + labels: + app: helm-client-validator + spec: + containers: + - name: helm-client-validator + imagePullPolicy: IfNotPresent + image: onap/org.onap.sdc.sdc-helm-validator:latest + resources: + requests: + memory: "256Mi" + limits: + memory: "256Mi" + + +--- +apiVersion: v1 +kind: Service +metadata: + name: helm-client-validator-service + namespace: onap + labels: + app: helm-client-validator +spec: + selector: + app: helm-client-validator + type: NodePort + ports: + - port: 8244 + targetPort: 8080 + nodePort: 32244 diff --git a/dev-resources/sample-charts/correct-apiVersion-v1.tgz b/dev-resources/sample-charts/correct-apiVersion-v1.tgz new file mode 100644 index 0000000..9782071 Binary files /dev/null and b/dev-resources/sample-charts/correct-apiVersion-v1.tgz differ diff --git a/dev-resources/sample-charts/correct-apiVersion-v2.tgz b/dev-resources/sample-charts/correct-apiVersion-v2.tgz new file mode 100644 index 0000000..a1a99ba Binary files /dev/null and b/dev-resources/sample-charts/correct-apiVersion-v2.tgz differ diff --git a/dev-resources/sample-charts/error-bad-chart-yaml.tar.gz b/dev-resources/sample-charts/error-bad-chart-yaml.tar.gz new file mode 100644 index 0000000..b7ce4e5 Binary files /dev/null and b/dev-resources/sample-charts/error-bad-chart-yaml.tar.gz differ diff --git a/dev-resources/sample-charts/one-lint-one-render-error-apiVersion-v1.tgz b/dev-resources/sample-charts/one-lint-one-render-error-apiVersion-v1.tgz new file mode 100644 index 0000000..d17c118 Binary files /dev/null and b/dev-resources/sample-charts/one-lint-one-render-error-apiVersion-v1.tgz differ diff --git a/dev-resources/sample-charts/one-lint-one-render-error-apiVersion-v2.tgz b/dev-resources/sample-charts/one-lint-one-render-error-apiVersion-v2.tgz new file mode 100644 index 0000000..874dd3c Binary files /dev/null and b/dev-resources/sample-charts/one-lint-one-render-error-apiVersion-v2.tgz differ diff --git a/dev-resources/sample-charts/one-lint-warning-apiVersion-v2.tgz b/dev-resources/sample-charts/one-lint-warning-apiVersion-v2.tgz new file mode 100644 index 0000000..51f4dd1 Binary files /dev/null and b/dev-resources/sample-charts/one-lint-warning-apiVersion-v2.tgz differ diff --git a/dev-resources/sample-charts/two-lint-warnings-apiVersion-v1.tgz b/dev-resources/sample-charts/two-lint-warnings-apiVersion-v1.tgz new file mode 100644 index 0000000..54422c9 Binary files /dev/null and b/dev-resources/sample-charts/two-lint-warnings-apiVersion-v1.tgz differ diff --git a/pom.xml b/pom.xml index 346f07d..e67db84 100644 --- a/pom.xml +++ b/pom.xml @@ -150,7 +150,7 @@ false - Dockerfile-local + dev-resources/Dockerfile-local -- cgit 1.2.3-korg