2021-03-18 08:11:53 -03:00
|
|
|
|
|
|
|
.. pmb1590001656644
|
|
|
|
.. _install-rest-api-and-horizon-certificate:
|
|
|
|
|
|
|
|
========================================
|
|
|
|
Install REST API and Horizon Certificate
|
|
|
|
========================================
|
|
|
|
|
|
|
|
.. rubric:: |context|
|
|
|
|
|
2022-03-28 20:35:52 -03:00
|
|
|
For secure communications, HTTPS should be enabled for OpenStack REST API and
|
|
|
|
Horizon endpoints by configuring a certificate for these endpoints.
|
2021-03-18 08:11:53 -03:00
|
|
|
|
2021-07-16 15:37:55 -04:00
|
|
|
.. rubric:: |prereq|
|
|
|
|
|
2022-03-28 20:35:52 -03:00
|
|
|
- Obtain an Intermediate or Root |CA|-signed certificate and key from a trusted
|
|
|
|
Intermediate or Root |CA|. The OpenStack certificate should be created with a
|
|
|
|
wildcard SAN.
|
2021-07-16 15:37:55 -04:00
|
|
|
|
2022-03-28 20:35:52 -03:00
|
|
|
For example:
|
2021-03-18 08:11:53 -03:00
|
|
|
|
2022-03-28 20:35:52 -03:00
|
|
|
.. code-block:: none
|
|
|
|
|
|
|
|
X509v3 extensions:
|
|
|
|
X509v3 Subject Alternative Name:
|
|
|
|
DNS:*.west2.us.example.com
|
|
|
|
|
|
|
|
- To install an openstack certificate, the domain has to be added to the
|
|
|
|
service-parameter openstack as prerequisite, for details see
|
|
|
|
:ref:`Update the Domain Name <update-the-domain-name>`.
|
|
|
|
|
|
|
|
.. code-block:: none
|
2021-03-18 08:11:53 -03:00
|
|
|
|
2022-03-28 20:35:52 -03:00
|
|
|
~(keystone_admin)$ system service-parameter-add openstack Helm endpoint_domain=west2.us.example.com
|
|
|
|
|
|
|
|
+-------------+--------------------------------------+
|
|
|
|
| Property | Value |
|
|
|
|
+-------------+--------------------------------------+
|
|
|
|
| uuid | 0459ede4-85e7-4767-aca9-d29e84f38bd4 |
|
|
|
|
| service | openstack |
|
|
|
|
| section | Helm |
|
|
|
|
| name | endpoint_domain |
|
|
|
|
| value | west2.us.example.com |
|
|
|
|
| personality | None |
|
|
|
|
| resource | None |
|
|
|
|
+-------------+--------------------------------------+
|
|
|
|
|
|
|
|
~(keystone_admin)$ system service-parameter-apply openstack
|
|
|
|
Applying openstack service parameters
|
|
|
|
|
|
|
|
- HTTPS must be enabled for |prod|, see :ref:`Configure REST API Applications
|
|
|
|
and Web Administration Server Certificate
|
|
|
|
<configure-rest-api-applications-and-web-administration-server-certificates-after-installation-6816457ab95f>`.
|
2021-03-18 08:11:53 -03:00
|
|
|
|
2021-07-29 19:23:57 -04:00
|
|
|
.. rubric:: |proc|
|
2021-03-18 08:11:53 -03:00
|
|
|
|
2021-07-29 19:23:57 -04:00
|
|
|
#. Put the |PEM| encoded versions of the OpenStack certificate and key in a
|
2022-03-28 20:35:52 -03:00
|
|
|
single file (e.g. ``openstack-cert-key.pem``), and put the certificate of
|
|
|
|
the Root |CA| in a separate file (e.g. ``openstack-ca-cert.pem``), then
|
|
|
|
copy the files to the controller host.
|
2021-03-18 08:11:53 -03:00
|
|
|
|
2021-07-29 19:23:57 -04:00
|
|
|
#. Install the certificate as the OpenStack REST API / Horizon Certificate.
|
2021-03-18 08:11:53 -03:00
|
|
|
|
2022-03-28 20:35:52 -03:00
|
|
|
This will automatically update the required openstack Helm charts.
|
|
|
|
|
2021-07-29 19:23:57 -04:00
|
|
|
.. code-block:: none
|
2021-03-18 08:11:53 -03:00
|
|
|
|
2022-03-28 20:35:52 -03:00
|
|
|
~(keystone_admin)$ system certificate-install -m ssl_ca openstack-ca-cert.pem
|
|
|
|
~(keystone_admin)$ system certificate-install -m openstack_ca openstack-ca-cert.pem
|
2021-07-29 19:23:57 -04:00
|
|
|
~(keystone_admin)$ system certificate-install -m openstack openstack-cert-key.pem
|
2021-03-18 08:11:53 -03:00
|
|
|
|
|
|
|
#. Apply the Helm chart overrides containing the certificate changes.
|
|
|
|
|
2021-10-26 11:25:46 -04:00
|
|
|
.. parsed-literal::
|
2021-03-18 08:11:53 -03:00
|
|
|
|
2021-10-26 11:25:46 -04:00
|
|
|
~(keystone_admin)$ system application-apply |prefix|-openstack
|
2021-03-18 08:11:53 -03:00
|
|
|
|
2022-03-28 20:35:52 -03:00
|
|
|
#. Ensure port 443 is open in |prod| firewall. For details see :ref:`Modify
|
|
|
|
Firewall Options <security-firewall-options>`.
|