231 Commits

Author SHA1 Message Date
pd2839
0c502d2062 readOnlyFilesystem: true for keystone chart
Fix for adding readOnlyFilesystem flag at pod level

Change-Id: I37fb7f580ae0a408530d58b195c353e41d701eac
2019-03-04 21:43:43 +00:00
Pavlo Shchelokovskyy
55645c7e73 Explicitly set datefmt for logging
the defaults in Python [0] and oslo.log [1] are such that when using
separate config file for logging configuration (log-config-append)
the log fomat of dates containes miliseconds twice (as in sec,ms.ms)
which is exactly what is currently seen in logs of OpenStack services
deployed by openstack-helm.

When not provided with datefmt log formatter option, Python effectively
uses '%Y-%m-%d %H:%M:%S,%f' [0] as a default time formatting string to
render `%(asctime)s`, but the defaults in oslo.log add another `.%f`
to it [1].

Since `log-date-format` oslo.log option has no effect when using
log-config-append, we need to explicitly set date format to avoid double
miliseconds rendering in date of log entries.

[0] 6ee41793d2/Lib/logging/__init__.py (L427-L428)
[1] http://git.openstack.org/cgit/openstack/oslo.log/tree/oslo_log/_options.py?id=7c5f8362b26313217b6c248e77be3dc8e2ef74a5#n148

Change-Id: I47aa7ce96770d94b905b56d6fe4abad428f01047
2019-02-21 08:28:35 +00:00
Steve Wilkerson
f4c01d2461 Add release-uuid annotation to pod spec
This adds the release-uuid annotation to the pod spec for all
replication controller templates in the openstack-helm charts

Change-Id: I0159f2741c27277fd173208e7169ff657bb33e57
2019-02-12 12:31:59 -06:00
Pavlo Shchelokovskyy
776f4a8297 Drop heat_stack_owner role
this role is not actually required since ~Kilo
I3f1b70b78b91bfac9af5fadb71140679b208c999
plus the heat chart already sets the trusts_delegated_roles option
for Heat to pass all roles to the trust

Change-Id: Icf900f318d3173d63c5967857d96f7d2a7f9aa5b
2019-02-05 17:36:18 +02:00
Zuul
326200bf93 Merge "Scan templated python files with bandit" 2019-01-31 13:53:16 +00:00
Zuul
817eda621f Merge "Keystone: remove stale pids on startup if present" 2019-01-30 00:38:06 +00:00
Pete Birley
a5162ad6d7 Keystone: remove stale pids on startup if present
This PS removes stale pids on startup if present.

Change-Id: Iff136f16f8d15a08e8ce8c51d058b55288f97a2e
Signed-off-by: Pete Birley <pete@port.direct>
2019-01-29 16:30:36 -06:00
Deokjin Kim
658138935f Allow prometheus-openstack-exporter to access keystone
To get openstack related metrics, prometheus-openstack-exporter need to
access to keystone. So add prometheus-openstack-exporter to network
policy of keystone.

Change-Id: I31106a10e512578a35122949c3cff698b1bc482b
Signed-off-by: Deokjin Kim <deokjin81.kim@samsung.com>
2019-01-25 14:12:09 +00:00
Gage Hugo
482dbcac29 Scan templated python files with bandit
This change adds a zuul check job to export any templated python
contained in the helm charts and scan it with bandit for any
potential security flaws.

This also adds two nosec comments on the instances of subprocess
used as they currently do not appear to be malicious, as well
as changing the endpoint_update python code to prevent sql
injection, which satisfies bandit code B608.

