Commit Graph

1392 Commits

Author SHA1 Message Date
Jenkins
142dfad122 Merge "Enable custom apt.conf in apt-conf element" 2014-02-28 04:17:51 +00:00
Jonathan Brownell
2189b627de Fix syntax error in GRUB_OPTS env var handling
Reference to ${GRUB_OPTS:""} in 'vm' element causes syntax error
if GRUB_OPTS is set. Fix by changing to ${GRUB_OPTS:-""}.

Change-Id: Iae3ee8b7c4064c92d0cfc1b5a8caa22e53d6d112
2014-02-27 13:53:07 -08:00
Dustin J. Mitchell
c60ed49e2e Update README formatting and content
This orders the phase subdirectories by execution order, adds
subheadings, and fixes some markdown formatting issues. This also
replaces all double-spaces after full-stops with single spaces.

Change-Id: I2d5526cbe4a902067fa9cad1456c35d13f81e183
2014-02-27 12:10:06 -05:00
Robert Collins
2843e8a802 Improve local-config proxy handling.
We were applying proxy settings after apt-get install runs are done
in the Ubuntu element, which made it ineffective. Secondly, we were
not applying no_proxy settings to apt, which caused it to fail in
corporate settings. More explicit control may be facilitated in future
but local-config is a DTRT tool, and so we should help it DTRT.

