Skip to content

Commit

Permalink
#22 default to specified version
Browse files Browse the repository at this point in the history
  • Loading branch information
donsizemore committed Aug 23, 2018
1 parent 991fdac commit a461935
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 8 deletions.
29 changes: 23 additions & 6 deletions tasks/dataverse-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,36 @@
name: maven
state: latest

- name: update system libraries on this ancient centos-7.1 image
yum:
name: "{{ item }}"
state: latest
with_items:
- curl
- libcurl
- nss

- name: clone specified branch
git:
repo: https://github.com/IQSS/dataverse.git
dest: /tmp/dataverse
version: "{{ dataverse.branch }}"

- name: build warfile
shell: mvn package > mvn.out
# use shell until we upgrade ansible. sigh.
#- name: clone specified branch
# shell: "cd /tmp && git clone -b {{ dataverse.branch }} https://github.com/IQSS/dataverse.git"

- name: build warfile. tail /tmp/dataverse/mvn.out for gory details.
shell: "mvn -Dmaven.test.skip=true package > mvn.out"
args:
chdir: /tmp/dataverse

#- name: copy warfile over release
# copy:
# remote_src: "/tmp/dataverse/target/dataverse-{{ dataverse.version }}.war"
# dest: "/tmp/dvinstall/dataverse-{{ dataverse.version }}.war"
# backup: yes

# use shell until we upgrade ansible.
- name: copy warfile over release
copy:
remote_src: "/tmp/dataverse/target/dataverse-{{ dataverse.version }}.war"
dest: /tmp/dvinstall/dataverse-{{ dataverse.version }}.war"
backup: yes
shell: "cp /tmp/dataverse/target/dataverse-{{ dataverse.version }}.war /tmp/dvinstall/dataverse.war"
2 changes: 1 addition & 1 deletion tasks/dataverse-install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
dest: /tmp

- include: dataverse-build.yml
when: "{{ dataverse.branch }}" is defined
when: dataverse.branch is defined

- name: fix perms on dataverse-war
file: path=/tmp/dvinstall/dataverse.war mode=0644
Expand Down
2 changes: 1 addition & 1 deletion tests/group_vars/vagrant.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ dataverse:
blocked_endpoints: "admin,test"
blocked_policy: "localhost-only"
location: "http://localhost:8080/api"
branch: develop
branch:
copyright: "© Your Institution"
db:
name: dvndb
Expand Down

0 comments on commit a461935

Please sign in to comment.