Output format

Human-readable

Best way to format output for easy debugging is running with one level of verbose -v and config ANSIBLE_STDOUT_CALLBACK=debug for callback output login, also print pure stdout
Or add stdout_callback = debug to file ansible.cfg
1
TASK [Config backend directory] ************************************************
2
changed: [default] => {
3
"changed": true,
4
"gid": 33,
5
"group": "www-data",
6
"mode": "0775",
7
"owner": "www-data",
8
"path": "/var/www",
9
"size": 4096,
10
"state": "directory",
11
"uid": 33
12
}
13
14
TASK [shell] *******************************************************************
15
changed: [default] => {
16
"changed": true,
17
"cmd": "cp -r /home/ubuntu/* /****/",
18
"delta": "0:00:00.003310",
19
"end": "2019-02-20 04:27:35.078530",
20
"rc": 0,
21
"start": "2019-02-20 04:27:35.075220"
22
}
23
24
TASK [copy] ********************************************************************
25
changed: [default] => {
26
"changed": true,
27
"checksum": "827c6dd2d1f982794c8bf413708c9b8207252c5b",
28
"dest": "/etc/supervisor/conf.d/msg-worker-supervisord.conf",
29
"gid": 0,
30
"group": "****",
31
"md5sum": "6d007a703729673056bc9b0ec4a1367b",
32
"mode": "0775",
33
"owner": "****",
34
"size": 261,
35
"src": "/****/msg-worker-supervisord.conf",
36
"state": "file",
37
"uid": 0
38
}
39
40
TASK [Run migration on template subdomain] *************************************
41
changed: [default] => {
42
"changed": true,
43
"cmd": "runuser --user=www-data -- /var/www/backend-symfony/current/bin/console doctrine:migrations:migrate --instance=instance_template.ahihi.io --env=prod",
44
"delta": "0:00:00.458270",
45
"end": "2019-02-20 04:27:37.223567",
46
"rc": 0,
47
"start": "2019-02-20 04:27:36.765297"
48
}
49
50
STDOUT:
51
52
****@instance_template:
53
54
Application Migrations
55
56
57
Migrating up to 20190218074800 from 20190215121527
58
59
++ migrating 20190218074800
60
61
-> DELETE FROM contents_status_translations WHERE status_id IN (1, 2, 3, 4)
62
-> INSERT INTO contents_status_translations (status_id, `language`, field, `value`) VALUES (1, 'de', 'name', 'Idee'), (2, 'de', 'name', 'In Produktion'), (3, 'de', 'name', 'Veröffentlicht'), (4, 'de', 'name', 'Abgelehnt')
63
64
++ migrated (0.06s)
65
66
------------------------
67
68
++ finished in 0.06s
69
++ 1 migrations executed
70
++ 2 sql queries
Copied!

Reference

Last modified 2yr ago
Copy link