I think I've correctly setup Zypper for this, and I have no idea
how to make the same improvement for Yum (and also Yum currently
doesn't set HTTPS proxies, which may lead to similar reports there).

Change-Id: Idbb9781d64d44b717ea22a25429383fa45d84148
2014-02-28 00:01:11 +13:00
Jon-Paul Sullivan
852cec3789 Enable custom apt.conf in apt-conf element
Allow DIB_APT_CONF to be set to the apt.conf file to be inserted
into the built images.

Change-Id: I5d148ae7286a93e81b3e984c94ba4f089d3a3280
2014-02-26 19:10:23 +00:00
Jonathan Brownell
263e0310dc Add rsync to the package list used by debootstrap
Debian builds fail due to missing rsync in the baseline set
of packages that debootstrap defaults to. Rsync is used by a
variety of tripleo-image-elements and should be included in
disk images by default.

Change-Id: I8d83a53dfab279075e11f9825f15ee960395dd17
2014-02-26 10:53:55 -08:00
Jon-Paul Sullivan
0edfcf6587 Enable simple modification of git repo location
Add the DIB_GITREPOBASE variable to the source-repositories element
to enable global changing of git repository location.

Change-Id: Icfac5e103fce6e5a3f1a2db094144a0ed89fcc33
2014-02-26 13:52:03 +00:00
Jenkins
61d474f2cd Merge "Update pypi element to suggest pypi-mirror" 2014-02-26 08:52:19 +00:00
Ryan Brady
90d416e857 Add NFS package mapping
In Fedora, the package is nfs-utils and in Debian the package is
'nfs-kernel-server'.

Change-Id: I34f793bb6eb43f749bf383a082e90371f8e28219
2014-02-25 19:28:06 -05:00
Jon-Paul Sullivan
8b2325118f Improve usability of the source-repositories cache
* Rename the cache directory for sources

Make the cache directory name match that of the element that creates
it.  This makes it easier to find and more logically implies what
element created the cache directory.

* Add REPONAME to repository cache directory

For better usability add the reponame to the directory created
to cache it.

* Add migration code

Move pre-existing cache directories of the old name to the new name.

Change-Id: Ic62f19acb1746888ccbdf95eebf6e653f3e66357
2014-02-24 20:42:48 +00:00
Ghe Rivero
48e6ceebe9 Fix unbound variable in debian element
Change-Id: Ie4bf86fa0ce387a55f1c390f58e58d17267ae61d
2014-02-24 10:19:30 +01:00
Steve Kowalik
a84611d766 Replace security.ubuntu.com when setting mirror
The current method to rewrite the mirror URL in the ubuntu element will
only rewrite archive.ubuntu.com, which leaves the security URL alone.
This is probably not intended for people who are creating images behind
firewalls.

Change-Id: I54a867e0e9d5a7c94324a5c00ff1a83b4e6e4524
2014-02-24 11:00:24 +11:00
Ben Nemec
004474e93b Generalize install-packages for yum
All of the yum-based install-packages scripts are doing essentially
the same thing, so let's use one script for all of the elements
that depend on the yum element.

Change-Id: I49e8c9b44e41bcf4cb9fa820e8a9179754694a97
2014-02-21 12:00:24 -06:00
Jenkins
6360b46229 Merge "Add 00-fedora-fixup-vim" 2014-02-21 14:31:54 +00:00
Jenkins
86cd539496 Merge "Permit using arbitrary PyPI urls." 2014-02-21 04:43:26 +00:00
James Slagle
959aed3f86 Remove accidental merge marker
Change-Id: If98066c418f64be9f1bdce16558969d800e602c0
2014-02-20 15:10:32 -05:00
Dan Prince
4f795b91ed Add libvirt-bin -> libvirtd to map-services.
We'll need this soon for the Nova TripleO image element.

Change-Id: I9f4284aa503f422828e2ccb56597852b5a0c9591
2014-02-20 14:38:56 -05:00
Jenkins
66ae41756b Merge "Pep8/Pyflakes fixing" 2014-02-20 04:28:41 +00:00
Jenkins
06ecc6c5e8 Merge "Shift debian element to DIB_DISTRIBUTION_MIRROR" 2014-02-20 04:22:26 +00:00
Dan Prince
ea555476cc Make max-online-resize an option.
In fb246a02eb we introduced an
ext4 option to allow root filesystems to be resized up to 1PB.
This appears to cause an ext4 resize2fs bug in some images.

When the issue occurs an image will hit a kernel bug when
cloud-init runs the resize2fs command during first boot:

  kernel BUG at fs/ext4/resize.c:409!

In this commit we add a new option for max-online-resize
which can be used if a really large root partition is
desirable.

The root cause of all this is really a design problem in
DIB/TripleO at the moment in that we shouldn't have to worry about the
max size of the root file system when creating our images.  Ideally we'd
just mkfs on the root file system itself. Much more efficient,
avoids this problem altogether...

I think the best thing to do today to avoid this is make setting
max-online-resize an option in DIB. This will allow us to stick
to the (well tested) ext4 defaults for most cases, and if someone has
need for a large root filesystem they can easily bump the setting. This
may be temporary until we either fix the design... or the ext4 fix is
released.

Change-Id: I371f62555d2753cec48790c8fd811c4342af925c
Closes-bug: #1280709
2014-02-19 08:37:56 -05:00
Dan Prince
21c1a6205b Correct DIB long option parsing
Fixes issues with option parsing. The --min-tmpfs and --image-cache
options where previously broken.

Closes-bug: 1282077
Change-Id: I40c62b16d854335902d1b6b5ceab7f0e1992623a
2014-02-19 08:33:08 -05:00
James Slagle
4072ae232f Add 00-fedora-fixup-vim
We need to update vim-minimal, otherwise when rabbitmq-server gets
installed and pulls in vim-common, we run into:

https://bugzilla.redhat.com/show_bug.cgi?id=1066983

Change-Id: I910cd6c5c5fcfc6f6780b86029b1b4e660dd8d05
2014-02-19 08:32:25 -05:00
Clint Byrum
d03b14b4eb Update pypi element to suggest pypi-mirror
jeepyb no longer contains pypi-mirror.

Change-Id: Ifa905181119b30b1184dde53deaf0a97e2cb2ab2
2014-02-19 12:10:38 +00:00
Robert Collins
1adf3a377e Permit using arbitrary PyPI urls.
The pypi element is cool, but some folk have local network mirrors
which we should permit them to use.

Change-Id: Ie840ad1184e72b0e01966eee0298cfd6511b6c19
2014-02-19 14:05:31 +13:00
Dirk Mueller
0ab2a1300f Pep8/Pyflakes fixing
Just avoiding the error popups in the editor that way.

Change-Id: Ic0cb903dfb0e9eff6b12d004da720919f6f1a009
2014-02-17 22:37:34 +01:00
Steve Kowalik
98fa6c882f Shift debian element to DIB_DISTRIBUTION_MIRROR
The ubuntu element supports simple replacement of sources.list by using
the DIB_DISTRIBUTION_MIRROR environment variable. Drag the debian
element into line by supporting both DIB_DEBIAN_MIRROR and the new shiny
DIB_DISTRIBUTION_MIRROR.

Change-Id: I9d5f8d1e3251965b34e55929182aa601a524fe8f
2014-02-17 14:16:25 +11:00
Jenkins
621376db44 Merge "Remove tox locale overrides" 2014-02-14 14:36:02 +00:00
Jenkins
e9b4ec2104 Merge "Teach cache-url to handle file:// URIs." 2014-02-14 12:23:40 +00:00
Jenkins
cd8082e5dc Merge "Rename Openstack to OpenStack" 2014-02-14 12:12:58 +00:00
Robert Collins
1dfd4b3e44 Revert "Add Fedora DHCP interfaces via udev rules."
This reverts commit 201c9e8527.

This depended on the revert for one-at-a-time.

Change-Id: I05f1f85b8f13a1eea3d5e4b144ff92e0e791bdac
2014-02-14 14:43:09 +13:00
Robert Collins
39e6f7a5c4 Revert "Support adding DHCP interfaces one at a time. "
This reverts commit a1b469b10b.

This broke testenv deployments - it does not yet work on Ubuntu.

Change-Id: I0f74abc6b99da4b8cabca8ed673c606bae7de0e1
2014-02-14 14:42:58 +13:00
Chris Jones
fde4572764 Teach cache-url to handle file:// URIs.
We can now support file:// URIs in source-repositories files and other
places, by ignoring curl's inability to determine an HTTP status code
for them.

Change-Id: Ie226ce05ecb912b23cedc73fd7ba53c0b9c0fe35
2014-02-13 19:43:50 +00:00
Jenkins
b4e2968aea Merge "Add Fedora DHCP interfaces via udev rules" 2014-02-13 16:44:12 +00:00
Jenkins
0d52928a53 Merge "Support adding DHCP interfaces one at a time." 2014-02-13 16:43:47 +00:00
Jenkins
14ad0df6e7 Merge "Don't hardcode environment.d" 2014-02-13 08:45:43 +00:00
Jeremy Stanley
606286f6e7 Remove tox locale overrides
* tox.ini: The LANG, LANGUAGE and LC_ALL environment overrides were
introduced originally during the testr migration in an attempt to be
conservative about the possibility that locale settings in the
calling environment could cause consistency problems for test runs.
In actuality, this should be unnecessary and any place where it does
cause issues ought to be considered an actual bug. Also, having
these in the configuration actively causes older pip to have
problems with non-ASCII content in some package metadata files under
Python 3, so drop it now.

Change-Id: I840f950d2e9f6e1e40af578900e92cedf8f14295
Closes-Bug: #1277495
2014-02-12 19:28:32 +00:00
Dan Prince
201c9e8527 Add Fedora DHCP interfaces via udev rules
Updates the dhcp-all-interfaces element so that
we add new DHCP interfaces using a udev rule
instead of a systemd service.

The previous approach (using the systemd service)
was proving to be problematic when used with
the new Fedora constistent network naming
convention rules (em1, em2, etc.). We aren't using
these device names as a default yet... but we will
need to soon and when we do udev rules seem to be the
best way to avoid racy behaviour when calling
dhcp-all-interfaces.sh from the systemd service.

Change-Id: I87e0aed1f34718e896bd414388886a1f1073b0c0
2014-02-12 12:00:50 -05:00
Dan Prince
a1b469b10b Support adding DHCP interfaces one at a time.
Refactors dhcp-all-interfaces.sh so that if an optional
INTERFACE argument (the first argument) is passed to the script
it only inspects that single interface. If no argument is
passed then the previous default behaviour use used which
causes all interfaces to be inspected.

Also sets PATH so that the commands within the script
can all be found if it isn't set properly (/sbin/ip, /bin/cat, etc.)

This is a move towards using udev rules to add these types
of interfaces automatically.

Change-Id: Ia482c1d3ddce0f0d8d77f9bc3ac76d6924640715
2014-02-12 11:57:56 -05:00
tanlin
d8d81922da Rename Openstack to OpenStack
Change-Id: I65a0af76132fa1375bca25889b90d381fd038988
2014-02-12 17:52:55 +08:00
Jenkins
a3f2836625 Merge "Fix kernel extraction on openSUSE" 2014-02-12 03:18:23 +00:00
Jenkins
eab085af02 Merge "ifquery doesn't exist on Fedora" 2014-02-12 03:11:43 +00:00
Jenkins
983f918804 Merge "Make the MIRROR_TARGET directory if it didn't exist" 2014-02-11 14:38:10 +00:00
Jenkins
0a678da6b6 Merge "Remove unneeded service mapping for mysql on openSUSE" 2014-02-11 14:17:37 +00:00
James Slagle
f760f11050 Don't hardcode environment.d
Don't assume environment.d is always under /tmp/in_target.d. This makes
dib-run-parts more flexible, and less specific to diskimage-builder. For
instance, dib-run-parts is already used by os-refresh-config, but
/tmp/in_target.d/environment.d is never going to exist when it's called
by os-refresh-config.

This is useful b/c elements can now install os-refresh-config scripts
under /opt/stack/os-config-refresh/environment.d to influence how
further scripts are run. Specifically, the OpenSuse packages prepend the
OpenStack user accounts with "openstack-". Instead of checking for which
users exists with an if/else in all the os-refresh-config scripts that
need to do user related things, we can just update the scripts to use
$NOVA_USER, etc. The OpenSuse element can then install a file under
/opt/stack/os-config-refresh/environment.d to set NOVA_USER to
openstack-nova. We could have files that declare defaults as well within
each specific element, or just set a default variable at the top of each
os-refresh-config script.

Change-Id: Iadbfad995da657e2965fd55fc4ba3a88138b4cfc
2014-02-11 08:33:45 -05:00
Jenkins
014e3bf875 Merge "Adjust neutron package install for Fedora" 2014-02-11 09:39:54 +00:00
Jenkins
e1d58046f0 Merge "Add lsof package to all Fedora images" 2014-02-10 12:32:05 +00:00
Jenkins
9295162946 Merge "Add more package name mappings for openSUSE." 2014-02-10 10:49:19 +00:00
Dirk Mueller
af3cf11b27 Add more package name mappings for openSUSE.
Adjust for naming difference on openSUSE.

Change-Id: Ieda36c14b94add4d9877a25224b15563c648d122
2014-02-07 22:56:12 +01:00
Dan Prince
72ca729c67 Add lsof package to all Fedora images
Really useful when debugging.

Change-Id: I0862ad2b97f5fa061aea592f4a267856ac124f65
2014-02-07 16:29:37 -05:00
Dan Prince
01e25c378b ifquery doesn't exist on Fedora
Updates dhcp-all-interfaces so that we avoid using
ifquery on Fedora to determine if an interface exists.

Adds a new config_exists function which simply looks for
the ifcfg config file on distro's that use netscripts.

Change-Id: Ie55524b83820fe4fab28cc9d3f7e08ca2e42c182
2014-02-07 13:33:35 -05:00