cli behavior changed for commands passing optional --file argument to cloud-init init, modules or single subcommand

Bug #2064300 reported by Brett Holman
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
cloud-init (Ubuntu)
Status tracked in Oracular
Focal
Fix Committed
Undecided
Unassigned
Jammy
Fix Committed
Undecided
Unassigned
Mantic
Fix Committed
Undecided
Unassigned
Noble
Invalid
Undecided
Unassigned
Oracular
Invalid
Undecided
Unassigned

Bug Description

[ Impact ]

 * Environments or scripts which directly call cloud-init subcommands and
   provide an optional -f or --file argument to inject supplemental
   configuration after first boot will receive usage errors on the command
   line which will break any supplemental scripted setup of configuration.
   This affects some platforms which may provide secondary configuration after
   cloud-init's first boot.

   Workaround:
   Upstream cloud-init requires -f/--file arguments come after the
   subcommand instead of before. Change the order of these parameters, placing
   -f or --file after the subcommand as a workaround while awaiting an SRU fix.

 * Direct calls to cloud-init init, modules or single are atypical for most
   deployments because automated configuration generally relies on
   cloud-init systemd units running the various boot stages invoking the
   cloud-init CLI directly. But, to better support custom environments which
   need to provide an additional layer of configuration after first boot, this
   change in behavior is something we would like to resolve on stable releases.

[ Test Plan ]

 * Launch daily images in LXC and confirm usage failure inf cloud-init 24.1.3
   when providing supplemental file config before the init subcommand:
   cloud-init -f myfile.yaml init

   $ cat > myfile.yaml <<EOF
   #cloud-config
   hostname: worked
   EOF

   $ cat > setup_proposed.sh <<EOF
   #/bin/bash
   mirror=http://archive.ubuntu.com/ubuntu
   echo deb \$mirror \$(lsb_release -sc)-proposed main | tee /etc/apt/sources.list.d/proposed.list
   apt-get update -q
   apt-get install -qy cloud-init
   cloud-init --version
   EOF

   $ lxc launch ubuntu-daily:focal test-focal
   $ lxc exec test-focal bash
   $ hostname # confirm test-focal from standard meta-data
   test-focal
   $ cloud-init clean # allow running init stage again
   $ lxc file push myfile.yaml test-focal/
   $ lxc exec test-focal bash
   $ apt update; apt install cloud-init -y; cloud-init --version
   # confirm usage failure
   $ cloud-init -f /myfile.yaml init

 * Upgrade cloud-init to -proposed and confirm -f argument is supported before
   or after the init subcommand
   $ lxc file push setup_proposed.sh test-focal/
   $ lxc exec test-f -- sh /setup_proposed.sh

   # Assert cloud-init -f <myfile> <subcmd>
   $ lxc exec test-f -- cloud-init -f /myfile.yaml init
   $ lxc exec test-f -- hostname # expect 'worked'
   $ lxc exec test-f -- hostname test-f # reset hostname
   $ lxc exec test-f -- cloud-init clean # reset cloud-init

   # Assert cloud-init <subcmd> -f <myfile>
   $ lxc exec test-f -- cloud-init init -f /myfile.yaml
   $ lxc exec test-f -- hostname # expect 'worked'

   # Assert all default systemd unit behavior is unaffected by this changeset
   $ lxc exec test-f -- cloud-init clean --logs ---reboot
   $ sleep 4
   # Assert no errors or warnings logged from default boot stages
   $ lxc exec test-f -- cloud-init status --wait --format=yaml

[ Where problems could occur ]

 * Problems introduced in argument parsing on the CLI could adversely effect
   the default systemd units for cloud-init's 4 boot stages which call
   cloud-init init and modules subcommands no the CLI inside each systemd unit.
   Errors or warnings in any of these boot stages would show up in cloud-init
   status --format=yaml output or cause cloud-init to exit non-zero leaving the
   booted system in degraded state.

[ Other Info ]

==== original desciption ====
Originally reported on Github[1], cloud-init released a change in the cli[2] that broke former cloud-init cli commands.

