Commit Graph

39 Commits

Author SHA1 Message Date
OpenDev Sysadmins eba36ec408 OpenDev Migration Patch
This commit was bulk generated and pushed by the OpenDev sysadmins
as a part of the Git hosting and code review systems migration
detailed in these mailing list posts:

http://lists.openstack.org/pipermail/openstack-discuss/2019-March/003603.html
http://lists.openstack.org/pipermail/openstack-discuss/2019-April/004920.html

Attempts have been made to correct repository namespaces and
hostnames based on simple pattern matching, but it's possible some
were updated incorrectly or missed entirely. Please reach out to us
via the contact information listed at https://opendev.org/ with any
questions you may have.
2019-04-19 19:51:34 +00:00
Corey Bryant f058b9383d In test cleanup, only delete DBs if they exist
Change-Id: I892b7f8a3dfac2e84fa39ba95962eee586b88286
2017-10-25 16:22:44 -04:00
zhangbailin 9032dfec2f Replace http with https for snap-nova document
Update doc links according to OpenStack document migration,
Use https instead of http for docs links

Change-Id: I35a285e164e8de8f6634188be131083b4c8a0f1f
2017-09-05 02:13:19 -07:00
Pete Vander Giessen 96350c2167 Added config files to snapstack_test.
This helps us not break when transitioning to using the new version of
snapstack, with the config files for each snap in the individual
steps, rather than in a config step.

Change-Id: I2d827e6efbaa098805fb81bf6db6d52a67b50b97
2017-08-11 20:55:15 +00:00
Jenkins 7f1673673d Merge "Added config files to snap." 2017-08-10 20:21:17 +00:00
Pete Vander Giessen 6f18583c92 Added config files to snap.
This is part of a transition to storing the config files in the snap,
rather than in snapstack.

Also updated .gitignore to ignore emacs temp files and snapcraft
cruft.

Change-Id: I917767c08e0daebdeb2392f2fc74ca3a3a1c57ac
2017-08-10 19:30:35 +00:00
Corey Bryant cbd4747bcf Update README snap install command
This snap is now being published to ocata/edge only.

Change-Id: Ifd5ad2299d2b9623e3cfb0b12b940c9858f503af
2017-08-09 17:08:08 -04:00
Pete Vander Giessen c614d0cc5b Updated proxy env var passthrough in tox.ini
We made a breaking change to snapstack. SNAP_BUILD_PROXY ->
SNAPSTACK_HTTP/S_PROXY.

Change-Id: I700e1772e58b026b72a873dee9400405176877d4
2017-08-08 13:45:09 +00:00
Pete Vander Giessen abebe58008 Added snapstack test.
Tweaked tox.ini to invoke snapstack, and added test_snapstack.py to
tests dir.

Also added nova.sh to nova/tests, as part of the plan to move
those scripts from snap-test to the individual snaps.

Change-Id: If52e45bbef18a3ad7da993c93eb78f8aea687c5b
2017-07-27 18:58:36 +00:00
Corey Bryant 4d6726561a Use auto-alias for nova-manage
The current snaps now have well-known aliases defined at install time
for commands [1]. This means we can drop the manual alias definition
from snapcraft.yaml and the instructions for setting it up.

When building/installing locally users can still create the alias
with 'snap alias'.

[1] https://forum.snapcraft.io/t/auto-aliases-for-openstack-base-snaps/1146/6

Change-Id: Iab9fce6b31aaf4d135317814a3ef03985936a858
2017-07-11 20:22:22 +00:00
Corey Bryant fe3291caf8 Drop browser-support plug from nginx
The browser-support plugs doesn't appear to be necessary for nginx.

Change-Id: I5f7bd209148b9a33fd1bb7bb4b86d6c192e34a4f
2017-06-22 23:51:54 +00:00
Corey Bryant da4138e3f5 Switch back to strict confinement
The following are included in the switch to strict confinement:
* Set snapcraft.yaml confinement to strict and restore/update plugs
* Drop building of python as it's not required for strict snaps
* Switch back to running apps under root
* Patch setgroups from ngnix since it's not covered by a plug
* Build libxml into snap