Change-Id: I2212d26514c3510353d16a4592893dd2e85cb369
2019-01-22 20:53:52 +00:00
Zuul
8935b24544 Merge "Upgrade rally to 1.3.0" 2019-01-09 05:18:39 +00:00
weiyj
50a65ca297 spelling errors
Change-Id: Id2660a1c7f1808b7f74b3960abbd5bf6b72aa387
2019-01-05 04:40:00 +00:00
Zuul
e24b21afdd Merge "Keystone podSecurityContext" 2018-12-20 21:51:55 +00:00
Jaesang Lee
2a03fd65bf Upgrade rally to 1.3.0
Since rally 1.0, rally has been a platform for testing, and rally for
openstack has been separated by rally-openstack. The current version
of rally in openstack-helm is version 0.8 which corresponds to ocata.
This patch tests with the latest version of rally-openstack, version
1.3.0, and removes scenarios that are no longer in use.

Change-Id: I380a976c0f48c4af0796c9d866fc8787025ce548
2018-12-20 00:22:49 +00:00
Rahul Khiyani
085610523f Keystone podSecurityContext
securitycontext with non-root user is implemented at pod level
and leveraged the helm-toolkit snippet

Fix for adding allowPrivilegeEscalation flag as a blanket
policy on the pod in the keyston chart

Depends-On: I95264c933b51e2a8e38f63faa1e239bb3c1ebfda
Change-Id: I15333df4707948e50deb935ffc1ee599588e4788
2018-12-19 20:55:24 +00:00
Zuul
2fcfd668ad Merge "Enable keystone brute-force protection by default" 2018-12-19 07:24:47 +00:00
Vladyslav Drok
df336272f0 Enable keystone brute-force protection by default
This change sets lockout_failure_attempts and lockout_duration
configuration options in security_compliance group.

Change-Id: I72910e52239ace23b92d826794cd0603a061e6c3
2018-12-18 05:03:22 +00:00
Mike Pham
95a6a2e875 Enable Egress policy enforcement
This PS is enable the Egress policies
and enforces them in Openstack-helm.

Depends-On: Icbe2a18c98dba795d15398dcdcac64228f6a7b4c
Change-Id: I6ef3cd157749fd562acb2f89ad44e63be4f7e975
2018-12-17 14:38:29 +00:00
Huang,Sophie(sh879n)
3061ae3896 Implemented livenessProbe for different OpenStack api containers
LivenessProbe is added to the below deployments:
  glance-api
  glance-registry
  heat-api
  heat-cfn
  horizon
  keystone-api
  nova-api-metadata
  nova-api-osapi
  nova-placement-api

Change-Id: I76b8cafa437855eeb42b77e88da6e3c514a3ac90
Signed-off-by: Huang,Sophie(sh879n) <sh879n@att.com>
2018-12-14 09:52:50 -06:00
Tin Lam
29f32a07ac Enable network policy enforcement
This patch set updates the gate to by default uses network policy
for all components and enforces them in Openstack-helm.

Change-Id: I70c90b5808075797f02670f21481a4f968205325
Depends-On: I78e87ef3276e948ae4dd2eb462b4b8012251c8c8
Co-Authored-By: Mike Pham <tp6510@att.com>
Signed-off-by: Tin Lam <tin@irrational.io>
2018-10-23 14:58:13 +00:00
Zuul
3d5fcddffe Merge "Keystone: remove rally ec2 credential test" 2018-10-17 19:44:53 +00:00
Pete Birley
a2c47a78c3 Keystone: remove rally ec2 credential test
This PS removes the rally ec2 credential test. As Rally left old
encrypted ec2 credentials in the database which were not being
cleaned up between upgrades and key changes.

Change-Id: Id0c5411521adebc8c977fd9a24f511f6925f16d0
Signed-off-by: Pete Birley <pete@port.direct>
2018-10-17 09:57:13 -05:00
Tin Lam
3cd4d0898a Upgrade default from newton to ocata
This patch set moves the default deployment to ocata from newton.
Newton zuul job is now moved into its separate job.

Change-Id: Ic534c8ee02179f23c7855d93a4707e5a2fd77354
Signed-off-by: Tin Lam <tin@irrational.io>
2018-10-13 04:18:46 +00:00
Pete Birley
3ae745a10e Add release uuid to pods and rc objects
This PS adds the ability to attach a release uuid to pods and rc
objects as desired. A follow up ps will add the ability to add arbitary
annotations to the same objects.

Depends-On: Iceedba457a03387f6fc44eb763a00fd57f9d84a5
Change-Id: I324680f10263c1aefca2be9056e70d0ff22fcaf0
Signed-off-by: Pete Birley <pete@port.direct>
2018-09-13 06:29:14 -05:00
Jean-Philippe Evrard
05d0e2b4b8 Revert "Update OSH Author copyrights to OSF"
This reverts commit b1755c399341388627a668ab9fd6f43b7416f65a.

Change-Id: I215a172f2ff4220340292b95f5323847944baeb7
2018-08-28 17:25:13 +00:00
Matt McEuen
b1755c3993 Update OSH Author copyrights to OSF
This PS updates the "Openstack-Helm Authors" copyright attribution
to be the "OpenStack Foundation", as decided in the 2018-03-20
team meeting:
http://eavesdrop.openstack.org/meetings/openstack_helm/2018/openstack_helm.2018-03-20-15.00.log.html

No other copyright attributions were changed.

Change-Id: I167ceedab8fadee28c19514fad6f125d0a521caf
2018-08-26 17:17:41 -05:00
Zuul
e31f82668e Merge "Keystone: Correct endpoint definition" 2018-08-24 16:01:53 +00:00
Pete Birley
4b3cbafc9a Keystone: Correct endpoint definition
This PS udpates the keystone endpoint definition to point to the
correct host for the admin endpoint when looked up using endpoint
functions from helm-toolkit.

Change-Id: Ic6b82a002cca92e37d21f594bad5f00758f1ea7a
Signed-off-by: Pete Birley <pete@port.direct>
2018-08-23 11:33:21 -05:00
Pete Birley
83b91e6e1b Openstack: Use k8s secret to store config
This PS moves openstack components in OSH to use secrets to store
potentially sensitive config information.

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

Change-Id: I9bab586c03597effea0e48a58c69efff3f980a92
Signed-off-by: Pete Birley <pete@port.direct>
2018-08-22 20:39:52 -05:00
Pete Birley
7e90bb02bd Logging: update logging config to pass null as a string to oslo config
This PS updates the logging config to pass null as a string though to
the rendering engine, which is required to avoid things like `<no value>`
when base64 encoding output.

Change-Id: I04d6afbc693ec1adf560c7be15704c8b7434c08f
Signed-off-by: Pete Birley <pete@port.direct>
2018-08-20 13:28:27 -05:00
Pete Birley
7a8ef5f1bb Keystone: move all configuration to be values driven
This PS moves the keystone chart to be linine with other OSH
components and drives all config via the charts values.yaml

Change-Id: I14ee6ede0a87619ecbb2c56d0edf82ffbc5606be
Signed-off-by: Pete Birley <pete@port.direct>
2018-08-05 08:39:17 -05:00
Pete Birley
4a6d740154 Keystone: Stop running keystone container with root user
This PS updates the keystoen chart to stop running the keystone api
as the root user.

Change-Id: If3042210f761476846da02fc8e648c700267a591
Signed-off-by: Pete Birley <pete@port.direct>
2018-08-04 10:06:32 -05:00
Pete Birley
5f349ae653 Keystone: Disable v2 api
This PS disables the v2 keystone API, and finishes the migration to
full v3 support.

Change-Id: I3021ebe0bee668db9f28e7fb18e2d4b26172f209
Signed-off-by: Pete Birley <pete@port.direct>
2018-08-03 14:50:45 +00:00
Pete Birley
dc7008d9a5 Keystone: enable external access to admin endpoint
This PS moves to use port 80 by default for the keystone
asdmin endpoint, and adjusts paths accordingly.

Change-Id: Iccae704dadc17eba269e857301654782f64763c9
Signed-off-by: Pete Birley <pete@port.direct>
2018-08-02 14:40:20 +00:00
Gage Hugo
f57aba1fab Fix invalid policy rule
As reported in OSSN-0083[0], "get_identity_providers" is invalid
and should be singular "get_identity_provider". The former rule
is ignored, this change to make the rule singular fixes this
issue.

[0] https://wiki.openstack.org/wiki/OSSN/OSSN-0083

Change-Id: I479bcda89b0be0056717864e79269b8d071d98ec
2018-07-31 17:07:12 -05:00
Pete Birley
d003a082c8 Logging: Only output std logs to stdout
This PS removes the double logging of openstack components that
were caused by outputting to both stdout and stderr.

Change-Id: I6e0ae5861bbf5b8d736ae08251aa865e1c4ce0d8
Signed-off-by: Pete Birley <pete@port.direct>
2018-07-27 11:01:30 +00:00
Pete Birley
1925a6e61b Keystone: enable service catalog endpoint updates
This PS adds a script to update the keystone catalog endpoints
for keystone itself, as the keystone-bootstrap will not update
these once created.

Change-Id: Ie48c71bbdc9bbd14cebcee46285b3bf51bd28065
Signed-off-by: Pete Birley <pete@port.direct>
2018-07-26 21:24:57 +00:00
Pete Birley
ec2f9d0808 Keystone: Update admin port declaration to use standard layout
This PS updates keystone, and the keystone endpoints sections to use
the same layout for port declarations as other charts.

Change-Id: I7dddabee6c74bf023da4b1cdf722a409e7475f8f
Signed-off-by: Pete Birley <pete@port.direct>
2018-07-25 13:00:52 -05:00
Steve Wilkerson
2f878e6cf7 Dynamically generate tags for oslo_log fluentd formatter
This proposes changing the tags added to the openstack logs
gathered by the fluentd handler from `openstack.<service>` to
`Namespace.Release` to account for multiple instances of openstack
services being deployed into different namespaces. This allows for
fine tuning the search queries in elasticsearch/kibana to target
specific service deployments in specific namespaces

Change-Id: Ia12dceb4089e107e15d8e30c92c91f350dc31318
2018-07-23 13:28:26 +00:00
Steve Wilkerson
2840259fb8 Armada check: Add test directive to charts
This adds support for executing helm tests via the armada test
directive. It enables theses tests for all services, except for
nova and neutron as executing tests with armada force a chart to
wait. Forcing nova and neutron to wait effectively sequences the
charts, which will result in a failure to deploy past those
services

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

Change-Id: I6ac845c82d744e2f5fd79c3e2ff3c1479dd1ddab
2018-07-11 13:34:58 +00:00
Ruslan Khanbikov
826e867d0a Keystone: it enables keystone notificaitons
This patch sets the notifier driver to messagingv2 so all
messages sent to RabbitMQ using the 2.0 format.

For info:
Auth notificaitons are supressed by default, to enable it
uncomment the following parameter:
conf:
  DEFAULT:
    notification_opt_out: ""

Change-Id: I652fc34a229612dcb8b96c8722b8c6ac1c8aba3e
Signed-off-by: Ruslan Khanbikov <rk760n@att.com>
2018-07-06 18:31:55 +00:00
Ruslan Khanbikov
e0ed5d2708 RabbitMQ: It adds HA and ttl policy for notificaitons queues
This patchset introduces mirroring "notificaitons.*" queues messages across
rmq cluster nodes and add ttl expiration time for messages, utilizing
rabbitmq helm-toolkit

the configuration example:

rabbitmq:
  policies:
    - name: "test"
      vhost: "nova"
      definition: ".*"
      definition:
        ha-mode: all
  ...

equals:
 rabbitmqctl set_policies -p nova test ".*" "{"ha-mode":"all"}"
Signed-off-by: Ruslan Khanbikov <rk760n@att.com>

Change-Id: I61215de07cfaeb9d896126ef9abc94fcc9e429b9
Depends-On: I85240a50fb64a4d74454768034fe3bdcf25f3019
2018-07-06 18:31:25 +00:00
Ruslan Khanbikov
c3b2c944f8 Update fernet keys rotation and expiration
Keystone token expiration, rotation frequency and active keys
values should follow the formula:

max_active_keys = (token_expiration / rotation_frequency) + 2

max_active_keys by default is 3
token expiration set to 43200 (12h)
rotation frequency set to 12 hours

Change-Id: Ia04daec9b2905ef2d3f2d4fbb43557dda220dc70
Signed-off-by: Ruslan Khanbikov <rk760n@att.com>
2018-06-27 17:43:28 -07:00
Zuul
e8f561127f Merge "Add logging.conf files to enabled loggers/handlers/formatters" 2018-06-26 18:02:54 +00:00
Steve Wilkerson
da7bc575ec Add logging.conf files to enabled loggers/handlers/formatters
This introduces a mechanism for generating the logging.conf
file for the openstack services via the values. This allows us to
define loggers, handlers, and formatters for the services and the
modules they're composed of.

This also allows us to take advantage of the oslo fluent handler
and formatter. The fluent handler and formatter give us the
following benefits: sending logs directly to fluentd instead of
routed to stdout/stderr and then through fluentbit to fluentd,
project specific tags on the logged events (enables us to define
more robust filters in fluentd for aggregation if required),
full traceback support, and additional metadata (modules that
created logged event, etc)

Depends-On: https://review.openstack.org/577796

Change-Id: I63340ce6b03191d93a74d9ac6947f0b49b8a1a39
2018-06-26 09:51:14 -05:00
Pete Birley
e19be77f08 Ingress: Add initial TLS Support for core service public endpoints
This PS adds support for TLS on over-ridden fqdn's for public
endpoints for core OpenStack Services. Currently this implementation
is limited, in that it does not provide support for dynamicly loading
CAs into the containers, or specifying them manually via configuration.
As a result only well known or CA's added manually to containers will
be recognised.

Change-Id: I8f1b699af29cbed2d83ad91bb6840dccce8c5146
Depends-On: I535f38a8d92c01280d79926a1f0acd06984aabbf
Signed-off-by: Tin Lam <tin@irrational.io>
Signed-off-by: Pete Birley <pete@port.direct>
2018-06-26 07:15:24 +00:00
Gage Hugo
f5c2fe9a1a Consolidate all variations of member role
As of Rocky, keystone creates a default "member" role upon bootstrap.

This change modifies any references to the manually created
"_member_" role to "member". In a future change, the manualy creation
of this role in keystone can be removed since it will no longer be
needed.

Change-Id: I65c63695976f38da21dc6dd8f40ad70e23da6f48
2018-06-25 18:40:22 +00:00
Pete Birley
75ecf8fdf4 Gotpl: remove quote and trunc to suppress output
This PS removes the use of the `quote and truncate` approach to
suppress output from gotpl actions in templates and replaces it
with the recommended practice of defining `$_` instead.

Change-Id: I5f35c5f7e70b4f7f461d772e3b72ed1c695c56a8
Signed-off-by: Pete Birley <pete@port.direct>
2018-06-16 18:52:13 +00:00
Pete Birley
67aed694c4 Deployments: Use current kubernetes deployment version
This PS moves to use the current ga version for kubernetes deployments.

Story: 2002205
Task: 21735
Depends-On: Icb4e7aa2392da6867427a58926be2da6f424bd56

Change-Id: I062a8a29dff70427ee9bcf09f595011b3611b0b1
Signed-off-by: Pete Birley <pete@port.direct>
2018-06-13 21:29:59 -05:00
Pete Birley
75b1af3897 Keystone: add deps for rabbitmq job
This PS adds dep checking for the rabbitmq management jobs.

Change-Id: Ibdaa1a9d6db0eb8fae83ba6390d629af7ee63571
Signed-off-by: Pete Birley <pete@port.direct>
2018-06-05 17:48:40 -05:00
zhulingjie
eb80c4f7f1 Update the home page for openstack project
Change-Id: I3841873915bb6e10e55375cd170688a7d6810535
2018-05-27 14:01:50 -04:00