Previously `cloud-init -f <file> init` was allowed, but after the 24.1 SRU release to Jammy, this broke and
now the following invocation is required to accomplish the same thing: `cloud-init init -f foo.cfg`. There is apparently no syntax that is compatible with both versions.

This is a change in behavior that was released under SRU back to stable releases.

[1] https://github.com/canonical/cloud-init/pull/4559#issuecomment-2084860007
[2] https://github.com/canonical/cloud-init/pull/4559

Chad Smith (chad.smith)
description: updated
Chad Smith (chad.smith)
summary: - cli behavior changed
+ cli behavior changed for commands passing optional --file argument to
+ cloud-init init, modules or single subcommand
James Falcon (falcojr)
description: updated
Revision history for this message
Andreas Hasenack (ahasenack) wrote :

I'm told that for noble and later, the change in behavior that this SRU is reverting will not be applied, as there it's intended. I'll thus make this clear by adding noble and Oracular tasks and marking them as invalid.

Changed in cloud-init (Ubuntu Oracular):
status: New → Invalid
Changed in cloud-init (Ubuntu Noble):
status: New → Invalid
Changed in cloud-init (Ubuntu Mantic):
status: New → Fix Committed
tags: added: verification-needed verification-needed-mantic
Revision history for this message
Andreas Hasenack (ahasenack) wrote : Please test proposed package

Hello Brett, or anyone else affected,

Accepted cloud-init into mantic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/cloud-init/24.1.3-0ubuntu1~23.10.4 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-mantic to verification-done-mantic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-mantic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in cloud-init (Ubuntu Jammy):
status: New → Fix Committed
tags: added: verification-needed-jammy
Revision history for this message
Andreas Hasenack (ahasenack) wrote :

Hello Brett, or anyone else affected,

Accepted cloud-init into jammy-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/cloud-init/24.1.3-0ubuntu1~22.04.3 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-jammy to verification-done-jammy. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-jammy. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in cloud-init (Ubuntu Focal):
status: New → Fix Committed
tags: added: verification-needed-focal
Revision history for this message
Andreas Hasenack (ahasenack) wrote :

Hello Brett, or anyone else affected,

Accepted cloud-init into focal-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/cloud-init/24.1.3-0ubuntu1~20.04.3 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-focal to verification-done-focal. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-focal. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Revision history for this message
Chad Smith (chad.smith) wrote :
Download full text (16.5 KiB)

==== focal verification complete ====
csmith@midtown:~$ lxc file push myfile.yaml test-focal/
csmith@midtown:~$ lxc exec test-focal bash
root@test-focal:~# # confirm usage failure
root@test-focal:~# cloud-init -f /myfile.yaml init
usage: /usr/bin/cloud-init [-h] [--version] [--debug] [--force]
                           {init,modules,single,query,features,analyze,devel,collect-logs,clean,status,schema}
                           ...
/usr/bin/cloud-init: error: argument subcommand: invalid choice: '/myfile.yaml' (choose from 'init', 'modules', 'single', 'query', 'features', 'analyze', 'devel', 'collect-logs', 'clean', 'status', 'schema')
root@test-focal:~# exit
csmith@midtown:~$ # upgrade cloud-init to proposed
csmith@midtown:~$ lxc file push setup_proposed.sh test-focal/
csmith@midtown:~$ lxc exec test-focal -- sh /setup_proposed.sh
deb http://archive.ubuntu.com/ubuntu focal-proposed main
Hit:1 http://archive.ubuntu.com/ubuntu focal InRelease
Get:2 http://security.ubuntu.com/ubuntu focal-security InRelease [114 kB]
Get:3 http://archive.ubuntu.com/ubuntu focal-updates InRelease [114 kB]
Get:4 http://archive.ubuntu.com/ubuntu focal-backports InRelease [108 kB]
Get:5 http://security.ubuntu.com/ubuntu focal-security/main amd64 Packages [2892 kB]
Get:6 http://archive.ubuntu.com/ubuntu focal-proposed InRelease [267 kB]
Get:7 http://archive.ubuntu.com/ubuntu focal/universe amd64 Packages [8628 kB]
Get:8 http://security.ubuntu.com/ubuntu focal-security/universe amd64 Packages [957 kB]
Get:9 http://security.ubuntu.com/ubuntu focal-security/universe Translation-en [201 kB]
Get:10 http://security.ubuntu.com/ubuntu focal-security/universe amd64 c-n-f Metadata [19.2 kB]
Get:11 http://security.ubuntu.com/ubuntu focal-security/multiverse amd64 Packages [24.0 kB]
Get:12 http://security.ubuntu.com/ubuntu focal-security/multiverse Translation-en [5904 B]
Get:13 http://security.ubuntu.com/ubuntu focal-security/multiverse amd64 c-n-f Metadata [548 B]
Get:14 http://archive.ubuntu.com/ubuntu focal/universe Translation-en [5124 kB]
Get:15 http://archive.ubuntu.com/ubuntu focal/universe amd64 c-n-f Metadata [265 kB]
Get:16 http://archive.ubuntu.com/ubuntu focal/multiverse amd64 Packages [144 kB]
Get:17 http://archive.ubuntu.com/ubuntu focal/multiverse Translation-en [104 kB]
Get:18 http://archive.ubuntu.com/ubuntu focal/multiverse amd64 c-n-f Metadata [9136 B]
Get:19 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 Packages [3269 kB]
Get:20 http://archive.ubuntu.com/ubuntu focal-updates/universe amd64 Packages [1183 kB]
Get:21 http://archive.ubuntu.com/ubuntu focal-updates/universe Translation-en [284 kB]
Get:22 http://archive.ubuntu.com/ubuntu focal-updates/universe amd64 c-n-f Metadata [25.7 kB]
Get:23 http://archive.ubuntu.com/ubuntu focal-updates/multiverse amd64 Packages [26.2 kB]
Get:24 http://archive.ubuntu.com/ubuntu focal-updates/multiverse Translation-en [7880 B]
Get:25 http://archive.ubuntu.com/ubuntu focal-updates/multiverse amd64 c-n-f Metadata [620 B]
Get:26 http://archive.ubuntu.com/ubuntu focal-backports/main amd64 Packages [45.7 kB]
Get:27 http://archive.ubuntu.com/ubuntu focal-backports/main Translation-en [16.3 kB]
Get:28 http://archive...

tags: added: verification-done-focal
removed: verification-needed-focal
Revision history for this message
Chad Smith (chad.smith) wrote :
Download full text (17.6 KiB)

===== jammy verification complete ====
csmith@midtown:~$ lxc launch ubuntu-daily:jammy test-jammy
Creating test-jammy
Starting test-jammy
csmith@midtown:~$ lxc file push myfile.yaml test-jammy/
csmith@midtown:~$ lxc file push setup_proposed.sh test-jammy/
csmith@midtown:~$ lxc exec test-jammy bash
root@test-jammy:~# hostname # confirm test-jammy from standard meta-data
test-jammy
root@test-jammy:~# cloud-init clean # allow running init stage again
root@test-jammy:~# # confirm usage failure
root@test-jammy:~# cloud-init -f /myfile.yaml init
usage: /usr/bin/cloud-init [-h] [--version] [--debug] [--force]
                           {init,modules,single,query,features,analyze,devel,collect-logs,clean,status,schema}
                           ...
