mirror of
https://github.com/Crocmagnon/ansible.git
synced 2024-12-22 05:52:00 +01:00
add update playbook + folder for apps
This commit is contained in:
parent
06630d79fd
commit
9b01415013
5 changed files with 16 additions and 7 deletions
8
Makefile
8
Makefile
|
@ -1,7 +1,7 @@
|
||||||
.PHONY: dry-run
|
.PHONY: dry-run
|
||||||
dry-run:
|
apps-dry-run:
|
||||||
ansible-playbook playbooks/*.yaml --check --diff
|
ansible-playbook playbooks/apps/*.yaml --check --diff
|
||||||
|
|
||||||
.PHONY: run
|
.PHONY: run
|
||||||
run:
|
apps:
|
||||||
ansible-playbook playbooks/*.yaml
|
ansible-playbook playbooks/apps/*.yaml
|
||||||
|
|
|
@ -11,5 +11,5 @@ ansible-playbook playbooks/dependencies/*.yaml
|
||||||
|
|
||||||
## run
|
## run
|
||||||
```shell
|
```shell
|
||||||
ansible-playbook playbooks/*.yaml
|
ansible-playbook playbooks/apps/*.yaml
|
||||||
```
|
```
|
||||||
|
|
|
@ -30,7 +30,7 @@
|
||||||
- name: write service unit file
|
- name: write service unit file
|
||||||
become: true
|
become: true
|
||||||
template:
|
template:
|
||||||
src: ../templates/goatcounter.service.j2
|
src: ../../templates/goatcounter.service.j2
|
||||||
dest: /etc/systemd/system/goatcounter.service
|
dest: /etc/systemd/system/goatcounter.service
|
||||||
notify:
|
notify:
|
||||||
- daemon-reload
|
- daemon-reload
|
|
@ -4,7 +4,7 @@
|
||||||
- name: write service file
|
- name: write service file
|
||||||
become: true
|
become: true
|
||||||
template:
|
template:
|
||||||
src: ../templates/lyon-transports.service.j2
|
src: ../../templates/lyon-transports.service.j2
|
||||||
dest: /etc/systemd/system/lyon-transports.service
|
dest: /etc/systemd/system/lyon-transports.service
|
||||||
notify:
|
notify:
|
||||||
- daemon-reload
|
- daemon-reload
|
9
playbooks/system/update.yaml
Normal file
9
playbooks/system/update.yaml
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
- name: system update
|
||||||
|
hosts: servers
|
||||||
|
become: true
|
||||||
|
tasks:
|
||||||
|
- name: packages update
|
||||||
|
apt:
|
||||||
|
upgrade: yes
|
||||||
|
update_cache: yes
|
||||||
|
cache_valid_time: 86400
|
Loading…
Reference in a new issue