Change-Id: Ibd2e3c625ceb92cb4b6dd9f0c9a9012baf7c53a5
2017-06-22 00:41:19 +00:00
Corey Bryant f011198f5b Enable nova-placement-api config and logging
nova-placement-api is a bit tricky. The wsgi application doesn't accept
CLI arguments, so we can't pass --config-file, --config-dir, or
--log-file via uwsgi's pyargv. Additionally, nova-placement-api doesn't
pass the [keystone_authtoken] from the config file found in
OS_PLACEMENT_CONFIG_DIR to keystonemiddleware.

We continue to use the OS_PLACEMENT_CONFIG_DIR environment variable to
point at the default nova.conf in $SNAP/etc/nova.conf. This default
nova.conf includes logdir=$SNAP_COMMON/log/, enabling nova-placement-api.log
to be written to the correct directory.

Passing [keystone_authtoken] to keystonemiddleware is fixed in oslo.config.
The prior commit titled "Patch (_COMMON) dirs into oslo.config defaults"
includes a patch for this. keystonemiddleware gets the [keystone_authtoken]
config via oslo.config's find_config_files() and find_config_dirs(), which
are patched to include the $SNAP and $SNAP_COMMON config directories.

Change-Id: I02e2a5d9df91eb8cbf36beb474809bc1e80fe80b
Closes-Bug: 1696830
2017-06-22 00:40:53 +00:00
Corey Bryant 4d3bfe28b4 Patch (_COMMON) dirs into oslo.config defaults
Change-Id: I86dd0410a179620b6b9a121e776a59bd69f6e136
2017-06-22 00:40:22 +00:00
Corey Bryant 890c993bb5 Switch from conf.d to <project>.conf.d
This aligns with the extension that oslo.config expects.

Change-Id: I2b0e75c886fc1710d88a7b20b67e1ff220cfad56
2017-06-14 15:29:54 +00:00
Corey Bryant 86e6d6d8ed Enable override of config files and drop copyfiles
Enable the ability for default config files to be overridden for each
entry point type (simple, uwsgi, and nginx).

Also refresh the README while documenting how default config files can
be overridden.

Finally, drop copyfiles from snap-openstack.yaml for nginx, and modify
the nginx template files such that we can install them in $SNAP_COMMON
while pointing them at additional default config files in $SNAP.

Change-Id: Ia4496aa593d7e695c2451153c12c3dfd0c2ee989
2017-06-05 11:00:10 -04:00
Corey Bryant e5c9bc4969 Use both SNAP and SNAP_COMMON with --config-file
Ensure that uwsgi configuration file is rendered as part
of the endpoint to pickup required pyargv context variable.

Change-Id: Ic55a4851bd2d82d868f54af9d225f3287c115be5
2017-05-19 08:55:47 +01:00
Corey Bryant c210ae6e8e Drop privileges when running commands
Drop privileges to a regular user when running commands defined
by this snap. In most cases this is done prior to executing the
command.

NGINX is an exception in that the command will be run as root,
allowing the the master process to bind to ports. The nginx.conf
template is configured to then drop privileges for worker processes,
which do all work, such as handling network connections, r/w to
disk, and communication with servers.

Change-Id: Ifa55c4f36a3e5a8e0e2681f1aa229b6ba42a7e76
2017-05-18 16:13:12 +00:00
Corey Bryant f3212259d4 Compile nginx from source
Compile nginx from source and cleanup nginx.conf template.