/usr/bin/cloud-init: error: argument subcommand: invalid choice: '/myfile.yaml' (choose from 'init', 'modules', 'single', 'query', 'features', 'analyze', 'devel', 'collect-logs', 'clean', 'status', 'schema')
root@test-jammy:~# # upgrade cloud-init to confirm --file support
root@test-jammy:~# sh /setup_proposed.sh
deb http://archive.ubuntu.com/ubuntu jammy-proposed main
Hit:1 http://archive.ubuntu.com/ubuntu jammy InRelease
Get:2 http://archive.ubuntu.com/ubuntu jammy-updates InRelease [119 kB]
Get:3 http://security.ubuntu.com/ubuntu jammy-security InRelease [110 kB]
Get:4 http://archive.ubuntu.com/ubuntu jammy-backports InRelease [109 kB]
Get:5 http://archive.ubuntu.com/ubuntu jammy-proposed InRelease [270 kB]
Get:6 http://archive.ubuntu.com/ubuntu jammy/universe amd64 Packages [14.1 MB]
Get:7 http://security.ubuntu.com/ubuntu jammy-security/main amd64 Packages [1394 kB]
Get:8 http://archive.ubuntu.com/ubuntu jammy/universe Translation-en [5652 kB]
Get:9 http://security.ubuntu.com/ubuntu jammy-security/main Translation-en [243 kB]
Get:10 http://archive.ubuntu.com/ubuntu jammy/universe amd64 c-n-f Metadata [286 kB]
Get:11 http://archive.ubuntu.com/ubuntu jammy/multiverse amd64 Packages [217 kB]
Get:12 http://security.ubuntu.com/ubuntu jammy-security/universe amd64 Packages [848 kB]
Get:13 http://archive.ubuntu.com/ubuntu jammy/multiverse Translation-en [112 kB]
Get:14 http://archive.ubuntu.com/ubuntu jammy/multiverse amd64 c-n-f Metadata [8372 B]
Get:15 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 Packages [1612 kB]
Get:16 http://archive.ubuntu.com/ubuntu jammy-updates/main Translation-en [304 kB]
Get:17 http://archive.ubuntu.com/ubuntu jammy-updates/restricted Translation-en [311 kB]
Get:18 http://security.ubuntu.com/ubuntu jammy-security/universe Translation-en [163 kB]
Get:19 http://archive.ubuntu.com/ubuntu jammy-updates/universe amd64 Packages [1072 kB]
Get:20 http://security.ubuntu.com/ubuntu jammy-security/universe amd64 c-n-f Metadata [16.8 kB]
Get:21 http://security.ubuntu.com/ubuntu jammy-security/multiverse amd64 Packages [37.2 kB]
Get:22 http://security.ubuntu.com/ubuntu jammy-security/multiverse Translation-en [7588 B]
Get:23 http://security.ubuntu.com/ubuntu jammy-security/multiverse amd64 c-n-f Metadata [260 B]
Get:24 http://archive.ubuntu.com/ubuntu jammy-updates/universe Translation-en [245 kB]
Get:25 http://archive.ubuntu.com/ubuntu jammy-updates/universe amd64 c-n-f Me...

tags: added: verification-done-jammy
removed: verification-needed-jammy
Revision history for this message
Chad Smith (chad.smith) wrote :
Download full text (18.7 KiB)

