Skip to content

Commit c12198f

Browse files
committed
Fix artifact passing for recurring runs.
Due to a bug in upstream code, scheduled run pipelines are not getting the k8s annotations on the tekton pods that contain the artifact endpoint and bucket info. As such artifact passing works in regular (non-scheduled) runs but not for recurring runs, failing at the copy-artifacts container step. Hardcoding these values within the artifact script serves as a sufficient work around for this problem. Signed-off-by: Humair Khan <[email protected]>
1 parent 2851682 commit c12198f

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

config/internal/apiserver/artifact_script.yaml.tmpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ data:
55
push_artifact() {
66
if [ -f "$2" ]; then
77
tar -cvzf $1.tgz $2
8-
aws s3 --endpoint ${ARTIFACT_ENDPOINT} cp $1.tgz s3://$ARTIFACT_BUCKET/artifacts/$PIPELINERUN/$PIPELINETASK/$1.tgz
8+
aws s3 --endpoint {{.ObjectStorageConnection.Endpoint}} cp $1.tgz s3://{{.ObjectStorageConnection.Bucket}}/artifacts/$PIPELINERUN/$PIPELINETASK/$1.tgz
99
else
1010
echo "$2 file does not exist. Skip artifact tracking for $1"
1111
fi

controllers/testdata/declarative/case_0/expected/created/configmap_artifact_script.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ data:
55
push_artifact() {
66
if [ -f "$2" ]; then
77
tar -cvzf $1.tgz $2
8-
aws s3 --endpoint ${ARTIFACT_ENDPOINT} cp $1.tgz s3://$ARTIFACT_BUCKET/artifacts/$PIPELINERUN/$PIPELINETASK/$1.tgz
8+
aws s3 --endpoint http://minio-testdsp0.default.svc.cluster.local:9000 cp $1.tgz s3://mlpipeline/artifacts/$PIPELINERUN/$PIPELINETASK/$1.tgz
99
else
1010
echo "$2 file does not exist. Skip artifact tracking for $1"
1111
fi

controllers/testdata/declarative/case_2/expected/created/configmap_artifact_script.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ data:
55
push_artifact() {
66
if [ -f "$2" ]; then
77
tar -cvzf $1.tgz $2
8-
aws s3 --endpoint ${ARTIFACT_ENDPOINT} cp $1.tgz s3://$ARTIFACT_BUCKET/artifacts/$PIPELINERUN/$PIPELINETASK/$1.tgz
8+
aws s3 --endpoint http://minio-testdsp2.default.svc.cluster.local:9000 cp $1.tgz s3://mlpipeline/artifacts/$PIPELINERUN/$PIPELINETASK/$1.tgz
99
else
1010
echo "$2 file does not exist. Skip artifact tracking for $1"
1111
fi

controllers/testdata/declarative/case_3/expected/not_created/configmap_artifact_script.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ data:
55
push_artifact() {
66
if [ -f "$2" ]; then
77
tar -cvzf $1.tgz $2
8-
aws s3 --endpoint ${ARTIFACT_ENDPOINT} cp $1.tgz s3://$ARTIFACT_BUCKET/artifacts/$PIPELINERUN/$PIPELINETASK/$1.tgz
8+
aws s3 --endpoint http://minio-testdsp3.default.svc.cluster.local:9000 cp $1.tgz s3://mlpipeline/artifacts/$PIPELINERUN/$PIPELINETASK/$1.tgz
99
else
1010
echo "$2 file does not exist. Skip artifact tracking for $1"
1111
fi

0 commit comments

Comments
 (0)