-
Notifications
You must be signed in to change notification settings - Fork 880
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
over-riding distro config still broken #2339
Comments
Launchpad user Scott Moser(smoser) wrote on 2012-12-14T17:36:30.169075+00:00 Launchpad attachments: Dependencies.txt |
Launchpad user Joshua Harlow(harlowja) wrote on 2012-12-14T18:27:23.209626+00:00 Thats really odd. Will try to look into how its not getting reset still. |
Launchpad user Joshua Harlow(harlowja) wrote on 2012-12-15T05:24:16.985831+00:00 Is it just me or did the merge not go through correctly? See: https://bazaar.launchpad.net/~harlowja/cloud-init/ds-reset-fix/revision/741 Looking at the current "head" function for distro() that was supposed to be different, it doesn't appear to have reflected that merge?? https://bazaar.launchpad.net/~cloud-init-dev/cloud-init/trunk/view/head:/cloudinit/stages.py#L75 Possibly thats why :-) |
Launchpad user Scott Moser(smoser) wrote on 2012-12-16T16:06:36+00:00 On Sat, 15 Dec 2012, Joshua Harlow wrote:
It looks like yo'ure right. Thanks for pointing this out. |
Launchpad user Joshua Harlow(harlowja) wrote on 2012-12-16T18:46:59.798547+00:00 Sure, I can submit a new merge/review if u want. Simple stuff to add back in. Shall I? |
Launchpad user Scott Moser(smoser) wrote on 2012-12-17T15:27:02.943082+00:00 fixed upstream in revno 750. Thanks Josh. |
Launchpad user Scott Moser(smoser) wrote on 2012-12-17T17:01:27.133546+00:00 fix-released in 0.7.1-0ubuntu4. |
Launchpad user Scott Moser(smoser) wrote on 2013-01-09T00:58:39.730083+00:00 fixed in -quantal proposed update 0.7.0-0ubuntu2.2 |
Launchpad user Scott Moser(smoser) wrote on 2013-05-15T20:00:30.272549+00:00 fixed in 0.7.2 |
This bug was originally filed in Launchpad as LP: #1090482
Launchpad details
Launchpad user Scott Moser(smoser) wrote on 2012-12-14T17:36:30.169075+00:00
bug reported in bug 1076811 is still affecting trunk.
See this example:
$ ec2metadata --user-data
#cloud-config
system_info:
This will affect which distro class gets used
distro: ubuntu
Other config here will be given to the distro class and/or path classes
package_mirrors:
- arches: [i386, amd64]
failsafe:
primary: http://archive.ubuntu.com/ubuntu
security: http://security.ubuntu.com/ubuntu
search:
primary:
- http://bogus.invalid.com/ubuntu/
security: []
- arches: [armhf, armel, default]
failsafe:
primary: http://ports.ubuntu.com/ubuntu-ports
security: http://ports.ubuntu.com/ubuntu-ports
That resulted in:
$ grep -v "^#" /etc/apt/sources.list | grep . | head -n 4
deb http://nova.clouds.archive.ubuntu.com/ubuntu/ raring main
deb-src http://nova.clouds.archive.ubuntu.com/ubuntu/ raring main
deb http://nova.clouds.archive.ubuntu.com/ubuntu/ raring-updates main
deb-src http://nova.clouds.archive.ubuntu.com/ubuntu/ raring-updates main
debugging with, I added these lines to /usr/share/pyshared/cloudinit/config/cc_apt_configure.py right
before the call to cloud.datasource.get_package_mirror_info() in find_apt_mirror_info.
print "cloud.distro: %s" % cloud.distro
print " package_mirrors: %s" % cloud.distro.get_option("package_mirrors", [])
print "cloud.datasource.distro: %s" % cloud.datasource.distro
print " package_mirrors: %s" % cloud.datasource.distro.get_option("package_mirrors", [])
The issue is that the 'datasource's distro != the 'cloud's distro.
$ sudo _CLOUD_INIT_SAVE_STDOUT=1 cloud-init single --name=apt-configure --frequency=always
Cloud-init v. 0.7.1 running 'single' at Fri, 14 Dec 2012 17:35:40 +0000. Up 4808.29 seconds.
cloud.distro: <cloudinit.distros.ubuntu.Distro object at 0x166f350>
package_mirrors: [{'arches': ['i386', 'amd64'], 'failsafe': {'security': 'http://security.ubuntu.com/ubuntu', 'primary': 'http://archive.ubuntu.com/ubuntu'}, 'search': {'security': [], 'primary': ['http://bogus.invalid.com/ubuntu/']}}, {'arches': ['armhf', 'armel', 'default'], 'failsafe': {'security': 'http://ports.ubuntu.com/ubuntu-ports', 'primary': 'http://ports.ubuntu.com/ubuntu-ports'}}]
cloud.datasource.distro: <cloudinit.distros.ubuntu.Distro object at 0x1ddff90>
package_mirrors: [{'arches': ['i386', 'amd64'], 'failsafe': {'security': 'http://security.ubuntu.com/ubuntu', 'primary': 'http://archive.ubuntu.com/ubuntu'}, 'search': {'security': [], 'primary': ['http://%(ec2_region)s.ec2.archive.ubuntu.com/ubuntu/', 'http://%(availability_zone)s.clouds.archive.ubuntu.com/ubuntu/']}}, {'arches': ['armhf', 'armel', 'default'], 'failsafe': {'security': 'http://ports.ubuntu.com/ubuntu-ports', 'primary': 'http://ports.ubuntu.com/ubuntu-ports'}}]
ProblemType: Bug
DistroRelease: Ubuntu 13.04
Package: cloud-init 0.7.1-0ubuntu3 [modified: usr/share/pyshared/cloudinit/config/cc_apt_configure.py usr/share/pyshared/cloudinit/distros/init.py]
ProcVersionSignature: User Name 3.7.0-5.13-generic 3.7.0-rc8
Uname: Linux 3.7.0-5-generic x86_64
ApportVersion: 2.6.3-0ubuntu4
Architecture: amd64
Date: Fri Dec 14 17:30:01 2012
Ec2AMI: ami-0000018a
Ec2AMIManifest: FIXME
Ec2AvailabilityZone: nova
Ec2InstanceType: m1.tiny
Ec2Kernel: unavailable
Ec2Ramdisk: unavailable
MarkForUpload: True
PackageArchitecture: all
ProcEnviron:
TERM=screen
PATH=(custom, no user)
LANG=en_US.UTF-8
SHELL=/bin/bash
SourcePackage: cloud-init
UpgradeStatus: No upgrade log present (probably fresh install)
The text was updated successfully, but these errors were encountered: