Cloud config files no CR/LF

Bug #1812701 reported by mr marcus j adams
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
cloudbase-init
New
Undecided
Unassigned

Bug Description

Windows Server 2012 R2 Cloudbase-init 0.9.12

When using write-files option of cloud config files are being created but CR/LF are being ignored and output is being treated as a single line per file.

Example
#cloud-config
write_files:
  - path: 'C:\temp\test.xml'
    content: |
      <Test>
        <myIndent>
            <Item1>test.fqdn.local</Item1>
            <Item2>value</Item2>
            <Item3>data</Item3>
            <Item4></Item4>
            <Item5>data</Item5>
           </myIndent>
      </Test>

  - path: 'C:\temp\test.full.xml.config'
    content: |
      <?xml version="1.0" encoding="utf-8"?>
      <configuration>
        <appSettings>
          <add key="one" value="one" />
          <add key="two" value="two" />
          <add key="three" value="three" />
        </appSettings>
      </configuration>

  - path: 'C:\temp\test.multilinetext.txt'
    content: |
      # This is multi line windows text file.
      # This should be on a new line.
      # This file may contain comment lines using hash signs (like this one). Other lines
      # must consist of the following: IP address or range in CIDR notation
      #
      #LocalLink Address
      169.254.0.0/16
      # Localhost
      127.0.0.1/8
      # another IP
      10.0.0.0/16
      # evryoneknowsthis
      4.4.4.4

**********************************
This results in the following example corrupted output

# This is multi line windows text file. # This should be on a new line.# This file may contain comment lines using hash signs (like this one). Other lines# must consist of the following: IP address or range in CIDR notation##LocalLink Address......

Not sure if it helps but if I copy the contents of the files from the windows server and then past here or in a more intelligent (linux aware) editor they then do paste correctly

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.