aboutsummaryrefslogtreecommitdiff
path: root/kolla/image
AgeCommit message (Collapse)AuthorFilesLines
2017-07-10Fixed the invalid link in the kolla/image/build.pyTaeha Kim1-1/+1
Change-Id: I7bd17624139e1dbd5905ddc2be4436923277ebca Signed-off-by: Taeha Kim <kthguru@gmail.com>
2017-07-05Add new --skip-existing option to kolla-buildMartin André1-6/+17
This new option allows to skip images that are already present in the docker cache. Change-Id: I202c70864f8aa86abd882240beb7f6525963e625 Closes-Bug: #1694302
2017-06-30Merge "Upgrade from docker-py to docker"Jenkins1-1/+1
2017-06-27Merge "Skip [plugins,additions]-archive for binary builts"Jenkins1-20/+21
2017-06-21Upgrade from docker-py to dockerHongbin Lu1-1/+1
The pypi package 'docker-py' [1] has been renamed to 'docker' [2]. It is better to move to the new 'docker' package because the old package will be deprecated and all the new features will go into the new package only. Package 'docker' has been added to requirements [3]. The old package 'docker-py' is still allowed to be in the global requirements during the transition period but it should be removed after all or most of the projects finsih the migration. [1] https://pypi.python.org/pypi/docker-py [2] https://pypi.python.org/pypi/docker [3] https://review.openstack.org/#/c/423715/ Change-Id: I3ffd8bb6461e8b7edacc5e833754f00c4249b854
2017-06-16Merge "kolla-build --list-dependencies use json, not pprint"Jenkins1-2/+1
2017-06-16Merge "kolla-build log to stderr"Jenkins1-1/+1
2017-06-09Merge "Fix inconsistent build task attempt logging"Jenkins1-6/+2
2017-06-04Merge "Add dots at first line in docstring"Jenkins1-8/+8
2017-06-02kolla-build --list-dependencies use json, not pprintSteve Baker1-2/+1
kolla-build --list-dependencies uses pprint, which prints almost-but-not-quite json. This makes it hard for other tools to parse its output. This change switches to a json output with an indent of 2. If there is interest in a default output which is friendly to both humans and software, YAML might be more appropriate. Change-Id: Icaead5a62a2d6510965524f68fb57dcf7494e618 Closes-Bug: #1694888
2017-06-02kolla-build log to stderrSteve Baker1-1/+1
Logging to the console would traditionally go to stderr so that stdout can be parsed by other tools for structured output. Because logging currently goes to stdout, it is difficult to parse the outputs of the following: kolla-build --format json kolla-build --list-images kolla-build --list-dependencies This change logs to stderr instead. Change-Id: Ib3995431408f3c2a9c1949ef72954f93e2bccddc Closes-Bug: #1694593
2017-05-22Fix inconsistent build task attempt loggingKurt Taylor1-6/+2
Change-Id: I5fee4782202fc8e5094b2be05e88f70706596078
2017-05-16fix handling of delorean on non-x86Marcin Juszkiewicz1-1/+1
Python 2.7.5 != 2.7.9 when it comes to handling None. So sort disabling delorean-deps.repo on non-x86 in other way. Change-Id: Iae86c391c7dcf006538d39d9b447f47171b8b541 Partially-Implements: blueprint multiarch-and-arm64-containers
2017-05-11Support non-x86 architectures (aarch64, ppc64le)Marcin Juszkiewicz1-0/+3
Based on ppc64le changes by Sajauddin Mohammad [1] 1. https://review.openstack.org/#/c/423239/6 Tested with centos, debian, ubuntu on aarch64 and ppc64le. Partially-Implements: blueprint multiarch-and-arm64-containers Change-Id: If0ccc58d436b2468cd477c222ebc2fe0073206e9
2017-05-10Skip [plugins,additions]-archive for binary builtsMartin André1-20/+21
Skip the creation of `plugins-archive` or `additions-archive` for binary builds as they are only checked-out as part of the source build process. Doing so also has the nice side-effect of failing the build in case someone accidently includes an 'ADD plugins-archive /' instruction to the binary section of a Dockerfile. Change-Id: I7442fcd9677466dd0878e124402b4d4170a1ab68 Related-Bug: #1681345
2017-05-04Add dots at first line in docstringEduardo Gonzalez1-8/+8
Running flake tests raises warning for: "First line should end with a period" Change-Id: I9714b350900500c997ef0e54e9830e232fcd6ce7
2017-05-03Override image's meta info.Jawon Choo1-1/+5
centos based images have wrong label info, these changes fix own image's name and build-date. Change-Id: I1d13f8f386c8db12b5fbe5f8ecbbf9e3fbb4ba1c Closes-Bug: #1680341
2017-04-01Merge "add base_arch variable for future non-x86 work"Jenkins1-0/+2
2017-03-30Merge "Allow the use of previously built parent images"Jenkins1-7/+34
2017-03-30add base_arch variable for future non-x86 workMarcin Juszkiewicz1-0/+2
This variable will allow to select which target architecture has to be used. Partially-Implements: blueprint multiarch-and-arm64-containers Change-Id: I71ddb7ef57c64d2505cac96724b1ab6772a57d6a
2017-03-29Allow the use of previously built parent imagesPaul Bourke1-7/+34
Consider the case where you have a set of tagged / released images to production, and you want to apply a small hotfix, security patch, etc. to one of them, say keystone-ssh. Rebuilding keystone-ssh will cause a rebuild of base, openstack-base, and keystone-base, potentially pulling in updated packages / new dependencies, unless you have access to the exact machine they were previously built on. Ideally you want to use the exact parent images that are in production. This patch adds a new build argument '--skip-parents', which will result in only the image(s) specified by the regex and their children to be built. Parents are expected to exist either on machine or in a registry. Change-Id: I79d5f0b422f48d2dc36ae85dfa21668cf8177837 Implements: blueprint image-build-depth
2017-03-03Merge "Add SNAP support when finding Docker images folder"Jenkins1-1/+6
2017-03-01Add work-dir command-line optionJavier Pena1-5/+10
The working directory was previously generated as a temporary one, but there may be cases when we want to specify a directory, for example if we want to generate the Dockerfiles and then do some parsing on them. Change-Id: Ic332328913924bcb3d0dfa4d473e796050fc14b3
2017-02-23Improve kolla image build script for finding parent imagesChris Suttles1-1/+8
This change updates the image script to search for the parent image via the Docker 'FROM' tag throughout the Dockerfile. The script previously checked for parent name of an image, assuming that first line of Dockerfile always starts with FROM, but that is not always the case when using custom Dockerfiles. Change-Id: I176d99f4e4896b64435e495526154c8f4c684839 Closes-Bug: #1656206
2017-02-21Merge "Allow for image additions archives (as well as plugins)"Jenkins1-25/+73
2017-02-16Add SNAP support when finding Docker images folderSaverio Proto1-1/+6
Closes-bug: #1665265 Change-Id: I046a93de72666eae11cb88eb4577c97935f72520
2017-02-12build: sort list of built/failed images before printingMarcin Juszkiewicz1-2/+2
I am building all images as test for my non-x86 support patch. Several images fail for misc reasons. I am tired of having to copy/paste 'kolla' output for manual sorting to find out which built, which failed. Change-Id: I2ed9c7353040106650cbffb04eca8877fb7fc187
2017-01-18Merge "Support filtering output of --list-images"Jenkins1-1/+5
2017-01-18Merge "Support for multiple override files"Jenkins1-3/+15
2017-01-17Merge "Py3 and py2 implementation for kolla/image module"Jenkins1-1/+2
2017-01-17use static uid/gid in imagesSam Yaple1-0/+15
This centralizes all user and group creation into a single source. This will fix any current and furture uid/gid mismatches (such as with nova-libvirt). In the process, we also unify users between the distros in a standard way. The users in the following containers change from thier defaults: Ubuntu: _chrony user is now chrony Ubuntu: memcache user is now memcached All: qemu user is used for ownership and socket permissions All uid and gid numbers are customizable via kolla-build.conf Co-Authored-By: Kris Lindgren <klindgren@godaddy.com> Change-Id: I120f26ab0683dc87d69727c3df8d4707e52a4543 Partially-Implements: blueprint static-uid-gid
2017-01-16Py3 and py2 implementation for kolla/image moduleSurya Prakash Singh1-1/+2
This commit addresses the changes in kolla/image directory for better openstack python coding style. unittest also added for corresponding changes. Reference:- https://wiki.openstack.org/wiki/Python3 Change-Id: I8be60ebd214ac8ab400cc633f8e6005fb8760c24 Partially-Implements: blueprint support-python-35
2017-01-13Support filtering output of --list-imagesMartin André1-1/+5
In an effort to be more consistent in the behavior of kolla-build, only return matched images in the output of kolla-build --list-images. Change-Id: I583e20f181535fa1879730cbe88dd76276c08a80 Closes-Bug: #1656146
2017-01-06Support for multiple override filesMichal (inc0) Jastrzebski1-3/+15
To use multiple override files run --template-override f1 --template-override f2. One caveat is it won't work well if both modify same variable/block. One will override another, so if both overrides tries to add pkg to horizon tpl, only second package gets installed Change-Id: I8d2937c2dad83d3ec94efa6d9c9849a922c0cef6
2017-01-05Allow for image additions archives (as well as plugins)Joshua Harlow1-25/+73
It is quite useful to be able to add additional items (such as jenkins build information) into the image but the only way to do this seems to be via plugins archives. Using these for such information ends badly when building neutron (because those *plugin* archives need to contain setup.py files) so this proposes a new mechanism to put files that are not python plugins but are auxilary useful data to put in the image (such as the jenkins data mentioned above). Change-Id: Ica8b5750bd239e023f14225190e68dab75519d36
2017-01-03Not to pull the base images when building.dupengfei1-1/+1
Add --pull/--nopull parameter for kolla-build, when --nopull is given and the base image is already loaded, The docker-engine will not attemp to pull a newer version of the image. This makes sense when the registry server of base images is unreachable. This feature is as same to setting "image_pull_policy" to "IfNotPresent" while building images. The reason why I create this feature is that, even if I have setted base_distro_tag to a stable tag, e.g. "7" or "2016-12-13", docker still have to wait much time to fetch the version, and return failure when registry server is unreachable. This is a feature of docker build --pull=True. Change-Id: If1bd08763fb757b4f090a3163dd1dbfb8fc531d3 Implements: blueprint docker-build-nopull-base
2016-12-02Add ability to output the things built/failed/not buildJoshua Harlow1-2/+20
Instead of having users of kolla image building grep the output of kolla (or grep `docker images` before and after kolla is ran) to find what was actually built have kolla be able to write exactly what was built (thus avoiding the whole docker and grep stuff). Closes-Bug: #1640973 Change-Id: I11c031b4ded2ff780fa3ceb809a2ee232b36100c
2016-12-01Don't process/queue children not matchedJoshua Harlow1-0/+2
It seems like children that are unmatched are still submitted onto the queue (and then they don't do anything) when we can just avoid that processing in the first place by just not submitting them in the first place. Change-Id: I5d576faab25b3a47b395b9f627b131370d31e191
2016-11-25Remove --include-header and --include-footer parameterTin Lam1-8/+0
In Newton, kolla moved to Dockerfile customization, and the parameters --included-header and --include-footer were marked deprecated. This patch set removes them in the Ocata release. Change-Id: I3263c305bf619ab47a31cf4eafe5d4fcfa4aec17 Closes-Bug: #1643967
2016-11-16Merge "Extract kolla exceptions into a single exception.py file"Jenkins1-21/+6
2016-11-12Extract kolla exceptions into a single exception.py filelijing1-21/+6
Change-Id: I03388360b6ac735d5a6f380a7956cd91ab449131
2016-11-11Merge "Show the rendered docker file"Jenkins1-1/+5
2016-11-10Merge "Skip queuing build tasks for UNMATCHED images"Jenkins1-0/+5
2016-11-08Show the rendered docker fileJoshua Harlow1-1/+5
It can be quite useful (especially while debugging) to see exactly what the final rendered Dockerfile actually is; so when it is being rendered, log it at DEBUG level (so that users running with DEBUG) can see it. Change-Id: I28b6f49a7d2f01d155f7885b6ab275c03c4e14af
2016-11-07Skip queuing build tasks for UNMATCHED imagesJoshua Harlow1-0/+5
Closes-Bug: #1639989 Change-Id: I7bad2b784d2ac02a5af0d790ea32d35f90a681ec
2016-11-07Merge "Load all sections defined in code and conf file"Jenkins1-1/+4
2016-11-06Merge "Fix plugin parsing for base images"Jenkins1-1/+1
2016-11-05Load all sections defined in code and conf fileJeffrey Zhang1-1/+4
oslo.config has two method, _groups and list_all_sections. the former return all sections defined in config file and the latter one return all sections defined in code. Change-Id: Ib05a6dffc2463fd30f183ae5bfb3fc20f475a0bc Closes-Bug: #1639323
2016-11-04Fix plugin parsing for base imagesPaul Bourke1-1/+1
If we try to add a plugin to a base image, e.g. [neutron-base-plugin-neutron-fwaas] type = git location = https://github.com/openstack/neutron-fwaas reference = master The build will fail as it parses the above as both "neutron-base-plugin-neutron-fwaas" and "base-plugin-neutron-fwaas". Update the regex to ensure the image name is anchored to the beginning of the conf section. Change-Id: I4099ebd0d25cd28a9bb3bdc4fcfbf311ce22a3fd Closes-Bug: #1638900
2016-11-03Remove Fedora supportChristian Berendt1-5/+1
Closes-bug: #1616387 Change-Id: Id97f88b9baa3d48d33ce120962450a374282d044