Change-Id: I0adce7bdfb673853952cb58734fc2c35f9724e04
2017-05-18 15:55:34 +00:00
Corey Bryant 967d6c6750 Add nova-placement-api
Change-Id: Iabf1e20e5026483777326a78c9814ee67e552f21
2017-05-03 18:59:49 +00:00
Corey Bryant 75c26b96ef Base this snap on stable Ocata tar file
Change-Id: Ief987b0894b64ef46d8a6b8215dd9fede8278de8
2017-05-03 18:59:17 +00:00
Corey Bryant 7858086433 Add libxml2-dev and libxslt1-dev to build-packages
Change-Id: If09acc536b7db588e7a7242b711b67d6d37c6ee1
2017-05-03 18:11:51 +00:00
Corey Bryant 0c30243b11 Go back to installing files to SNAP_COMMON
The symlinks setup key is dropped, and SNAP_COMMON is used as the
root directory where setup dirs, templates, and copyfiles are
installed. This aligns better with how snaps should behave.

Change-Id: I9b18b703f3f00f5ac8db61253e8abfe024a51b50
2017-04-24 12:55:49 +00:00
Corey Bryant b0eeeed2fa Compile python and drop environment dictionary
Classic python snaps require python to be compiled from source.
Additionaly, move away from using the environment dictionary
until it is fully supported by snapd. Finally, use a fixed python
path in order to get the correct site-specific config.

These changes were recommended in the following bug:
https://bugs.launchpad.net/snapcraft/+bug/1675479

Change-Id: I5505bb19b026589c94df4c2753a7ee4b7e2f8fb1
2017-04-24 12:53:41 +00:00
Corey Bryant 9569635bfb Touch namespace package __init__.py files
This is a work-around for https://bugs.launchpad.net/bugs/1675479,
where namespace packages aren't installed correctly.

Change-Id: Ia915ba667bc983ca78d0d9ba8a21cbf3c16644d0
2017-04-24 12:50:28 +00:00
Corey Bryant 1388b583b5 Switch to classic confinement
Classic confinement allows the snap to behave like a traditionally
packaged application with full access to the system, and enables the
use of traditional directories such as /etc and /var/log.

We will continue to store all of the snap's files in $SNAP* directories.
This enables the snap to cleanup after itself if it is removed. However,
traditional directory locations are symlinked to their corresponding
$SNAP* directories.

For example, nova configs are installed in $SNAP_COMMON/etc/nova
which has a symlink at /etc/nova.

The nova apps then use the traditional directories when running
commands and services.

Change-Id: Ie21c66007a37b90ac3bca042505bad332fa76543
2017-03-21 13:52:23 +00:00
James Page 0ff5b25d59 Misc updates
Drop nova-api-metadata; metadata services are best placed
on hypervisor or network nodes to ensure that failure domains
are as isolated as possible.

Add alias for nova-manage.

Change-Id: Ibbb73ed115d8d15e80f6eff5b05d8717cd4741aa
2017-01-06 14:55:05 +00:00
James Page 4010485ea9 Use snapcraft from packages
snapcraft is not yet pip installable, so use from installed packages
for the time being.

Change-Id: Ib6f065efba5a905bde23eeaf9fcf55776f3d6441
2017-01-04 09:21:18 +00:00
James Page 390b56430e Add firewall control to nova metadata service 2016-12-01 08:53:33 +00:00
James Page 7e2ada0be8 Add missing requirements file 2016-11-30 10:24:24 +00:00
James Page 55fdd62e0b Add metadata daemon, rename conf->snap 2016-11-25 09:02:44 +00:00
James Page 6134a30011 Misc updates 2016-11-25 08:49:09 +00:00
James Page eeeaf62ddd Add LICENSE 2016-11-22 15:47:52 +00:00
James Page fcd7385a2d Add gitreview configuration 2016-11-22 15:47:05 +00:00
James Page 7b51d24c71 Drop libvirt-dev from build-packages - not required 2016-11-22 15:44:58 +00:00
James Page 415cee3730 Add CONTRIBUTING doc 2016-11-22 15:10:35 +00:00
James Page 985a0e76ad Add README 2016-11-22 15:09:51 +00:00
James Page 271c1247e7 Add generated policy.yaml and include memcached in python-modules 2016-11-22 15:09:25 +00:00
James Page e4d9ad3741 Baseline nova snap 2016-11-22 14:35:13 +00:00