Skip to content

Commit

Permalink
Merge branch 'master' into sdk-launcher
Browse files Browse the repository at this point in the history
  • Loading branch information
hongye-sun committed Feb 1, 2019
2 parents cce2f63 + ef851e8 commit 8c58af2
Show file tree
Hide file tree
Showing 26 changed files with 12 additions and 2,849 deletions.
43 changes: 1 addition & 42 deletions .cloudbuild.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ steps:
id: 'copyPythonSDKToLatest'
waitFor: ['preparePythonSDK']

# Build the pipeline system images and bootstrapper
# Build the pipeline system images
- name: 'debian'
entrypoint: '/bin/bash'
args: ['-c', 'sed -i -e "s/ARG DATE/ENV DATE \"$(date -u)\"/" /workspace/frontend/Dockerfile']
Expand Down Expand Up @@ -57,46 +57,6 @@ steps:
args: ['build', '-t', 'gcr.io/$PROJECT_ID/persistenceagent:$COMMIT_SHA', '-f',
'/workspace/backend/Dockerfile.persistenceagent', '/workspace']
id: 'buildPersistenceAgent'
- name: 'gcr.io/cloud-builders/docker'
args: ['build', '--build-arg', 'RELEASE_VERSION=$COMMIT_SHA',
'--build-arg', 'API_SERVER_IMAGE=gcr.io/$PROJECT_ID/api-server:$COMMIT_SHA',
'--build-arg', 'SCHEDULED_WORKFLOW_IMAGE=gcr.io/$PROJECT_ID/scheduledworkflow:$COMMIT_SHA',
'--build-arg', 'PERSISTENCE_AGENT_IMAGE=gcr.io/$PROJECT_ID/persistenceagent:$COMMIT_SHA',
'--build-arg', 'UI_IMAGE=gcr.io/$PROJECT_ID/frontend:$COMMIT_SHA',
'-t', 'gcr.io/$PROJECT_ID/bootstrapper:$COMMIT_SHA', '/workspace/pipeline']
id: 'buildBootstrapper'
- name: 'debian'
entrypoint: '/bin/bash'
args: ['-c', 'sed -i -e "s/gcr.io\/ml-pipeline\/bootstrapper:\([a-zA-Z0-9_.-]\)\+/gcr.io\/$PROJECT_ID\/bootstrapper:$COMMIT_SHA/g" /workspace/bootstrapper.yaml']
id: 'prepareBootstrapperYAML'
- name: 'gcr.io/cloud-builders/gsutil'
args: ['cp', '/workspace/bootstrapper.yaml', 'gs://$PROJECT_ID/builds/$COMMIT_SHA/bootstrapper.yaml']
id: 'copyBootstrapperYAML'
waitFor: ['prepareBootstrapperYAML']
- name: 'gcr.io/cloud-builders/gsutil'
args: ['cp', '/workspace/bootstrapper.yaml', 'gs://$PROJECT_ID/builds/latest/bootstrapper.yaml']
id: 'copyBootstrapperYAMLToLatest'
waitFor: ['prepareBootstrapperYAML']

