620 Commits

Author SHA1 Message Date
Zuul
041cbcbafe Merge "tools: generalize execute_shipyard_action" 2019-03-12 19:59:35 +00:00
Zuul
38956c7b27 Merge "[Database] Shipyard DB changes" 2019-03-07 21:21:39 +00:00
Nishant Kumar
d9f145e2a6 [Database] Shipyard DB changes
- Use helm-toolkit for DB initialization [0]
- Create DB auxiliary Job for shipyard specific
  additonal DB operations
- Refactor Job dependencies

[0] https://review.openstack.org/#/c/635348/

Depends-On: https://review.openstack.org/#/c/635348/

Change-Id: I093671f9bce747b491f22dd8f38f597bd9dae9af
2019-03-07 15:16:39 +00:00
Dustin Specker
c234b72abd tools: generalize execute_shipyard_action
This enables passing any combination of actions and parameters to this
script.  This also makes it easier to add scripts for additional actions
by not having to modify execute_shipyard_action.

Updated redeploy_server to pass in servers as a param.

Change-Id: I590183c28e8c66997ab85470902dbe9576c5c5f6
2019-02-28 15:16:06 -06:00
Dustin Specker
f4f57a1bbf tools: fix execute_shipyard_action if condition
Before if condition was looking for non-existence of ${server}. `server`
is never defined, so this condition is always true.

Now if condition is looking for existence of ${servers}, which is
sometimes defined.

Change-Id: I31cd4a2765705176a9d5239a01b04ff341b36540
2019-02-28 00:11:32 +00:00
Dustin Specker
2d10945dd8 tools: fix execute typo
Change-Id: I41e45b236472d34eba2c434755373f7a6b706100
2019-02-25 19:16:21 +00:00
Bryan Strassner
62cada246d Update dependencies on Armada, Drydock, Deckhand
Updates the dependencies on Armada, Drydock, and Deckhand to current
values. The primary reason for this is to take advantage of a new set of
Armada requirements that allows for a reduced image size (no longer
includes grpc tools)

Change-Id: I8f208ab91664479a7af96c543a4e72d8f6d154ef
2019-02-22 22:36:21 +00:00
Bryan Strassner
067db5f2a0 [FIX] Fix document build
Adds the SLUGIFY_USES_TEXT_UNIDECODE=yes option to the appropriate tox
jobs to allow document builds/regeneration of directories occur in
alignment with license requirements

Change-Id: Ie0d25183e6759d1ae48aa45c504479e1d0592d52
2019-02-22 15:43:08 -06:00
Bryan Strassner
919868e16c Use UBUNTU_BASE_IMAGE instead of BASE_IMAGE
Offering better alignment with some downstream build jobs.

Change-Id: I90332926b4e5dd04b00b6008d06d36624086e313
2019-02-06 16:55:00 -06:00
Zuul
c7472d7f60 Merge "Switch to ubuntu base image" 2019-02-04 17:23:22 +00:00
Bryan Strassner
8550346b78 Switch to ubuntu base image
Change to use ubuntu base image instead of python
Refactor Shipyard Dockerfile to reduce image size significantly

BREAKING CHANGE: The `make images` PYTHON_BASE_IMAGE arg is now renamed to BASE_IMAGE.

Change-Id: I3338dfbbb91b5514fa4fd205bdfc4136d0abc2e5
2019-02-02 08:21:55 -06:00
Bryan Strassner
a11e962eef Move Airflow web container into Shipyard pod
Moves the airflow web server container from its own pod into the
Shipyard pod. This removes exposed network surface area from the
Shipyard suite of software. Shipyard, after this change accesses the
Airflow API using localhost in the same k8s pod.

Change-Id: Ied4bd415a8d78c393b7256ead27a6a2176f4a2d6
2019-01-29 09:41:16 -06:00
Bryan Strassner
9725b0f337 Build workflows into Airflow image
Changes to make the docker image build to include the workflows from
Shipyard, rather than adding them to the container during Helm install
of Shipyard. This also removes the "prod" switch, as it is now always
built the same way, with the workflows in place.

Change-Id: I4acd6195cbec32193e15621e75ccaeb9879455f5
2019-01-29 09:41:16 -06:00
Bryan Strassner
6b75c7119a Move airflow scheduler to worker statefulset
Moves the airflow sceduler to a container in the airflow-worker
statefulset so that its version lifecycle matches that of the worker.
Leaves the stand-alone scheduler in place to support upgradability from
prior installations that included a standalone scheduler. New
installations are advised to turn off the scheduler template from
rendering using the values.yaml flag.

This is an attempt to make disruptive upgrades to airflow less impactful
to a "update_site" action from Shipyard.

Additionally this removes the template for airflow-flower, which is not in use.

Change-Id: I0608793ee6aba1eb3ce0f5e9567655287014a0ca
2019-01-29 09:41:16 -06:00
Zuul
6bd02eea84 Merge "CI: Add chart build gate" 2019-01-29 15:36:03 +00:00
Zuul
377378febd Merge "Adding filename to logging message format for troubleshooting purpose" 2019-01-28 20:24:15 +00:00
Drew Walters
5a32c2d1fd CI: Add chart build gate
This commit introduces a chart build gate that triggers when changes are
made to charts in the charts/ directory.

