This is caused by the Puppet daemon not reading the correct locale, even though it's previously set by the shell provisioner.
While this could be mitigated by setting LANG=en_US.UTF-8
when the Puppet daemon runs, Vagrant currently doesn't support passing environment variables to Puppet at runtime. The issue is described here: https://github.com/mitchellh/vagrant/issues/2270.
The link above also provides a workaround. The workaround in the issue thread has to do with setting proxy servers as env. variables, but I modified it to set the LANG
in a similar way:
Vagrantfile
:
config.vm.provision :puppet do |puppet|
puppet.facter = {
# Specifying the LANG environment variable this way is a work around.
# The work around can be removed when this issue is fixed https://github.com/mitchellh/vagrant/issues/2270
"hack=hack LANG=en_US.UTF-8 hack" => "hack"
}
Adding this to Vagrantfile's Puppet provisioner sets the LANG
correctly, and Puppet runs as expected on first boot.