# Copy the uninstaller config
- name: 'debian'
entrypoint: '/bin/bash'
args: ['-c', 'sed -i -e "s/gcr.io\/ml-pipeline\/bootstrapper:\([a-zA-Z0-9_.-]\)\+/gcr.io\/$PROJECT_ID\/bootstrapper:$COMMIT_SHA/g" /workspace/uninstaller.yaml']
id: 'prepareUninstallerYAML'
- name: 'debian'
entrypoint: '/bin/bash'
args: ['-c', 'sed -i -e "s/args: \[/args: [\n \"--api_image\", \"gcr.io\/$PROJECT_ID\/api-server:$COMMIT_SHA\",\n \"--scheduled_workflow_image\", \"gcr.io\/$PROJECT_ID\/scheduledworkflow:$COMMIT_SHA\",\n \"--persistence_agent_image\", \"gcr.io\/$PROJECT_ID\/persistenceagent:$COMMIT_SHA\",\n \"--ui_image\", \"gcr.io\/$PROJECT_ID\/frontend:$COMMIT_SHA\"\n/g" /workspace/uninstaller.yaml']
id: 'updateUninstallerYAMLImage'
waitFor: ['prepareUninstallerYAML']
- name: 'gcr.io/cloud-builders/gsutil'
args: ['cp', '/workspace/uninstaller.yaml', 'gs://$PROJECT_ID/builds/$COMMIT_SHA/uninstaller.yaml']
id: 'copyUninstallerYAML'
waitFor: ['updateUninstallerYAMLImage']
- name: 'gcr.io/cloud-builders/gsutil'
args: ['cp', '/workspace/uninstaller.yaml', 'gs://$PROJECT_ID/builds/latest/uninstaller.yaml']
id: 'copyUninstallerYAMLToLatest'
waitFor: ['prepareUninstallerYAML']


# Build the Dataflow-based pipeline component images
- name: 'gcr.io/cloud-builders/docker'
Expand Down Expand Up @@ -197,7 +157,6 @@ images:
- 'gcr.io/$PROJECT_ID/scheduledworkflow:$COMMIT_SHA'
- 'gcr.io/$PROJECT_ID/persistenceagent:$COMMIT_SHA'
- 'gcr.io/$PROJECT_ID/viewer-crd-controller:$COMMIT_SHA'
- 'gcr.io/$PROJECT_ID/bootstrapper:$COMMIT_SHA'

# Images for the Dataflow-based pipeline components
- 'gcr.io/$PROJECT_ID/ml-pipeline-dataflow-tf-predict:$COMMIT_SHA'
Expand Down
43 changes: 0 additions & 43 deletions .release.cloudbuild.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,47 +62,6 @@ steps:
id: 'tagPersistenceagentCommitSHA'
waitFor: ['pullPersistenceagent']

- name: 'gcr.io/cloud-builders/docker'
args: ['pull', 'gcr.io/$PROJECT_ID/bootstrapper:$COMMIT_SHA']
id: 'pullBootstrapper'
- name: 'gcr.io/cloud-builders/docker'
entrypoint: '/bin/bash'
args: ['-c', 'printf "FROM gcr.io/$PROJECT_ID/bootstrapper:$COMMIT_SHA\nENV API_SERVER_IMAGE gcr.io/ml-pipeline/api-server:$COMMIT_SHA\nENV SCHEDULED_WORKFLOW_IMAGE gcr.io/ml-pipeline/scheduledworkflow:$COMMIT_SHA\nENV PERSISTENCE_AGENT_IMAGE gcr.io/ml-pipeline/persistenceagent:$COMMIT_SHA\nENV UI_IMAGE gcr.io/ml-pipeline/frontend:$COMMIT_SHA" > Dockerfile; docker build -t gcr.io/ml-pipeline/bootstrapper:$COMMIT_SHA .']
id: 'buildBootstrapper'
waitFor: ['pullBootstrapper']
- name: 'gcr.io/cloud-builders/docker'
args: ['tag', 'gcr.io/ml-pipeline/bootstrapper:$COMMIT_SHA', 'gcr.io/ml-pipeline/bootstrapper:$TAG_NAME']
id: 'tagBootstrapperVersionNumber'
waitFor: ['buildBootstrapper']

# Copy the bootstrapper config
- name: 'debian'
entrypoint: '/bin/bash'
args: ['-c', 'sed -i -e "s/gcr.io\/ml-pipeline\/bootstrapper:\([a-zA-Z0-9_.-]\)\+/gcr.io\/ml-pipeline\/bootstrapper:$TAG_NAME/g" /workspace/bootstrapper.yaml']
id: 'prepareBootstrapperYAML'
- name: 'gcr.io/cloud-builders/gsutil'
args: ['cp', '/workspace/bootstrapper.yaml', 'gs://ml-pipeline/release/$TAG_NAME/bootstrapper.yaml']
id: 'copyBootstrapperYAML'
waitFor: ['prepareBootstrapperYAML']
- name: 'gcr.io/cloud-builders/gsutil'
args: ['cp', '/workspace/bootstrapper.yaml', 'gs://ml-pipeline/release/latest/bootstrapper.yaml']
id: 'copyBootstrapperYAMLToLatest'
waitFor: ['prepareBootstrapperYAML']

