1045 Commits

Author SHA1 Message Date
Jenkins
6bbd4bf1ca Merge "Fix gate" 2015-11-20 21:23:08 +00:00
Sam Yaple
ea17c2db72 Fix gate
A previous commit [1] removed the glance data container. Although this
worked at the time (as evident by it passing the gate) the drop root
patches merged after the gate patch causing the glance service to
not have the proper permissions to create this needed directory

[1] I7f2f5979b01807275908699d1243756cb97d3588

Change-Id: I5044de8d348e401a50970fd77671a79d35d2d595
2015-11-20 20:29:06 +00:00
Andrey Shestakov
df02ffe1c5 Fix /etc files location for ironic-base building from sources
Ironic config files should be palced to /etc/ironic/*

Closes-Bug: #1518433
Change-Id: Ic82dbb9a28ed3adb6bfca2d0f715da3a7bbc4698
2015-11-20 21:46:42 +02:00
Paul Bourke
2e50ead57e Fix missing policy.json in Magnum
The magnum api falls over on a request without this file in place

Change-Id: Ic7ff8af22c3142d93e0dcf2b2ed5455685dec658
Closes-Bug: #1517152
2015-11-18 12:10:38 +00:00
Jenkins
4cddefe7d7 Merge "Fix namespace regression for neutron" 2015-11-18 02:14:16 +00:00
Jenkins
3e97fdf4d8 Merge "Drop root for Magnum" 2015-11-18 00:50:40 +00:00
Jenkins
e63c0458f5 Merge "Remove old config-external.sh scripts for magnum" 2015-11-18 00:48:10 +00:00
Jenkins
bfcbdc41f8 Merge "Use pip upper-constraints in magnum-base" 2015-11-17 22:20:35 +00:00
Jenkins
cb96171ef8 Merge "Fix issues in Glance filesystem backend" 2015-11-17 19:36:03 +00:00
Paul Bourke
1a536124ad Drop root for Magnum
This change ensures commands run in the magnum containers are done as the
'magnum' user rather than root.

Change-Id: I18e2febae98aae6d6fc6c61cc2817442f408cb75
Partially-Implements: blueprint drop-root
2015-11-17 18:02:18 +00:00
Paul Bourke
9f6106c8f5 Remove old config-external.sh scripts for magnum
These are no longer used.

Trivial-Fix

Change-Id: Ia4dced3b8ac8512097f5cafbb1b06661c6f3eb88
2015-11-17 17:39:25 +00:00
Paul Bourke
1d0b8afa8b Use pip upper-constraints in magnum-base
Change-Id: Ibb5636d897c2b9177c54dfc13f6193e00107776b
Closes-Bug: #1517144
2015-11-17 17:13:15 +00:00
Paul Bourke
988c4f23f1 Fix issues in Glance filesystem backend
The drop root change for Glance highlighted the fact that we were
binding volumes from glance_data into the wrong container - it was
glance_registry whereas it should be glance_api. This would result in
all images being lost if the glance_api container happens to restart.

Also, we need a sudoers file to chown the file backend dir to the glance
user.

Change-Id: If04337045bb94b3126e48d1f5bf0ea29e20373ae
Closes-Bug: #1516729
2015-11-17 09:42:39 +00:00
Angus Salkeld
2f1c00a467 Add support for loading kolla config from ENV
Implements: blueprint zookeeper

Change-Id: Ibabcb5d6d304be9290633338c513f16651d4479a
2015-11-17 07:51:32 +00:00
Sam Yaple
baf9d93358 Fix namespace regression for neutron
Due the to way network namespaces work, they will not survive a
container restart. This is not an issue related to Kolla or Neutron
but rather an issue with how network namespaces work.

This is putting back into place a workaround that was in correctly
removed in the past. We simply cleanup the namespace cruft when the
neutron-agents container restarts thus avoiding this issue.

Change-Id: Ic16f2f766b4fa46347ea14a1ece5a4653c69d779
Closes-Bug: #1511216
2015-11-16 20:56:39 +00:00
Britt Houser
e9c47f3d64 Add usermod to Zaqar container
When we dropped root, we forgot the usermod.  Updated.

Change-Id: I72a452c9b3b6a9aac0a8edd073887a1b79c34e8e
2015-11-14 12:17:48 -05:00
Jenkins
fb06344aee Merge "drop root on memcached" 2015-11-14 17:11:23 +00:00
Britt Houser
66c15ce55e drop root on memcached
This patch add the USER directive to the memcached container.
It also removes the -u from the command line to launch
memcached, since it will already be run as that use.

Change-Id: I87d782a424df99fe1b5694debafa3c0c4a9aba27
Partially-Implements: blueprint drop-root
2015-11-14 11:38:30 -05:00
Jenkins
a27e1f895b Merge "Revert "Drop root for Horizon service"" 2015-11-13 22:06:20 +00:00
Jenkins
f54c5bee3a Merge "Drop root for Zaqar service" 2015-11-13 20:14:01 +00:00
Jenkins
4650d81341 Merge "Add ZooKeeper support in kolla-ansible" 2015-11-13 19:28:01 +00:00
Josh Lothian
63d5e9b552 Drop root for Zaqar service
Change-Id: I59797a8539406e478f6953a9aa0c933e73eb5892
Partially-Implements: blueprint drop-root
2015-11-13 13:20:36 -06:00
Michal Rostecki
1dfb791116 Add ZooKeeper support in kolla-ansible
In kolla-mesos, ZK will be used for storing information about
actions done in bootstrap.

Change-Id: Id7067a493b457cf7b73eb007852df7b13f4363b3
Partially-Implements: blueprint zookeeper
2015-11-13 19:39:07 +01:00
Jenkins
84b6f7edc4 Merge "Add Ansible support for Magnum" 2015-11-13 17:01:04 +00:00
Michal Rostecki
2cd5d9ed74 Add Ansible support for Magnum
Change-Id: Idb25ac4d3148c9b9400cf675ac2e47d35cce6224
Implements: blueprint ansible-magnum
2015-11-13 11:31:34 +01:00
Sam Yaple
6ec1fabf65 Revert "Drop root for Horizon service"
This reverts commit f9ccb1c8829cef551b875c7c387530e7980414a7.

There are many issues with this patch that prevents it from working
under numerous circumstances. The implementation is entirely busted
on Ubuntu. Additionally, best practice for apache is to run as root.
Apache itself does the privlege dropping.

Change-Id: I4395debb7d32223fb3752a6d3e7c4d7672d29916
2015-11-13 08:53:49 +00:00
Jenkins
52bd56e686 Merge "Drop root privileges for rabbitmq" 2015-11-13 07:53:06 +00:00
Ryan Hallisey
22def41d37 Drop root privileges for rabbitmq
Drop root privileges for rabbitmq.  Only the rabbitmq user
will be able to execute chown of /var/lib/rabbitmq.

Change-Id: I546e6b475a8462bfbc75972854e1fee64f96d9cb
Partially-Implements: blueprint drop-root
2015-11-12 11:38:17 -05:00
Sam Yaple
ea9d5cd067 Move USER operation after footer
The USER operation affects all docker commands after it. This causes a
problem with our {{ include_footer }} implementation since commands in
that footer may require elevated permissions to perform.

In the current implementation I can no longer remove my proxy settings
once the USER has been changed.

Change-Id: I9b2bab5a15f595f6d52a46c64ddf59ba5608b938
Partially-Implements: blueprint drop-root
2015-11-12 14:34:09 +00:00
Steven Dake
4c9e15b94e Drop root privileges for mariadb
Drop root privileges for mariadb.  This isn't perfect.  If somemone
breaks out of the container and can run sudo within the contianer,
it would be possible to replace the root credentials of the database.

Any container that uses sudo suffers from some extra attack vector
related to the sudo command.  That said, the sudo commands are
locked down to minimize harm.

Change-Id: I4b3573725d940bb8aa90d43a6235d8cf7d30fc64
Partially-Implements: blueprint drop-root
2015-11-12 03:12:40 -05:00
Steven Dake
09e9b1be33 Move the mariadb expect code to a script
Atleast in a script, sudo can be made to only allow the script to
run from the mysql process in the future, versus all the proceesses
being able to be executed as root presently.

Change-Id: I030b57086e37e4dc8f668f98c04335d94ab9d2b0
Partially-Implements: blueprint drop-root
2015-11-11 18:42:07 -05:00
Steven Dake
f9ccb1c882 Drop root for Horizon service
Drop root privileges for Horizon service.  It is necesssary to set
a capability on the filesystem to allow binding to port 80 as a
non-root user.  I have tested this works correctly from a registry
on both CentOS and Ubuntu.

Change-Id: I4c26f28bb28b6633784e6842f3423a2425332c27
Partially-Implements: blueprint drop-root
2015-11-11 18:41:56 -05:00
Jenkins
b6212875d3 Merge "Install keystoneauthv1 in openstack-base image" 2015-11-11 22:59:19 +00:00
Jenkins
d9f49d1026 Merge "Drop root for kolla-ansible" 2015-11-11 22:36:36 +00:00
Jenkins
1a6050e5e5 Merge "Clean up horizon httpd pid files for RPM distros" 2015-11-11 22:34:26 +00:00
Steven Dake
87c5b6b86b Install keystoneauthv1 in openstack-base image
Lots of tools rqeuire keystoneeauthv1 not just horizon

TrivialFix

Change-Id: I35eb958e35500b04657679371019f2e6f3c2f2dd
2015-11-11 13:49:54 -07:00
Steven Dake
d11b8f260b Drop root for heat
Drop root user for heat containers.

Change-Id: Ib07c0193f97bb18cc6154b4015b4056fd983f6c1
Partially-Implements: blueprint drop-root
2015-11-11 14:50:02 -05:00
Steven Dake
5e15ee16de install openstack-heat-common in heat-base
the openstack-heat-common package installs the Heat UID/GID.
This is necessary pre-work for drop-root for heat services.

Change-Id: I247b0209248de144d20f5245973833be5cd8f14f
Partially-Implements: blueprint drop-root
2015-11-11 14:50:02 -05:00
Jenkins
d4379a5cde Merge "Drop root for designate" 2015-11-11 18:35:33 +00:00
Paul Bourke
0f315a0ed0 Drop root for kolla-ansible
This change ensures commands run in the kolla-ansible container are done
as the 'ansible' user rather than root.

By default Ansible tries to write it's temporary files to $HOME/.ansible
on the target, which in most cases won't exist when run as the new user.
Hence we now supply the kolla-ansible container with an ansible.cfg, to
tweak the remote_dir option to /tmp.

Change-Id: I838a8c8cd0c7dc1aeca4d12e38c346f252170e7c
Partially-Implements: blueprint drop-root
2015-11-11 18:04:02 +00:00
Paul Bourke
bac1235ed2 Clean up horizon httpd pid files for RPM distros
(apply same fix that we did for keystone, to horizon)

In some cases we're seeing httpd not cleaning up properly after itself,
which results in the horizon container failing to restart. This is
confirmed to happen on rpm based distros, but have not had any reports
on Ubuntu.

Change-Id: I8ece6da1a8a1180730d68be0d129a656ddcede07
Closes-Bug: #1515214
backport: liberty
2015-11-11 11:46:24 +00:00
Michal Rostecki
c691334181 Drop root for designate
Change-Id: I1df05608be62cc008ccef1ca88d0b37983568d22
Partially-Implements: blueprint drop-root
2015-11-10 10:41:13 +01:00
Martin André
15290dc6cc Horizon rdo package requires python-keystoneauth1
Change-Id: I0d98399d7d573ea43689746dda59a647c307b25f
Closes-Bug: #1514697
2015-11-10 17:33:31 +09:00
Jenkins
610604e4b3 Merge "drop root for glance" 2015-11-09 18:04:47 +00:00
Jenkins
cb578df3b0 Merge "Base image changes for drop-root" 2015-11-09 18:02:50 +00:00
Steven Dake
bd9e8c22d7 drop root for glance
This uses the grouping feature of sudo to limit the amount of times
the base sudo file has to be modified to only once.  The container
contents always runs as the user root, except the software which is
controlled by Kolla.  This software may run as root, but it has
undergone a security audit and preserves permissions of the correct
files and does not permit the glance user to write any of the
set_config.py control files.

Change-Id: Ie3cd23edcde5b408a8f66970456279a1b15028e0
Partially-Implements: blueprint drop-root
2015-11-09 11:00:29 -05:00
Steven Dake
6cf5928ff1 Base image changes for drop-root
The reason we are doing drop root is so that a network exposed
software component (i.e. glance) cannot be used to affect the
immutability of the container which it runs in.  I have tried
several different approaches and this is the only approach which
puts glance in PID=1 while ensuring no files may be written by
the glance process in the container image except for the log files.

Change-Id: Ifd3c8c361b78d0e4791dade3afa6435290407c41
Partially-Implements: blueprint drop-root
2015-11-09 11:00:26 -05:00
Angus Salkeld
33d39f2942 Fix validate-all-maintainer.sh to look for Dockerfile.j2
And fix the fallout.

Change-Id: Iccad3f4fdb0a6a7c14246df3408cae0425b833a5
2015-11-09 15:20:13 +10:00
David Moreau Simard
4a1db7a08d Switch to RDO untested master repository
RDO does not yet provide a CI tested Mitaka repository.
As such, the current-passed-ci repository is the last tested
repository before the stable/liberty branch was cut.

To be able to test against the latest packages, we need to
use the untested repositories until the CI tested repository
is in place.

TrivialFix

Change-Id: I4a125eb3c84fa790746a9a8eca19e4fb2d9ecf38
2015-11-06 12:30:18 -05:00
Martin André
2405110f3d Remove mysql-devel cruft
This was conflicting with Percona-Server-devel-55 and broke centos
source build for openstack-base image.

Backport: Liberty
Change-Id: Ia2bb2106038e8e2eadb6668f4ae1ad1d95710c09
Closes-Bug: #1513711
2015-11-06 15:07:55 +09:00