XCP-ng
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    cloud-init Network configuration

    Scheduled Pinned Locked Moved Xen Orchestra
    4 Posts 3 Posters 969 Views 2 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • A Offline
      avishorp
      last edited by

      When installing a machine with custom cloud-init configuration, the "custom config" combo box only changes the User Config, the Network config box remains as a list of commented lines. This network config causes problems (on Ubuntu 18.04, cloud-init fails to parse it as a YAML file, causing the whole process to fail). Is there a way to pre-set the value of this box/file?
      Also, is there a way to enforce the usage of cloud-init file with a certain template?

      1 Reply Last reply Reply Quote 0
      • olivierlambertO Online
        olivierlambert Vates 🪐 Co-Founder CEO
        last edited by

        @fohdeesha is the cloud init specialist

        Regarding prefill, you can set your own user config for cloudinit in XO (bottom of the left menu, user icon, then edit your cloudinit personal config)

        1 Reply Last reply Reply Quote 0
        • A Offline
          avishorp
          last edited by

          The user config that can be set from the "Settings" menu does not affect the network config file.

          1 Reply Last reply Reply Quote 0
          • fohdeeshaF Offline
            fohdeesha Vates 🪐 Pro Support Team
            last edited by

            Do you mean to say when you edit the network config box, and fill it out with your own network info (adhering to this standard: https://cloudinit.readthedocs.io/en/latest/topics/network-config-format-v1.html) that cloudinit in the vm gives a yaml error? This indicates the way you filled out the entry box is not properly formatted. Keep in mind to pass networking info, your cloudinit install in your template VM needs to be set to use nocloud data sources, and keep in mind the network configuration passed via cloud-init is added to the template VM, not replaced, so you need to properly configure your template VM to not already have adapters configured with IP addresses etc

            1 Reply Last reply Reply Quote 0
            • First post
              Last post