Skip to content

Commit

Permalink
Merge branch 'feature/ZENKO-476-addDockerBuildStepForEve' into q/8.0
Browse files Browse the repository at this point in the history
  • Loading branch information
bert-e committed Jun 12, 2018
2 parents b475039 + c17397b commit 96a0729
Show file tree
Hide file tree
Showing 2 changed files with 64 additions and 3 deletions.
39 changes: 36 additions & 3 deletions eve/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,31 @@
version: 0.2

branches:
feature/*, improvement/*, bugfix/*, w/*, q/*, hotfix/*, ft/*, bf/*, chore/*, docs/*:
feature/*, improvement/*, bugfix/*, w/*, q/*, hotfix/*:
stage: "pre-merge"
development/*:
stage: "post-merge"


stages:
pre-merge:
worker:
worker: &pod
type: kube_pod
path: eve/workers/pod.yml
steps:
- TriggerStages:
name: trigger all the tests
stage_names:
- run-tests
- docker-build
run-tests:
worker: &workspace
type: docker
path: eve/workers/unit_and_feature_tests
volumes:
- '/home/eve/workspace'
steps:
- Git:
- Git: &git
name: fetch source
repourl: '%(prop:git_reference)s'
shallow: True
Expand All @@ -35,3 +48,23 @@ stages:
name: run s3 server and run feature tests
command: bash ./eve/workers/unit_and_feature_tests/run_server_tests.bash
workdir: '%(prop:builddir)s/build'

docker-build:
worker:
type: kube_pod
path: eve/workers/pod.yml
steps:
- Git: *git
- ShellCommand: &docker_build
name: Docker build
command: docker build -t zenko/backbeat:nightly .

post-merge:
worker:
type: kube_pod
path: eve/workers/pod.yml
steps:
- Git: *git
- ShellCommand: *docker_build
# - ShellCommand: &docker_login waiting for RELENG
# - ShellCommand: &docker_push Waiting for RELENG
28 changes: 28 additions & 0 deletions eve/workers/pod.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
apiVersion: v1
kind: Pod
metadata:
name: "zenko-test-pod"
spec:
activeDeadlineSeconds: 3600
restartPolicy: Never
terminationGracePeriodSeconds: 10
containers:
- name: zenko-releng
image: zenko/zenko-releng:0.0.6
imagePullPolicy: IfNotPresent
resources:
requests:
cpu: 500m
memory: 1Gi
limits:
cpu: "1"
memory: 2Gi
command: ["/bin/sh", "-c", "buildbot-worker create-worker . ${BUILDMASTER}:${BUILDMASTER_PORT} ${WORKERNAME} ${WORKERPASS} && buildbot-worker start --nodaemon"]
volumeMounts:
- mountPath: /var/run/docker.sock
name: docker-socket
volumes:
- name: docker-socket
hostPath:
path: /var/run/docker.sock
type: Socket

0 comments on commit 96a0729

Please sign in to comment.