For AC-132. Work in progress on project SCM support.

This commit is contained in:
Chris Church
2013-08-20 16:17:30 -04:00
parent 89f5182935
commit fc68955bad
10 changed files with 1055 additions and 132 deletions

View File

@@ -0,0 +1,37 @@
---
# The following variables will be set by the runner of this playbook:
# project_path: PROJECTS_DIR/_local_path_
# scm_type: git|hg|svn
# scm_url: https://server/repo
# scm_branch: HEAD
# scm_clean: true/false
- hosts: all
connection: local
gather_facts: false
tasks:
# Git Tasks
- name: update project using git
git: dest={{project_path}} repo={{scm_url}} version={{scm_branch}} force={{scm_clean}}
when: scm_type == 'git'
async: 0
poll: 5
tags: git
# Mercurial Tasks
- name: update project using hg
hg: dest={{project_path}} repo={{scm_url}} version={{scm_branch}} force={{scm_clean}}
when: scm_type == 'hg'
async: 0
poll: 5
tags: hg
# Subversion Tasks
- name: update project using svn
subversion: dest={{project_path}} repo={{scm_url}} revision={{scm_branch}} force={{scm_clean}}
when: scm_type == 'svn'
async: 0
poll: 5
tags: svn