Skip to content

Commit

Permalink
Fetch and publish packages after the build.
Browse files Browse the repository at this point in the history
Change-Id: I8ea159a48f3afb3d224f65cd8cadea45216922e1
Partial-Bug: 1752726
  • Loading branch information
wurbanski committed Mar 6, 2018
1 parent 3ba2ae0 commit f075996
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 6 deletions.
5 changes: 2 additions & 3 deletions .zuul.yaml
Expand Up @@ -9,14 +9,13 @@
description: |
Job that builds and tests Juniper/contrail project.
voting: False
parent: contrail-src-base
parent: contrail-src-publish-package-el-base
required-projects:
- Juniper/contrail
run: playbooks/contrail-go-docker/run.yaml
#post-run: playbooks/contrail-go-docker/post.yaml
nodeset:
nodes:
- name: contrail-go
- name: builder
label: centos-7-4-builder
vars:
docker:
Expand Down
4 changes: 2 additions & 2 deletions playbooks/contrail-go-docker/build-setup.yaml
Expand Up @@ -14,7 +14,7 @@
- name: Pretend we're using github
file:
src: "review.opencontrail.org"
path: "{{ ansible_env.HOME}}/src/github.com"
path: "{{ sourcedir }}/src/github.com"
state: link

- name: "Start runner docker container in background"
Expand All @@ -26,7 +26,7 @@
network_mode: host
command: sleep infinity
volumes:
- "{{ ansible_env.HOME }}:/go"
- "{{ sourcedir }}:/go"
become: yes
become_user: root

Expand Down
10 changes: 9 additions & 1 deletion playbooks/contrail-go-docker/run.yaml
@@ -1,9 +1,10 @@
- hosts: all
- hosts: builder
name: Build and test Juniper/contrail
roles:
- install-docker-daemon
vars:
workdir: /go/src/github.com/Juniper/contrail
sourcedir: "{{ ansible_env.HOME }}"
tasks:
- include: build-setup.yaml

Expand All @@ -21,3 +22,10 @@
- name: Make package
command: make build binaries package

- name: Fix files ownerships
file:
name: "{{ sourcedir }}"
recurse: yes
owner: "{{ ansible_env.USER }}"
become: yes
become_user: root

0 comments on commit f075996

Please sign in to comment.