==== mantic verification complete ====
csmith@midtown:~$ lxc launch ubuntu-daily:mantic test-mantic
Creating test-mantic
Starting test-mantic
csmith@midtown:~$ lxc file push myfile.yaml test-mantic/
csmith@midtown:~$ lxc file push setup_proposed.sh test-mantic/
csmith@midtown:~$ lxc exec test-mantic bash
root@test-mantic:~# apt update; apt install cloud-init -y; cloud-init --version
Hit:1 http://archive.ubuntu.com/ubuntu mantic InRelease
Get:2 http://security.ubuntu.com/ubuntu mantic-security InRelease [109 kB]
Get:3 http://archive.ubuntu.com/ubuntu mantic-updates InRelease [109 kB]
Get:4 http://archive.ubuntu.com/ubuntu mantic-backports InRelease [90.8 kB]
Get:5 http://security.ubuntu.com/ubuntu mantic-security/main amd64 Packages [352 kB]
Get:6 http://archive.ubuntu.com/ubuntu mantic/universe amd64 Packages [15.2 MB]
Get:7 http://security.ubuntu.com/ubuntu mantic-security/main Translation-en [90.8 kB]
Get:8 http://security.ubuntu.com/ubuntu mantic-security/restricted amd64 Packages [337 kB]
Get:9 http://security.ubuntu.com/ubuntu mantic-security/restricted Translation-en [60.3 kB]
Get:10 http://security.ubuntu.com/ubuntu mantic-security/universe amd64 Packages [273 kB]
Get:11 http://security.ubuntu.com/ubuntu mantic-security/universe Translation-en [114 kB]
Get:12 http://security.ubuntu.com/ubuntu mantic-security/universe amd64 DEP-11 Metadata [3860 B]
Get:13 http://security.ubuntu.com/ubuntu mantic-security/universe amd64 c-n-f Metadata [788 B]
Get:14 http://security.ubuntu.com/ubuntu mantic-security/multiverse amd64 Packages [5588 B]
Get:15 http://security.ubuntu.com/ubuntu mantic-security/multiverse Translation-en [1732 B]
Get:16 http://security.ubuntu.com/ubuntu mantic-security/multiverse amd64 c-n-f Metadata [232 B]
Get:17 http://archive.ubuntu.com/ubuntu mantic/universe Translation-en [5951 kB]
Get:18 http://archive.ubuntu.com/ubuntu mantic/universe amd64 DEP-11 Metadata [3793 kB]
Get:19 http://archive.ubuntu.com/ubuntu mantic/universe amd64 c-n-f Metadata [303 kB]
Get:20 http://archive.ubuntu.com/ubuntu mantic/multiverse amd64 Packages [239 kB]
Get:21 http://archive.ubuntu.com/ubuntu mantic/multiverse Translation-en [113 kB]
Get:22 http://archive.ubuntu.com/ubuntu mantic/multiverse amd64 DEP-11 Metadata [31.6 kB]
Get:23 http://archive.ubuntu.com/ubuntu mantic/multiverse amd64 c-n-f Metadata [8356 B]
Get:24 http://archive.ubuntu.com/ubuntu mantic-updates/main amd64 Packages [413 kB]
Get:25 http://archive.ubuntu.com/ubuntu mantic-updates/main Translation-en [110 kB]
Get:26 http://archive.ubuntu.com/ubuntu mantic-updates/restricted amd64 Packages [354 kB]
Get:27 http://archive.ubuntu.com/ubuntu mantic-updates/restricted Translation-en [62.7 kB]
Get:28 http://archive.ubuntu.com/ubuntu mantic-updates/universe amd64 Packages [357 kB]
Get:29 http://archive.ubuntu.com/ubuntu mantic-updates/universe Translation-en [138 kB]
Get:30 http://archive.ubuntu.com/ubuntu mantic-updates/universe amd64 DEP-11 Metadata [3864 B]
Get:31 http://archive.ubuntu.com/ubuntu mantic-updates/universe amd64 c-n-f Metadata [820 B]
Get:32 http://archive.ubuntu.com/ubuntu mantic-updates/multiverse amd64 Packages [8568 ...

tags: added: verification-done verification-done-mantic
removed: verification-needed verification-needed-mantic
Revision history for this message
Timo Aaltonen (tjaalton) wrote :

Hello Brett, or anyone else affected,

Accepted cloud-init into mantic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/cloud-init/24.1.3-0ubuntu1~23.10.5 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-mantic to verification-done-mantic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-mantic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

tags: added: verification-needed verification-needed-mantic
removed: verification-done verification-done-mantic
Revision history for this message
Timo Aaltonen (tjaalton) wrote :

Hello Brett, or anyone else affected,

Accepted cloud-init into jammy-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/cloud-init/24.1.3-0ubuntu1~22.04.4 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-jammy to verification-done-jammy. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-jammy. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

tags: added: verification-needed-jammy
removed: verification-done-jammy
tags: added: verification-needed-focal
removed: verification-done-focal
Revision history for this message
Timo Aaltonen (tjaalton) wrote :

Hello Brett, or anyone else affected,

Accepted cloud-init into focal-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/cloud-init/24.1.3-0ubuntu1~20.04.4 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-focal to verification-done-focal. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-focal. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Revision history for this message
Chad Smith (chad.smith) wrote :
Download full text (18.3 KiB)

Thanks Timo!
==== focal verification complete =====
csmith@midtown:~$ lxc launch ubuntu-daily:focal test-focal
Creating test-focal
Starting test-focal
csmith@midtown:~$ lxc exec test-focal bash
root@test-focal:~# hostname # confirm test-focal from standard meta-data
test-focal
root@test-focal:~# cloud-init clean # allow running init stage again
root@test-focal:~# exit
csmith@midtown:~$ lxc file push myfile.yaml test-focal/
csmith@midtown:~$ lxc exec test-focal bash
root@test-focal:~# apt update; apt install cloud-init -y; cloud-init --version
Hit:1 http://archive.ubuntu.com/ubuntu focal InRelease
Get:2 http://archive.ubuntu.com/ubuntu focal-updates InRelease [114 kB]
Get:3 http://security.ubuntu.com/ubuntu focal-security InRelease [114 kB]
Get:4 http://archive.ubuntu.com/ubuntu focal-backports InRelease [108 kB]
Get:5 http://archive.ubuntu.com/ubuntu focal/universe amd64 Packages [8628 kB]
Get:6 http://security.ubuntu.com/ubuntu focal-security/main amd64 Packages [2919 kB]
Get:7 http://archive.ubuntu.com/ubuntu focal/universe Translation-en [5124 kB]
Get:8 http://archive.ubuntu.com/ubuntu focal/universe amd64 c-n-f Metadata [265 kB]
Get:9 http://archive.ubuntu.com/ubuntu focal/multiverse amd64 Packages [144 kB]
Get:10 http://archive.ubuntu.com/ubuntu focal/multiverse Translation-en [104 kB]
Get:11 http://archive.ubuntu.com/ubuntu focal/multiverse amd64 c-n-f Metadata [9136 B]
Get:12 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 Packages [3296 kB]
Get:13 http://archive.ubuntu.com/ubuntu focal-updates/main Translation-en [521 kB]
Get:14 http://archive.ubuntu.com/ubuntu focal-updates/restricted amd64 Packages [2916 kB]
Get:15 http://archive.ubuntu.com/ubuntu focal-updates/restricted Translation-en [407 kB]
Get:16 http://archive.ubuntu.com/ubuntu focal-updates/universe amd64 Packages [1185 kB]
Get:17 http://archive.ubuntu.com/ubuntu focal-updates/universe Translation-en [284 kB]
Get:18 http://archive.ubuntu.com/ubuntu focal-updates/universe amd64 c-n-f Metadata [25.7 kB]
Get:19 http://archive.ubuntu.com/ubuntu focal-updates/multiverse amd64 Packages [26.2 kB]
Get:20 http://archive.ubuntu.com/ubuntu focal-updates/multiverse Translation-en [7880 B]
Get:21 http://archive.ubuntu.com/ubuntu focal-updates/multiverse amd64 c-n-f Metadata [620 B]
Get:22 http://archive.ubuntu.com/ubuntu focal-backports/main amd64 Packages [45.7 kB]
Get:23 http://archive.ubuntu.com/ubuntu focal-backports/main Translation-en [16.3 kB]
Get:24 http://archive.ubuntu.com/ubuntu focal-backports/main amd64 c-n-f Metadata [1420 B]
Get:25 http://archive.ubuntu.com/ubuntu focal-backports/restricted amd64 c-n-f Metadata [116 B]
Get:26 http://archive.ubuntu.com/ubuntu focal-backports/universe amd64 Packages [25.0 kB]
Get:27 http://archive.ubuntu.com/ubuntu focal-backports/universe Translation-en [16.3 kB]
Get:28 http://archive.ubuntu.com/ubuntu focal-backports/universe amd64 c-n-f Metadata [880 B]
Get:29 http://archive.ubuntu.com/ubuntu focal-backports/multiverse amd64 c-n-f Metadata [116 B]
Get:30 http://security.ubuntu.com/ubuntu focal-security/main Translation-en [438 kB]
Get:31 http://security.ubuntu.com/ubuntu focal-security/restricted amd64 Packages [2799 kB]
Get:...

tags: added: verification-done-focal
removed: verification-needed-focal
Revision history for this message
Chad Smith (chad.smith) wrote :
Download full text (17.7 KiB)