Change-Id: Iec1c6da785d26e2e7273b37fd1028f3bf47ec199
2019-01-28 11:27:26 -06:00
Drew Walters
ebf4ee4785 CI: Remove OpenStack-Helm-Infra CI job
Currently, the airship-shipyard-ubuntu job deploys K8s using outdated
playbooks. The job fails due to a change [0] that introduced an AppArmor
requirement to Calico. This change removes the failing job, as its
success does not depend on changes in Shipyard.

In the future, jobs requiring K8s should be deployed using the new
Minikube gate scripts from the OpenStack-Helm infra repository. They
will be added in future changes once they are required. Additionally, a
future change will introduce a Helm linting gate for charts hosted in
the Shipyard repository.

[0] https://review.openstack.org/614805
[1] https://git.openstack.org/cgit/openstack/openstack-helm-infra/tree/tools/deployment/common/005-deploy-k8s.sh

Change-Id: I72aaff9050eab844ef0856794b059de14e2a4a28
2019-01-28 09:20:17 -06:00
pd2839
ce564e7eca Adding filename to logging message format for troubleshooting purpose
This change is realted to Airflow

Change-Id: If8fd5983fd589ddf07b960d38e0081cfb0237003
2019-01-27 22:12:56 -06:00
Zuul
1474d7856f Merge "Raise specific errors during create configdocs" 2019-01-22 20:04:51 +00:00
Zuul
ce8e8264a3 Merge "fix typos in API.rst & output.py" 2019-01-22 20:01:11 +00:00
Zuul
d2941999eb Merge "Add missing test_site RBAC config in values.yaml" 2019-01-22 19:34:39 +00:00
Zuul
75c0bc41cb Merge "Adding filename to logging message format for troubleshooting purpose" 2019-01-17 21:36:33 +00:00
pd2839
d41c065fbf Adding filename to logging message format for troubleshooting purpose
Change-Id: I09348ab7ac78700badcff557a82049660ac9f5c6
2019-01-17 13:41:13 -06:00
Samuel Pilla
fd6dd968e3 Hide Server Information
Hides the server and version information from the response header.

Change-Id: I21d3bae4131b542c1b3f122ed2d313dfe68f3eb9
2019-01-17 09:20:28 -06:00
Bryan Strassner
fd665208b1 Add missing test_site RBAC config in values.yaml
The RBAC rule for test_site was missing from the values.yaml. This
change adds the rule.

Change-Id: I8a7477c3f4a8135a2cec4fa6738d9e5b8925fb7a
2019-01-10 16:11:48 -06:00
Zuul
e232975db8 Merge "Remove those copy words occured twice times in total_garbage.yaml" 2019-01-04 18:28:16 +00:00
zhouxinyong
749b12b238 Remove those copy words occured twice times in total_garbage.yaml
Change-Id: I487529c1ad791c067d09e32023edf7eb3e3d40cf
2019-01-04 20:19:21 +08:00
lijunjie
ecdb9ad345 Fix the misspelling of "except"
Change-Id: I85a40e078d2f5ec017d2aebedf79568de4163e44
2019-01-04 17:55:53 +08:00
Nishant Kumar
30950202b3 Raise specific errors during create configdocs
Currently shipyard raises same error for 2 scenarios-
    - Collection empty or resulted in no revision (Error code - 400)
    - Buffer is either not empty or the collection already
      exists in buffer (Error code - 409)

This PS enables shipyard to raise specific errors for the above
given scenarios which would equip consumers of Shipyard API client
to handle the exception gracefully.

Change-Id: I10860ca60f4fde4088cbb146283a2db305418320
2019-01-03 20:31:30 +00:00
Zuul
4dd6b484d1 Merge "Setup mirrored queues for celery in rabbit" 2018-12-28 08:39:39 +00:00
Zuul
c1b12b9a9e Merge "Updates cleartext-secrets RBAC Permissions" 2018-12-21 14:41:02 +00:00
Zuul
09d3238e78 Merge "Support clearing collections of configdocs" 2018-12-21 14:40:00 +00:00
Vladyslav Drok
2134a87875 Setup mirrored queues for celery in rabbit
This change starts setting up mirrored queues by default.
If there is only one rabbitmq pod present this will still
work, though will cause some performance overhead.

Depends-On: https://review.openstack.org/617812
Depends-On: https://review.openstack.org/617817
Change-Id: I8982aed699185f9b7fb4962e108eb76377643f25
2018-12-17 19:37:28 +00:00
melissaml
7b40eb190f fix typos in API.rst & output.py
Change-Id: I5bb9f8e55580a926b2684aa2e62bb8cc139de3be
2018-12-12 01:15:48 +08:00
Zuul
a235f8e6db Merge "Minor: meaningful default label" 2018-12-10 15:08:57 +00:00
Zuul
95cea0f54e Merge "Update to Airflow 1.10.1 and restore sysout" 2018-12-07 15:37:09 +00:00
Bryan Strassner
d6c72d19e6 Update to Airflow 1.10.1 and restore sysout
Updates to Airflow 1.10.1; See (1), (2) for some notes

Related, and additionally: configures Airflow to restore logging of
workflow steps to a console/sdtout logger, supporting the desired
ability to attach logging and monitoring to standard container
mechanisms. This does not change the behavior of also logging to the
airflow-arranged log files for steps and DAG runs.

A side effect of updating to 1.10.1 includes a major decrease in
resource usage by the Airflow scheudler process (reducing from ~ 1 core
fully consumed to less than 5% of a core consumed YMMV, but significant)

Additional adjustment downward of resources allocated, threads produced,
and frequency of polling leads to an overall significant reduction in
resource usage.

Airship note:
Because Airflow 1.10.0 and 1.10.1 use compatible versions of celery and
dag_run information, updating from 1.10.0 - 1.10.1 in place is possible
if airflow-worker pods are allowed to continue to run.

(1) https://github.com/apache/incubator-airflow/blob/master/UPDATING.md
(2) https://github.com/apache/incubator-airflow/releases/tag/1.10.1

Change-Id: I9b024e3996c528c7b74e2888191d48c7a45a1f04
2018-12-05 12:37:14 -06:00
Roman Gorshunov
c7c25e8cda Fix: install docker-py in gates post job for docker login
Zuul post-merge job fails to run docker login, complaining about
missing docker-py module. This patch adds installation of this module
to the relevant job.

Change-Id: I3523eedd9abb56a9cabbfb72391ed9f1471a4f4c
2018-12-04 14:27:12 +01:00
Bryan Strassner
667a538330 Support clearing collections of configdocs
Adds an option to create configdocs as an empty colleciton. This is done
as an explicit flag (--empty-collection) on the command as opposed to
using empty files to prevent accidental emtpy file loads leading to
frustration.

Since this introduced a new flag value for the CLI, the CLIs using flag
values were updated to use the standard is_flag=True instead of the
flag_value=True or some other value when a boolean flag is expected.

Minor updates to CLI tests due to moving to responses 0.10.2

Depends-On: https://review.openstack.org/#/c/614421/

Change-Id: I489b0e1183335cbfbaa2014c1458a84dadf6bb0b
2018-11-30 13:36:14 -06:00
Aaron Sheffield
0cac1cbe2f Updates cleartext-secrets RBAC Permissions
- Adds an RBAC check when returning raw configdocs.

Change-Id: Ia4967ba4e1dfc49d44a3914cfa151177a49c3799
2018-11-28 10:01:40 -06:00
Zuul
03d7269b6a Merge "Ensure SY gets redacted rendered documents" 2018-11-14 22:34:23 +00:00
anthony.bellino
407cdc76d0 Ensure SY gets redacted rendered documents
- Introduced query parameter 'cleartext-secrets' yields
  cleartext secrets in encrypted documents if true, else
  the values are redacted.
- Introduced CLI flag '--cleartext-secrets' yields cleartext
  secrets in encrypted documents.

Change-Id: I8a950c8bded3550f4aab8e6dc662ea330c2fb73f
2018-11-14 18:32:37 +00:00
Bryan Strassner
84d99967bc Add configurable timeout for Drydock client
Adds configs to allow a drydock client to use a non-default read
timeout.

Change-Id: Id4e4a235861165bfb5eb571684c8ce0be4181543
2018-11-13 13:10:07 -06:00
zhouxinyong
077bf7653a fix some errors for ill-syntax in CLI.rst
Change-Id: I11043e82da9de50b8444055e3602554d355540ee
2018-11-13 10:11:19 +08:00
Roman Gorshunov
1c08239287 Zuul gates cleanup and fixes
1. Removed osh-infra-upgrade-host playbook from image building jobs,
   as non-relevant
2. Removed osh-infra-deploy-docker playbook from image building jobs,
   as docker-ce is deployed in run-image playbook
3. Removed osh-infra-build, osh-infra-deploy-k8s and security-bandit
   playbooks - they are not referenced anywhere; bandit has already
   been merged with pep8 job

Change-Id: I27f0fd8f346d0b52c55870b6005be525a1fec671
2018-11-12 15:13:56 +00:00
Roman Gorshunov
8621e440c7 Minor: meaningful default label
Making default label meaningful and conformant to "key=value" requirement.

Change-Id: I19886ea8bc9a1a3a164ee1ab0d8adfc831af02c1
2018-11-08 19:32:19 +01:00
Zuul
7f3286b523 Merge "Expects Redacted Raw Documents" 2018-11-06 21:57:46 +00:00
lvxianguo
bae15294c5 trivial: modify spelling error of response
Change-Id: Ie3d2ad641457852c15654fc6dd730f9d305e75fc
2018-11-01 17:15:49 +08:00
lvxianguo
ad6445c3bf trivial: modify spelling error of test
Change-Id: I79d71d4596b3fd5ec625d5c2b749e8a9a0f7264e
2018-10-31 19:33:40 +08:00