Template generated html files with garbage chars

asked 2018-02-14 02:22:16 -0600

ttamttam gravatar image

Hello,

some years ago, we installed puppet on a dedicated virtual machine. It is used to manage a Windows server. One of it's tasks is to generate HTML files from templates (EPP). The problem is that since some time (we did not detect when it occured), the HTML files are no more correct. We are looking for advices for "things to check" in order to solve this problem.

The current configuration is described in more detail below: The template file and the manifest file are both encoded in utf-8.

Example of problem: A é in the template file (encoded as 0xC3 0xA9 ) becomes ├® in the generated HTML (encoded as 0xE2 0x94 0x9C 0xC2 0xA2).

The virtual machine operating system and puppet server version:

root@puppet:~# cat /etc/issue
Debian GNU/Linux 8 \n \l
root@puppet:~# dpkg -l puppetserver
Souhait=inconnU/Installé/suppRimé/Purgé/H=à garder
| État=Non/Installé/fichier-Config/dépaqUeté/échec-conFig/H=semi-installé/W=attend-traitement-déclenchements
|/ Err?=(aucune)/besoin Réinstallation (État,Err: majuscule=mauvais)
||/ Nom                                            Version                      Architecture                 Description
+++-==============================================-============================-============================-==================================================================================================
ii  puppetserver                                   2.8.0-1puppetlabs1           all                          Puppet Labs puppetserver

Thanks for any hint toward solving this problem.

edit retag flag offensive close merge delete

Comments

Can't you use entities as a work-around? I run my servers all in LC_ALL=C or LANG=en_US.UTF-8. Maybe this might cause a problem. Or maybe there is a difference if you generate your documents from an EPP or an ERB template.

Kai Burghardt gravatar imageKai Burghardt ( 2018-05-04 04:50:10 -0600 )edit