Commit 1a0459e1 authored by Jonas Waeber's avatar Jonas Waeber
Browse files

Deployment updates

- Update helm chart definition
- Update memobase repo path
- Update Dockerfile
- Add test for failed csv import
parent 2ae997f8
Pipeline #11443 passed with stages
in 4 minutes and 47 seconds
......@@ -64,7 +64,7 @@ test-chart:
tags:
- mbr
script:
- helm lint chart/
- helm lint helm-charts/
publish-chart:
stage: publish
......@@ -75,7 +75,7 @@ publish-chart:
- export HELM_EXPERIMENTAL_OCI=1
- helm registry login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" "$CI_REGISTRY"
- ./insert_chart_versions.sh
- helm chart save chart/ "$CI_REGISTRY/$CI_PROJECT_PATH:$CI_COMMIT_TAG-chart"
- helm chart save helm-charts/ "$CI_REGISTRY/$CI_PROJECT_PATH:$CI_COMMIT_TAG-chart"
- helm chart push "$CI_REGISTRY/$CI_PROJECT_PATH:$CI_COMMIT_TAG-chart"
- helm registry logout "$CI_REGISTRY"
only:
......
FROM openjdk:8
FROM gradle:6.3-jdk8
ADD . /
WORKDIR /
RUN ./gradlew -q --no-scan --no-daemon --no-build-cache distTar
RUN gradle --no-daemon --no-scan --no-build-cache distTar
RUN cd /build/distributions && tar xf app.tar
FROM openjdk:8-jre-alpine
......
......@@ -21,7 +21,7 @@ targetCompatibility = 1.8
repositories {
jcenter()
maven {
url "https://dl.bintray.com/jonas-waeber/memobase"
url "https://dl.bintray.com/memoriav/memobase"
}
}
......
#!/usr/bin/env bash
echo Creating release: $1
sed -i "s/version: 0.0.0/version: $CI_COMMIT_TAG/g" ./chart/Chart.yaml
sed -i "s/appVersion: 0.0.0/appVersion: $CI_COMMIT_TAG/g" ./chart/Chart.yaml
sed -i "s/tag: \"latest\"/tag: $CI_COMMIT_TAG/g" ./chart/values.yaml
\ No newline at end of file
sed -i "s/version: 0.0.0/version: $CI_COMMIT_TAG/g" ./helm-charts/Chart.yaml
sed -i "s/appVersion: 0.0.0/appVersion: $CI_COMMIT_TAG/g" ./helm-charts/Chart.yaml
sed -i "s/tag: \"latest\"/tag: $CI_COMMIT_TAG/g" ./helm-charts/values.yaml
\ No newline at end of file
......@@ -49,7 +49,8 @@ class Tests {
Pair("/memobase/test_record_set_2", "bauGAZH_metadaten.csv"),
Pair("/memobase/test_record_set_3", "invalid.csv"),
Pair("/memobase/test_record_set_4", "file.txt"),
Pair("/memobase/test_record_set_5", "20190906_Brandt_Metadaten.xlsx")
Pair("/memobase/test_record_set_5", "20190906_Brandt_Metadaten.xlsx"),
Pair("/memobase/test_record_set_6", "Export_Bilder_der_Arbeit_8.csv")
)
for (pair in files) {
......@@ -193,6 +194,23 @@ class Tests {
status = "SUCCESS",
message = "Successfully validated 1 files."
)
),
TestParams(
"test6.yml",
expectedKey = "Export_Bilder_der_Arbeit_8.csv",
expectedValue = "{\"format\" : \"ERROR\", \"path\" : \"/memobase/test_record_set_6/Export_Bilder_der_Arbeit_8.csv\"}",
expectedReportValue = Klaxon().toJsonString(
Report(
id = "Export_Bilder_der_Arbeit_8.csv",
status = "FAILURE",
message = "CSV ERROR: Fields num seems to be 1 on each row, but on 2th csv row, fields num is 5. for file /memobase/test_record_set_6/Export_Bilder_der_Arbeit_8.csv."
)
),
expectedProcessReport = Report(
id = "text-file-validation",
status = "FAILURE",
message = "Failed to validate 1 of 1 files."
)
)
)
}
This diff is collapsed.
id: jobXYZ
sftp:
host: localhost
port: 22000
user: user
password: password
app:
directory: /memobase/test_record_set_6
kafka:
producer:
bootstrap.servers: localhost:12345
client.id: sftp-reader-p1-j1
topic:
out: sftp-reader-p1-j1
process: p1-reporting
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment