Commit Graph

15 Commits

Author SHA1 Message Date
Carter, Matthew (mc981n) 0761099337 Validate existence of "deployment-version" during create configdocs
This PS adds funtionality to Shipyard to validate the existence of
the Pegleg-generated "deployment-version" document (Pegleg change id:
I7919b02d70c9797f689cdad85066d3953b978901) when a user runs create
configdocs. This validation only checks the presence of the document
(by name and schema) and does not care about the document's other
contents.
The severity of a failed validation is configurable through the
"validations" config section in shipyard.conf. The default severity
is "Skip", meaning the validation is not ran at all.

Note that with the default configuration of new validation, Shipyard
functionality should be unchanged.

Change-Id: I754617de81f628a24232e890b12b157ba6731c25
2019-05-09 08:33:52 -05:00
Carter, Matthew (mc981n) 222b074cb1 Be configuration driven when referencing document names/schemas
Currently, any document name or schema referenced in the Shipyard
code base is a hard-coded string. Often times, these strings are
repeated throughout the code. This patch set adds a new configuration
section to shipyard.conf to define document names and schemas so they
can then be referenced in the Shipyard code via the oslo
configuration object. This functionality will be important for
upcoming Shipyard features which will call for more documents to be
validated as well as some new Shipyard-created docs.

Change-Id: I34ae8cd578bab730d004c3d176e3817b5a45c89e
2019-05-02 10:47:38 -05:00
Smruti Soumitra Khuntia 9c5270b616 User context tracing through logging
This PS adds entry in log for user id and passes on the context
maker to other Airship components from Shipyard during API call.

This will ensure easy tracing of user and context through log
tracing.

Change-Id: Ib9bfa8f20b641f8bb6c2dca967d9388e30d5735c
2019-04-04 13:19:02 +00: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
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
Aaron Sheffield d62f15123d Expects Redacted Raw Documents
- Adds a query parameter 'cleartext-secrets' to get full raw documents.
- Adds CLI flag to get full raw documents.

Change-Id: If38974c8433c8360cc47ae1273720ad76e87a6fd
2018-10-23 11:12:56 -05:00
Felipe Monteiro 82581d205a Rollback to revision 0 instead of clearing Deckhand DB
Now that Deckhand supports rolling back to revision 0 with
https://review.openstack.org/#/c/592725/ it is preferrable to
exercise this functionality instead of deleting all revisions
in Deckhand's database, so that previous revision history
isn't lost.

Deckhand is fast-forwarded to
0b5aa2e98a1ab5ab8a58c9dec3c1f88ef00d17a9 which contains
the commit required for SY to be able to make use of this
new change in Deckhand's client, as well as to align with
Promenade's Deckhand fast-forward of Deckhand in
https://review.openstack.org/#/c/604459/

Depends-On: https://review.openstack.org/#/c/592725/
Change-Id: Iebbfeb5e6c74b3e2f09b2137ec14482cc8fa4f44
2018-09-25 16:04:32 -04:00
Roman Gorshunov 7fa3136470 Fix: various documentation and URL fixes
1) UCP -> Airship
2) readthedocs.org -> readthedocs.io (there is redirect)
3) http -> https
4) attcomdev -> airshipit (repo on quay.io)
5) att-comdev -> openstack/airship-* (repo on github/openstack git)
6) many URLs have been verified and adjusted to be current
7) no need for 'en/latest/' path in URL of the RTD
8) added more info to some setup.cfg and setup.py files
9) ucp-integration docs are now in airship-in-a-bottle
10) various other minor fixes

Change-Id: I4b8cc6ddf491e35d600a83f5f82d7717108e31dd
2018-09-24 12:53:27 +02:00
Andrey Volkov 65b8f3b46a Fix check_intermidiate_commit logic
Before this change check_intermidiate_commit return False if revision
has site-action-failure tag only.

Co-Authored-by: Bryan Strassner <bryan.strassner@gmail.com>
Co-Authored-by: Serge Kovaleff <sk607s@att.com>

Change-Id: I8524f599741dab743df9e1a2638b25e04c87da7c
2018-09-07 08:19:06 -07:00
Bryan Strassner bd2a686dbf Make validation process failures more obvious
Adds better info to the error returne when retreiving the validations
from another Airship component. Adds tests to cover the success and
failure flows of this same logic

Change-Id: Id7fb389a3905f3e0659d4a7eec0e0658e00f3f28
2018-07-16 16:59:39 -05:00
Bryan Strassner 70eb1cef10 Add udpate_software action to Shipyard
Provides an action that can be invoked by a user to deploy only the
software portion of a design.

Change-Id: I880bdc245064364dfdd6a482a3cf2d2a293f6c0d
2018-07-06 16:57:42 -05:00
One-Fine-Day aca1b60f22 Promenade validateDesign for Shipyard
SHIPYARD-342: Shipyard Integration with Promenade to Validate Design

Calls Promenade validateDesign API to validate site design.

Change-Id: Ia763983ed9857d4e5b13cfb11d3654e75e6578a4
2018-05-15 14:39:37 +00:00
Bryan Strassner aae5662dce [fix] move functions into class
Several funcitons were misplaced outside of the
configdocs helper class - this moves them into the
right scope.

Change-Id: I409d2974f7205a62a7286687aa21da540fd0242e
2018-05-11 12:02:23 -05:00
Anthony Lin 89a61d168a Refactor get_configdocs_status Method
This is a follow-up patch set for [0] to address the comments
to break up the get_configdocs_status method into smaller
methods.

Also made a minor update to the check_reformat_versions method
based on comments in [0]

[0] https://review.gerrithub.io/#/c/att-comdev/shipyard/+/409839/

Change-Id: Id13fcaa25e48cc2f4267a08db1ccb4561b260197
2018-05-10 17:16:26 +00:00
Bryan Strassner 23fd081ece Add deployment group validation to shipyard
Adds the validation of the existence of a deployment
configuration and a deployment strategy document to
the checks before submitting a site action for
processing.

Change-Id: I61bf67759bd919dcc31208370cb1be5a777baf54
2018-05-09 09:18:16 -05:00