Cloudbase-Init is removing all line breaks

asked 2016-12-05 06:57:50 -0600

Augustin Ziegler gravatar image

whenever i attach a script to a server using the --user-data parameter in combination with --config-drive True the script file on the server is without any line breaks:

$ErrorActionPreference = "Stop"

"$(Get-Date) - Test" | Out-File 'C:\test.log' -Append

will be

#ps1_sysnative$ErrorActionPreference = "Stop""$(Get-Date) - Test" | Out-File 'C:\test.log' -Append

on the server D:\openstack\latest\user-data. Obviously the script will not be executed, how can i fix this issue? is there any encoding I have to be aware?

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted

answered 2017-03-20 15:09:54 -0600

ader1990 gravatar image


There shouldn't be any issues with the encoding, can you put the exact user data file online so that we can reproduce the problem?

Thank you, Adrian Vladu

edit flag offensive delete link more

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower


Asked: 2016-12-05 06:57:50 -0600

Seen: 148 times

Last updated: Mar 20 '17