==== test verification complete jammy ====
csmith@midtown:~$ lxc launch ubuntu-daily:jammy test-jammy
Creating test-jammy
Starting test-jammy
csmith@midtown:~$ lxc file push myfile.yaml test-jammy/
csmith@midtown:~$ lxc file push setup_proposed.sh test-jammy/
csmith@midtown:~$
csmith@midtown:~$ lxc exec test-jammy bash
root@test-jammy:~# hostname # confirm test-jammy from standard meta-data
test-jammy
root@test-jammy:~# cloud-init clean # allow running init stage again
root@test-jammy:~# # confirm usage failure
root@test-jammy:~# cloud-init -f /myfile.yaml init
usage: /usr/bin/cloud-init [-h] [--version] [--debug] [--force] {init,modules,single,query,features,analyze,devel,collect-logs,clean,status,schema} ...
/usr/bin/cloud-init: error: argument subcommand: invalid choice: '/myfile.yaml' (choose from 'init', 'modules', 'single', 'query', 'features', 'analyze', 'devel', 'collect-logs', 'clean', 'status', 'schema')
root@test-jammy:~# # upgrade cloud-init to confirm --file support
root@test-jammy:~# sh /setup_proposed.sh
deb http://archive.ubuntu.com/ubuntu jammy-proposed main
Hit:1 http://archive.ubuntu.com/ubuntu jammy InRelease
Get:2 http://security.ubuntu.com/ubuntu jammy-security InRelease [110 kB]
Get:3 http://archive.ubuntu.com/ubuntu jammy-updates InRelease [119 kB]
Get:4 http://archive.ubuntu.com/ubuntu jammy-backports InRelease [109 kB]
Get:5 http://security.ubuntu.com/ubuntu jammy-security/main amd64 Packages [1427 kB]
Get:6 http://archive.ubuntu.com/ubuntu jammy-proposed InRelease [270 kB]
Get:7 http://archive.ubuntu.com/ubuntu jammy/universe amd64 Packages [14.1 MB]
Get:8 http://security.ubuntu.com/ubuntu jammy-security/main Translation-en [247 kB]
Get:9 http://security.ubuntu.com/ubuntu jammy-security/restricted amd64 Packages [1807 kB]
Get:10 http://security.ubuntu.com/ubuntu jammy-security/restricted Translation-en [307 kB]
Get:11 http://security.ubuntu.com/ubuntu jammy-security/universe amd64 Packages [852 kB]
Get:12 http://security.ubuntu.com/ubuntu jammy-security/universe Translation-en [164 kB]
Get:13 http://security.ubuntu.com/ubuntu jammy-security/universe amd64 c-n-f Metadata [16.8 kB]
Get:14 http://security.ubuntu.com/ubuntu jammy-security/multiverse amd64 Packages [37.2 kB]
Get:15 http://security.ubuntu.com/ubuntu jammy-security/multiverse Translation-en [7588 B]
Get:16 http://security.ubuntu.com/ubuntu jammy-security/multiverse amd64 c-n-f Metadata [260 B]
Get:17 http://archive.ubuntu.com/ubuntu jammy/universe Translation-en [5652 kB]
Get:18 http://archive.ubuntu.com/ubuntu jammy/universe amd64 c-n-f Metadata [286 kB]
Get:19 http://archive.ubuntu.com/ubuntu jammy/multiverse amd64 Packages [217 kB]
Get:20 http://archive.ubuntu.com/ubuntu jammy/multiverse Translation-en [112 kB]
Get:21 http://archive.ubuntu.com/ubuntu jammy/multiverse amd64 c-n-f Metadata [8372 B]
Get:22 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 Packages [1638 kB]
Get:23 http://archive.ubuntu.com/ubuntu jammy-updates/main Translation-en [307 kB]
Get:24 http://archive.ubuntu.com/ubuntu jammy-updates/restricted amd64 Packages ...

tags: added: verification-done-jammy
removed: verification-needed-jammy
Revision history for this message
Chad Smith (chad.smith) wrote :
Download full text (16.2 KiB)

