Skip to content

Commit

Permalink
Convert unit, integration test and integration-CLI jobs to postsubmits
Browse files Browse the repository at this point in the history
  • Loading branch information
AshwinHIBM committed Jan 28, 2025
1 parent 7dece64 commit 23a11d9
Show file tree
Hide file tree
Showing 2 changed files with 171 additions and 125 deletions.
135 changes: 10 additions & 125 deletions config/jobs/periodic/docker/periodic-ci-docker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,12 @@ periodics:
org: ppc64le-cloud
repo: docker-ce-build
reporter_config:
slack:
channel: 'prow-job-notifications'
report_template: 'Job {{.Spec.Job}} of type {{.Spec.Type}} ended with state {{.Status.State}}. <!subteam^S02N6DWBX0F> <{{.Status.URL}}|View logs>'
slack:
channel: 'prow-job-notifications'
job_states_to_report:
- failure
- error
report_template: 'Job {{.Spec.Job}} of type {{.Spec.Type}} ended with state {{.Status.State}}. <!subteam^S02N6DWBX0F> <{{.Status.URL}}|View logs>'
spec:
containers:
- image: quay.io/powercloud/docker-ce-build@sha256:b1e2679b9a5aabe15a94ae3130f5b02ce67441cf361fda7dc7a41929bb50ba87
Expand Down Expand Up @@ -49,7 +52,7 @@ periodics:
cluster: k8s-ppc64le-cluster
labels:
preset-build-docker: "true"
cron: 0 3 * * *
cron: 10 0 * * *
decorate: true
extra_refs:
- base_ref: main
Expand All @@ -58,6 +61,9 @@ periodics:
reporter_config:
slack:
channel: 'prow-job-notifications'
job_states_to_report:
- failure
- error
report_template: 'Job {{.Spec.Job}} of type {{.Spec.Type}} ended with state {{.Status.State}}. <!subteam^S02N6DWBX0F> <{{.Status.URL}}|View logs>'
spec:
containers:
Expand All @@ -84,124 +90,3 @@ periodics:
exit $rc
securityContext:
privileged: true
- name: periodic-unit-test-docker
cluster: k8s-ppc64le-cluster
labels:
preset-build-docker: "true"
cron: 0 9 * * *
decorate: true
extra_refs:
- base_ref: main
org: ppc64le-cloud
repo: docker-ce-build
reporter_config:
slack:
channel: 'prow-job-notifications'
report_template: 'Job {{.Spec.Job}} of type {{.Spec.Type}} ended with state {{.Status.State}}. <!subteam^S02N6DWBX0F> <{{.Status.URL}}|View logs>'
spec:
containers:
- image: quay.io/powercloud/docker-ce-build@sha256:b1e2679b9a5aabe15a94ae3130f5b02ce67441cf361fda7dc7a41929bb50ba87
resources:
requests:
cpu: "4000m"
limits:
cpu: "4000m"
command:
- /bin/bash
args:
- -c
- |
set -o errexit
set -o nounset
set -o pipefail
set -o xtrace
echo "* Start prow-unit-test-docker *"
chmod ug+x $PWD/upstream-master-ci/prow-unit-test-docker.sh
$PWD/upstream-master-ci/prow-unit-test-docker.sh
rc=$?
[ $rc != 0 ] && echo "ERROR: prow-unit-test-docker exited with code:$rc"
exit $rc
securityContext:
privileged: true
- name: periodic-integration-cli-docker
cluster: k8s-ppc64le-cluster
labels:
preset-build-docker: "true"
cron: 0 14 * * *
decorate: true
decoration_config:
timeout: 3h
extra_refs:
- base_ref: main
org: ppc64le-cloud
repo: docker-ce-build
reporter_config:
slack:
channel: 'prow-job-notifications'
report_template: 'Job {{.Spec.Job}} of type {{.Spec.Type}} ended with state {{.Status.State}}. <!subteam^S02N6DWBX0F> <{{.Status.URL}}|View logs>'
spec:
containers:
- image: quay.io/powercloud/docker-ce-build@sha256:b1e2679b9a5aabe15a94ae3130f5b02ce67441cf361fda7dc7a41929bb50ba87
resources:
requests:
cpu: "4000m"
limits:
cpu: "4000m"
command:
- /bin/bash
args:
- -c
- |
set -o errexit
set -o nounset
set -o pipefail
set -o xtrace
echo "* Start prow-integration-cli-tests *"
chmod ug+x $PWD/upstream-master-ci/prow-integration-cli.sh
$PWD/upstream-master-ci/prow-integration-cli.sh
rc=$?
[ $rc != 0 ] && echo "ERROR: prow-integration-cli-tests exited with code:$rc"
exit $rc
securityContext:
privileged: true
- name: periodic-integration-test-docker
cluster: k8s-ppc64le-cluster
labels:
preset-build-docker: "true"
cron: 30 14 * * *
decorate: true
decoration_config:
timeout: 3h
extra_refs:
- base_ref: main
org: ppc64le-cloud
repo: docker-ce-build
reporter_config:
slack:
channel: 'prow-job-notifications'
report_template: 'Job {{.Spec.Job}} of type {{.Spec.Type}} ended with state {{.Status.State}}. <!subteam^S02N6DWBX0F> <{{.Status.URL}}|View logs>'
spec:
containers:
- image: quay.io/powercloud/docker-ce-build@sha256:b1e2679b9a5aabe15a94ae3130f5b02ce67441cf361fda7dc7a41929bb50ba87
resources:
requests:
cpu: "4000m"
limits:
cpu: "4000m"
command:
- /bin/bash
args:
- -c
- |
set -o errexit
set -o nounset
set -o pipefail
set -o xtrace
echo "* Start prow-integration-tests *"
chmod ug+x $PWD/upstream-master-ci/prow-integration-tests.sh
$PWD/upstream-master-ci/prow-integration-tests.sh
rc=$?
[ $rc != 0 ] && echo "ERROR: prow-integration-tests exited with code:$rc"
exit $rc
securityContext:
privileged: true
161 changes: 161 additions & 0 deletions config/jobs/ppc64le-cloud/build-docker/postsubmit-ci-docker.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,161 @@
postsubmits:
ppc64le-cloud/docker-ce-build:
- name: postsubmit-unit-test-docker
cluster: k8s-ppc64le-cluster
labels:
preset-build-docker: "true"
decorate: true
decoration_config:
timeout: 2h
run_if_changed: 'job/postsubmit-ci-docker'
reporter_config:
slack:
channel: 'prow-job-notifications'
job_states_to_report:
- failure
- error
report_template: 'Job {{.Spec.Job}} of type {{.Spec.Type}} ended with state {{.Status.State}}. <!subteam^S02N6DWBX0F> <{{.Status.URL}}|View logs>'
branches:
- prow-job-tracking
spec:
containers:
- image: quay.io/powercloud/docker-ce-build@sha256:b1e2679b9a5aabe15a94ae3130f5b02ce67441cf361fda7dc7a41929bb50ba87
resources:
requests:
cpu: "4000m"
limits:
cpu: "4000m"
command:
- /bin/bash
args:
- -c
- |
##
# This job is populated with the files from the 'prow-job-tracking' branch.
# We switch to the 'main' branch, as it contains the scripts used by this job.
###
set -o errexit
set -o nounset
set -o pipefail
set -o xtrace
#Set this to your dev branch for testing
WORK_BRANCH=main
git fetch https://github.com/${REPO_OWNER}/${REPO_NAME} ${WORK_BRANCH}
git checkout ${WORK_BRANCH}
echo "* Start prow-unit-test-docker *"
chmod ug+x $PWD/upstream-master-ci/prow-unit-test-docker.sh
$PWD/upstream-master-ci/prow-unit-test-docker.sh
rc=$?
[ $rc != 0 ] && echo "ERROR: prow-unit-test-docker exited with code:$rc"
exit $rc
securityContext:
privileged: true
- name: postsubmit-integration-cli-docker
cluster: k8s-ppc64le-cluster
labels:
preset-build-docker: "true"
decorate: true
decoration_config:
timeout: 2h
run_if_changed: 'job/postsubmit-ci-docker'
reporter_config:
slack:
channel: 'prow-job-notifications'
job_states_to_report:
- failure
- error
report_template: 'Job {{.Spec.Job}} of type {{.Spec.Type}} ended with state {{.Status.State}}. <!subteam^S02N6DWBX0F> <{{.Status.URL}}|View logs>'
branches:
- prow-job-tracking
spec:
containers:
- image: quay.io/powercloud/docker-ce-build@sha256:b1e2679b9a5aabe15a94ae3130f5b02ce67441cf361fda7dc7a41929bb50ba87
resources:
requests:
cpu: "4000m"
limits:
cpu: "4000m"
command:
- /bin/bash
args:
- -c
- |
##
# This job is populated with the files from the 'prow-job-tracking' branch.
# We switch to the 'main' branch, as it contains the scripts used by this job.
###
set -o errexit
set -o nounset
set -o pipefail
set -o xtrace
#Set this to your dev branch for testing
WORK_BRANCH=main
git fetch https://github.com/${REPO_OWNER}/${REPO_NAME} ${WORK_BRANCH}
git checkout ${WORK_BRANCH}
echo "* Start prow-integration-cli-docker *"
chmod ug+x $PWD/upstream-master-ci/prow-integration-cli.sh
$PWD/upstream-master-ci/prow-integration-cli.sh
rc=$?
[ $rc != 0 ] && echo "ERROR: prow-integration-cli-docker exited with code:$rc"
exit $rc
securityContext:
privileged: true
- name: postsubmit-integration-test-docker
cluster: k8s-ppc64le-cluster
labels:
preset-build-docker: "true"
decorate: true
decoration_config:
timeout: 2h
run_if_changed: 'job/postsubmit-ci-docker'
reporter_config:
slack:
channel: 'prow-job-notifications'
job_states_to_report:
- failure
- error
report_template: 'Job {{.Spec.Job}} of type {{.Spec.Type}} ended with state {{.Status.State}}. <!subteam^S02N6DWBX0F> <{{.Status.URL}}|View logs>'
branches:
- prow-job-tracking
spec:
containers:
- image: quay.io/powercloud/docker-ce-build@sha256:b1e2679b9a5aabe15a94ae3130f5b02ce67441cf361fda7dc7a41929bb50ba87
resources:
requests:
cpu: "4000m"
limits:
cpu: "4000m"
command:
- /bin/bash
args:
- -c
- |
##
# This job is populated with the files from the 'prow-job-tracking' branch.
# We switch to the 'main' branch, as it contains the scripts used by this job.
###
set -o errexit
set -o nounset
set -o pipefail
set -o xtrace
#Set this to your dev branch for testing
WORK_BRANCH=main
git fetch https://github.com/${REPO_OWNER}/${REPO_NAME} ${WORK_BRANCH}
git checkout ${WORK_BRANCH}
echo "* Start prow-integration-test-docker *"
chmod ug+x $PWD/upstream-master-ci/prow-integration-tests.sh
$PWD/upstream-master-ci/prow-integration-tests.sh
rc=$?
[ $rc != 0 ] && echo "ERROR: prow-integration-test-docker exited with code:$rc"
exit $rc
securityContext:
privileged: true

0 comments on commit 23a11d9

Please sign in to comment.