Packer suppresses ANSI color encoding from ansible output
This issue was originally opened by @queglay as hashicorp/packer#10348. It was migrated here as a result of the Packer plugin split. The original body of the issue is below.
Overview of the Issue
Packer suppresses ANSI color encoding. When using provisioners like Ansible, some very long logs can be output and without the color it's difficult to determine where something went wrong.
Reproduction Steps
Build anything with Ansible. Any colors that would normally be output are not visible.
Packer version
1.6.4
Yep would be nice to see the colour.
Yeah, this is still an issue with version 1.7.8.
[EDIT]
Passing ansible_env_vars = ["ANSIBLE_FORCE_COLOR=1"] to the ansible provisioner fixes it for me.