Skip to content

Commit

Permalink
Fix env -> envs transform when pulling kfp upstream manifest
Browse files Browse the repository at this point in the history
  • Loading branch information
Bobgy committed Jun 18, 2020
1 parent b9b00e6 commit a842b7b
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 1 deletion.
16 changes: 15 additions & 1 deletion hack/pull_kfp_upstream.sh
Original file line number Diff line number Diff line change
@@ -1,9 +1,23 @@
#!/usr/bin/env bash

export PIPELINES_SRC_REPO=https://github.com/kubeflow/pipelines.git
# Usage:
# This script should be run from kubeflow/manifest repo's root:
# ./hack/pull_kfp_upstream.sh

set -ex

# Please edit the following version before running the script to pull new
# pipelines version.
export PIPELINES_VERSION=1.0.0-rc.2
export PIPELINES_SRC_REPO=https://github.com/kubeflow/pipelines.git
# Pulling for the first time
# kpt pkg get $PIPELINES_SRC_REPO/manifests/kustomize@$PIPELINES_VERSION pipeline/upstream

# Updates
kpt pkg update pipeline/upstream/@$PIPELINES_VERSION --strategy force-delete-replace
# Before kubeflow/pipelines/manifests/kustomize supports kustomize v3.5+, we
# have to convert kustomization.yaml env to envs syntax, so that it is compatible
# with latest kustomize used in kubeflow/manifests.
# ref: https://github.com/kubeflow/manifests/pull/1248#issuecomment-645739641
find pipeline/upstream -name 'kustomization.yaml' -exec \
sed -i.bak 's#env: \(.*\)#envs: ["\1"]#g' {} +
2 changes: 2 additions & 0 deletions pipeline/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# sed backup files
*.bak

0 comments on commit a842b7b

Please sign in to comment.