pilot-playbooks/README.md
2022-07-01 22:16:56 +02:00

40 lines
680 B
Markdown

# Ansible: Setup App
This playbook installs app from repository and bind Traefik on defined host.
## Usage
Copy then change values of hosts example file :
```bash
$ cp hosts.example.ini hosts.ini
```
Then create a file `vars.json` vars who contain :
```json
{
"name": "myapp",
"repository": "https://git.example.com/vendor/app.git",
"version": "master",
"host": "myapp.example.com",
"dockerfile": "Dockerfile",
"envvars": {
"APP_NAME": "Wonderful",
"APP_ENV": "production"
}
}
```
Then run a playbook:
```bash
$ ansible-playbook -i hosts.ini playbooks/app-install.yml -e @vars.json
```
## Available playbooks:
+ app-install
+ app-start
+ app-stop