re-organizing playbook deploy-db
This commit is contained in:
34
db/tasks/deploy-db.yml
Normal file
34
db/tasks/deploy-db.yml
Normal file
@@ -0,0 +1,34 @@
|
||||
# deploy db postgresql, liquibase and redis
|
||||
|
||||
- name: git archive local
|
||||
local_action:
|
||||
module: git
|
||||
repo: "https://{{ git_username | urlencode }}:{{ git_password | urlencode }}@git.valczeryba.ovh/v4l3n71n/covas-liquibase.git"
|
||||
dest: "/home/valentin/src/"
|
||||
archive: "/tmp/covas-liquibase.tar.gz"
|
||||
force: yes
|
||||
update: yes
|
||||
run_once: True
|
||||
|
||||
- name: Create directory
|
||||
file:
|
||||
path: "/home/valentin/{{ item }}"
|
||||
state: directory
|
||||
with_items:
|
||||
- db
|
||||
- db/covas-liquibase
|
||||
|
||||
- name: Extract covas liquibase
|
||||
unarchive:
|
||||
src: "/tmp/covas-liquibase.tar.gz"
|
||||
dest: "/home/valentin/db/covas-liquibase"
|
||||
|
||||
- name: Template env file
|
||||
template:
|
||||
src: env.j2
|
||||
dest: /home/valentin/db/.env
|
||||
|
||||
- name: Copy docker compose server file
|
||||
copy:
|
||||
src: docker-compose-server.yml
|
||||
dest: /home/valentin/db/docker-compose.yml
|
Reference in New Issue
Block a user