##### verification complete mantic #####
csmith@midtown:~$ lxc launch ubuntu-daily:mantic test-m
Creating test-m
Starting test-m file push myfile.yaml
csmith@midtown:~$ lxc file push myfile.yaml test-m/
csmith@midtown:~$ lxc file push setup_proposed.sh test-m/
csmith@midtown:~$ lxc exec test-m bash
root@test-m:~# hostname # confirm test-jammy from standard meta-data
test-m
root@test-m:~# cloud-init clean # allow running init stage again
root@test-m:~# # confirm usage failure
root@test-m:~# cloud-init -f /myfile.yaml init
usage: /usr/bin/cloud-init [-h] [--version] [--debug] [--force] {init,modules,single,query,features,analyze,devel,collect-logs,clean,status,schema} ...
/usr/bin/cloud-init: error: argument subcommand: invalid choice: '/myfile.yaml' (choose from 'init', 'modules', 'single', 'query', 'features', 'analyze', 'devel', 'collect-logs', 'clean', 'status', 'schema')
root@test-m:~# # upgrade cloud-init to confirm --file support
root@test-m:~# sh /setup_proposed.sh
deb http://archive.ubuntu.com/ubuntu mantic-proposed main
Hit:1 http://archive.ubuntu.com/ubuntu mantic InRelease
Get:2 http://archive.ubuntu.com/ubuntu mantic-updates InRelease [109 kB]
Get:3 http://security.ubuntu.com/ubuntu mantic-security InRelease [109 kB]
Get:4 http://archive.ubuntu.com/ubuntu mantic-backports InRelease [90.8 kB]
Get:5 http://archive.ubuntu.com/ubuntu mantic-proposed InRelease [256 kB]
Get:6 http://archive.ubuntu.com/ubuntu mantic/universe amd64 Packages [15.2 MB]
Get:7 http://security.ubuntu.com/ubuntu mantic-security/main amd64 Packages [355 kB]
Get:8 http://archive.ubuntu.com/ubuntu mantic/universe Translation-en [5951 kB]
Get:9 http://archive.ubuntu.com/ubuntu mantic/universe amd64 DEP-11 Metadata [3793 kB]
Get:10 http://security.ubuntu.com/ubuntu mantic-security/main Translation-en [91.5 kB]
Get:11 http://security.ubuntu.com/ubuntu mantic-security/universe amd64 Packages [274 kB]
Get:12 http://archive.ubuntu.com/ubuntu mantic/universe amd64 c-n-f Metadata [303 kB]
Get:13 http://archive.ubuntu.com/ubuntu mantic/multiverse amd64 Packages [239 kB]
Get:14 http://archive.ubuntu.com/ubuntu mantic/multiverse Translation-en [113 kB]
Get:15 http://archive.ubuntu.com/ubuntu mantic/multiverse amd64 DEP-11 Metadata [31.6 kB]
Get:16 http://archive.ubuntu.com/ubuntu mantic/multiverse amd64 c-n-f Metadata [8356 B]
Get:17 http://archive.ubuntu.com/ubuntu mantic-updates/main amd64 Packages [415 kB]
Get:18 http://archive.ubuntu.com/ubuntu mantic-updates/main Translation-en [110 kB]
Get:19 http://archive.ubuntu.com/ubuntu mantic-updates/universe amd64 Packages [360 kB]
Get:20 http://archive.ubuntu.com/ubuntu mantic-updates/universe Translation-en [138 kB]
Get:21 http://archive.ubuntu.com/ubuntu mantic-updates/universe amd64 DEP-11 Metadata [3864 B]
Get:22 http://archive.ubuntu.com/ubuntu mantic-updates/universe amd64 c-n-f Metadata [820 B]
Get:23 http://archive.ubuntu.com/ubuntu mantic-updates/multiverse amd64 Packages [8568 B]
Get:24 http://archive.ubuntu.com/ubuntu mantic-updates/multiverse Translation-en [2824 B]
Get:25 http://archive.ubuntu.com/ubuntu mantic-updates/multiverse amd64 c-n-f Metadata [232 B]
Get:26 http://archive.u...

tags: added: verification-done verification-done-mantic
removed: verification-needed verification-needed-mantic
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.