Skip to content

Commit

Permalink
Image building and pushing for free5gc-operator (#27)
Browse files Browse the repository at this point in the history
* Image building and pushing for free5gc-operator

Images built from every commit will have prow BUILD_ID as a version and those build from release tags v.X.Y.Z will have that tag name as version

* Update prow/config/config.yaml

Co-authored-by: Victor Morales <chipahuac@hotmail.com>

* Update prow/config/config.yaml

Co-authored-by: Victor Morales <chipahuac@hotmail.com>

---------

Co-authored-by: Victor Morales <chipahuac@hotmail.com>
  • Loading branch information
radoslawc and electrocucaracha committed May 5, 2023
1 parent dd2fac6 commit c58c18f
Showing 1 changed file with 75 additions and 0 deletions.
75 changes: 75 additions & 0 deletions prow/config/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,81 @@ postsubmits:
- image: alpine
command:
- /bin/printenv

nephio-project/free5gc-operator:
- name: build-push-image-free5gc-operator-release-conf
cluster: default
always_run: true
branches:
- "^v.*$"
annotations:
description: Build and Push Image to DockerHub when release tag is created
decorate: true
decoration_config:
censor_secrets: true
max_concurrency: 0
spec:
containers:
- name: kaniko
image: gcr.io/kaniko-project/executor:debug
command:
- "/bin/sh"
- "-c"
- |
executor --context=${PWD}/free5gc-operator \
--dockerfile=Dockerfile --destination=nephio/free5gc-operator:${PULL_BASE_REF}
volumeMounts:
- name: kaniko-secret
mountPath: /kaniko/.docker/
resources:
requests:
cpu: 2
memory: 2Gi
volumes:
- name: kaniko-secret
secret:
secretName: regcred
items:
- key: .dockerconfigjson
path: config.json

- name: build-push-image-free5gc-operator-commit-conf
cluster: default
always_run: true
branches:
- "main"
annotations:
description: Build and Push Image to DockerHub every commit
decorate: true
decoration_config:
censor_secrets: true
max_concurrency: 0
spec:
containers:
- name: kaniko
image: gcr.io/kaniko-project/executor:debug
command:
- "/bin/sh"
- "-c"
- |
executor --context=${PWD}/free5gc-operator \
--dockerfile=Dockerfile --destination=nephio/free5gc-operator:${BUILD_ID}
volumeMounts:
- name: kaniko-secret
mountPath: /kaniko/.docker/
resources:
requests:
cpu: 2
memory: 2Gi
volumes:
- name: kaniko-secret
secret:
secretName: regcred
items:
- key: .dockerconfigjson
path: config.json


presubmits:
nephio-project/nephio-test-prow-project:
- name: test-presubmit
Expand Down

0 comments on commit c58c18f

Please sign in to comment.