-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(backend): isolate artifacts per namespace/profile/user using only one bucket #7725
Open
juliusvonkohout
wants to merge
28
commits into
kubeflow:master
Choose a base branch
from
juliusvonkohout:patch-22
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
28 commits
Select commit
Hold shift + click to select a range
c9c3a9e
Seperate artifacts per namespace/profile/user
juliusvonkohout 1218655
sync.py
juliusvonkohout fb03d90
Create Dockerfile.pipelines-profile-controller
juliusvonkohout 8ca1101
Merge branch 'kubeflow:master' into patch-22
juliusvonkohout e8a7122
Update deployment.yaml
juliusvonkohout e99ab6a
Update sync.py
juliusvonkohout b681570
more secure iam policy
juliusvonkohout 27c6795
enable lifecycle policy
juliusvonkohout f1ab99b
Version 9 is more compatible
juliusvonkohout 9f3efc4
typographical error
juliusvonkohout 8b15871
Update sync.py
juliusvonkohout 8e15e56
Update Dockerfile.pipelines-profile-controller
juliusvonkohout eff65ea
Merge branch 'kubeflow:master' into patch-22
juliusvonkohout 1c292a9
Update composite-controller.yaml
juliusvonkohout 6bdffd5
Merge branch 'kubeflow:master' into patch-22
juliusvonkohout cbc549a
move changes to the minio distribution
5743208
rename distribution
a869701
rename distribution
63ffae9
fix kustomize build
1b13e66
remove unecessary changes
42a3a1a
remove wrong files
f6f3755
Update composite-controller-patch.yaml
juliusvonkohout 1485d6e
Update sync.py
juliusvonkohout 4988713
Update OWNERS
juliusvonkohout a4906e0
Update sync.py
juliusvonkohout b195034
Merge branch 'kubeflow:master' into patch-22
juliusvonkohout 5674951
Update sync.py
juliusvonkohout 82883b5
Merge branch 'kubeflow:master' into patch-22
juliusvonkohout File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
FROM docker.io/minio/mc:RELEASE.2019-08-14T20-49-49Z as minio-cli | ||
|
||
FROM python:3.7 | ||
# curl -o mc 'https://dl.min.io/client/mc/release/linux-amd64/archive/mc.RELEASE.2019-08-14T20-49-49Z' | ||
COPY --from=minio-cli /usr/bin/mc /app/mc | ||
RUN pip3 install 'boto3==1.22.*' 'minio==7.1.*' 'kubernetes==23.3.*' | ||
|
||
ENTRYPOINT ["python3" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
approvers: | ||
- juliusvonkohout | ||
- TobiasGoerke |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
This is a distribution for standalone Kubernetes clusters (Minikube, Openshift, etc.) that use MinIO as storage backend. | ||
It isolates the users on the MinIO S3 storage and has other security fixes. | ||
We will continue to harden this distribution with more security advancements. |
40 changes: 40 additions & 0 deletions
40
...ze/env/multi-user-minio/argo-workflow-controller/workflow-controller-configmap-patch.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
apiVersion: v1 | ||
kind: ConfigMap | ||
metadata: | ||
name: workflow-controller-configmap | ||
data: | ||
containerRuntimeExecutor: emissary | ||
artifactRepository: | | ||
archiveLogs: true | ||
s3: | ||
endpoint: "minio-service.$(kfp-namespace):9000" | ||
bucket: "$(kfp-artifact-bucket-name)" | ||
keyFormat: "private-artifacts/{{workflow.namespace}}/{{workflow.name}}/{{workflow.creationTimestamp.Y}}/{{workflow.creationTimestamp.m}}/{{workflow.creationTimestamp.d}}/{{pod.name}}" | ||
insecure: true | ||
accessKeySecret: | ||
name: mlpipeline-minio-artifact | ||
key: accesskey | ||
secretKeySecret: | ||
name: mlpipeline-minio-artifact | ||
key: secretkey | ||
executor: | | ||
imagePullPolicy: IfNotPresent | ||
resources: | ||
requests: | ||
cpu: 0.01 | ||
memory: 32Mi | ||
limits: | ||
cpu: 0.5 | ||
memory: 512Mi | ||
args: | ||
- --loglevel | ||
- debug | ||
- --gloglevel | ||
- "6" | ||
workflowDefaults: | | ||
spec: | ||
securityContext: | ||
fsGroup: 1000 | ||
fsGroupChangePolicy: "OnRootMismatch" | ||
runAsUser: 1000 | ||
runAsGroup: 0 |
8 changes: 8 additions & 0 deletions
8
manifests/kustomize/env/multi-user-minio/kubeflow-pipelines-profile-controller/Dockerfile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
FROM docker.io/minio/mc:RELEASE.2019-08-14T20-49-49Z as minio-cli | ||
|
||
FROM python:3.7 | ||
# curl -o mc 'https://dl.min.io/client/mc/release/linux-amd64/archive/mc.RELEASE.2019-08-14T20-49-49Z' | ||
COPY --from=minio-cli /usr/bin/mc /app/mc | ||
RUN pip3 install 'boto3==1.22.*' 'minio==7.1.*' 'kubernetes==23.3.*' | ||
|
||
ENTRYPOINT ["python3" ] |
12 changes: 12 additions & 0 deletions
12
...io/kubeflow-pipelines-profile-controller/kubeflow-pipelines-profile-controller-patch.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
name: kubeflow-pipelines-profile-controller | ||
spec: | ||
template: | ||
spec: | ||
serviceAccountName: meta-controller-service | ||
containers: | ||
- name: profile-controller | ||
image: mtr.devops.telekom.de/ai/pipelines-profile-controller:2.0.0-alpha.3 | ||
|
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My advice is to install these python library and minio cli client during runtime. New image has to pass license review and has to be served under new registry path. I would avoid that if possible.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I could make a runtime check and install them if they are not already there (self-built images), but we need them for the minio configuration. Another option could be to use the minio python client only. Anyway having downloads at runtime makes us dependent on the network and availability of pypi.org and the minio mc download site. I would prefer a static image that always works.
By the way did you read "@zijianjoy The minio mc license was changed quite late minio/mc@1402987 so that should be fine. We are using a way older mc, exactly the same date as your current minio-license-compatible image. The python SDK is still Apache 2.0 https://github.com/minio/minio-py/blob/master/LICENSE.
which minio alternative do you have in mind for the next years? ceph-rook?"
Boto3 is also apache 2.0 https://github.com/boto/boto3/blob/develop/LICENSE together with the kubernetes library https://github.com/kubernetes-client/python/blob/master/LICENSE
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you were to create a new image, then it needs to be integrated into our test and release process. Here're some pointers on top of my head, there could be more.
https://github.com/kubeflow/pipelines/blob/master/.cloudbuild.yaml
https://github.com/kubeflow/pipelines/blob/master/.release.cloudbuild.yaml