# Copy the uninstaller config
- name: 'debian'
entrypoint: '/bin/bash'
args: ['-c', 'sed -i -e "s/gcr.io\/ml-pipeline\/bootstrapper:\([a-zA-Z0-9_.-]\)\+/gcr.io\/ml-pipeline\/bootstrapper:$TAG_NAME/g" /workspace/uninstaller.yaml']
id: 'prepareUninstallerYAML'
- name: 'gcr.io/cloud-builders/gsutil'
args: ['cp', '/workspace/uninstaller.yaml', 'gs://ml-pipeline/release/$TAG_NAME/uninstaller.yaml']
id: 'copyUninstallerYAML'
waitFor: ['prepareUninstallerYAML']
- name: 'gcr.io/cloud-builders/gsutil'
args: ['cp', '/workspace/uninstaller.yaml', 'gs://ml-pipeline/release/latest/uninstaller.yaml']
id: 'copyUninstallerYAMLToLatest'
waitFor: ['prepareUninstallerYAML']

# Copy the Python SDK
- name: 'gcr.io/cloud-builders/gsutil'
args: ['cp', 'gs://$PROJECT_ID/builds/$COMMIT_SHA/kfp.tar.gz', '/workspace/']
Expand Down Expand Up @@ -140,7 +99,5 @@ images:
- 'gcr.io/ml-pipeline/scheduledworkflow:$COMMIT_SHA'
- 'gcr.io/ml-pipeline/persistenceagent:$TAG_NAME'
- 'gcr.io/ml-pipeline/persistenceagent:$COMMIT_SHA'
- 'gcr.io/ml-pipeline/bootstrapper:$TAG_NAME'
- 'gcr.io/ml-pipeline/bootstrapper:$COMMIT_SHA'

timeout: '1200s'
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,4 +60,4 @@ matrix:

# Component SDK tests
- cd $TRAVIS_BUILD_DIR/component_sdk/python
- ./run_test.sh
- ./run_test.sh
11 changes: 8 additions & 3 deletions backend/Dockerfile.viewercontroller
Original file line number Diff line number Diff line change
@@ -1,17 +1,22 @@
FROM golang:alpine as builder

RUN apk --no-cache add curl git dep
RUN apk update && apk upgrade
RUN apk add --no-cache git gcc musl-dev

WORKDIR /go/src/github.com/kubeflow/pipelines
WORKDIR /src/github.com/kubeflow/pipelines
COPY . .

RUN go mod vendor
RUN go build -o /bin/controller backend/src/crd/controller/viewer/*.go

FROM alpine
WORKDIR /src
COPY --from=builder /src/github.com/kubeflow/pipelines/vendor vendor

WORKDIR /bin

COPY --from=builder /bin/controller /bin/controller
COPY --from=builder /go/src/github.com/kubeflow/pipelines/third_party/license.txt /bin/license.txt
COPY --from=builder /src/github.com/kubeflow/pipelines/third_party/license.txt /bin/license.txt
RUN chmod +x /bin/controller

CMD /bin/controller -alsologtostderr=true
76 changes: 0 additions & 76 deletions bootstrapper.yaml

This file was deleted.

2 changes: 1 addition & 1 deletion component_sdk/python/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
kubernetes
fire
fire
44 changes: 0 additions & 44 deletions pipeline/Dockerfile

This file was deleted.

6 changes: 0 additions & 6 deletions pipeline/OWNERS

This file was deleted.

44 changes: 0 additions & 44 deletions pipeline/bootstrapper.sh

This file was deleted.

Loading

0 comments on commit 8c58af2

Please sign in to comment.