Skip to content

Commit

Permalink
tasks: lxc_cache_preparation: Log cache preparation command output
Browse files Browse the repository at this point in the history
We already enable debug output (-x) in the shell script but we never
actually see this output during or after the cache preparation step
takes place. It's useful to log what exactly happened so we can look
for problems or find potential optimization opportunities so just log
the output to /var/log which is also being collected by the various CI
scripts.

Change-Id: I3d0ab31e052889b9ac03de9a3ccba680e840fca5
  • Loading branch information
Markos Chandras committed Oct 8, 2017
1 parent 3f3c91c commit f00824f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tasks/lxc_cache_preparation.yml
Expand Up @@ -93,7 +93,7 @@
# This task runs several commands against the cached image to speed up the
# lxc_container_create playbook.
- name: Prepare cached image setup commands
command: "chroot {{ lxc_image_cache_path }} /usr/local/bin/cache-prep-commands.sh"
shell: "chroot {{ lxc_image_cache_path }} /usr/local/bin/cache-prep-commands.sh > /var/log/lxc-cache-prep-commands.log 2>&1"
changed_when: false

- name: Adjust sshd configuration in container
Expand Down

0 comments on commit f00824f

Please sign in to comment.