0c69464fa1fb7c6e14bf97fe7940e5a15785061a
Commit Graph

438 Commits

This Branch
This Branch
All Branches
Author SHA1 Message Date
James Gibson
800254b354 Add option to use alernative CA server for certbot
This could be achieved using the
haproxy_ssl_letsencrypt_setup_extra_params variable, but this
makes it a bit neater.
Change-Id: Iee2d5a10e1762b23fcb3f3140950c76a754743b7
2021年10月18日 08:50:27 +01:00
Zuul
27efcbd7bd Merge "Fix haproxy Let's Encrypt SSL path" 2021年10月15日 11:21:44 +00:00
Jonathan Rosser
a8593a876e Fix typo for user supplied certificate variable
Change-Id: I74da6c27a7d0992a45103657cd0800dab8143c4f
2021年10月08日 10:55:34 +01:00
Dmitriy Rabotyagov
1195355b43 Fix haproxy Let's Encrypt SSL path
With releasing PKI role we broke Let's Encrypt option because of
changing directories where certs should be located
and not reflecting these changes for let's encrypt. At the same time
we should not generate self-signed cert when let's encrypt path is used.
Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/811742
Closes-Bug: #1938961
Change-Id: I1a6701b171782528373bc1d0a39e70e6d1ef20ab
2021年10月05日 15:08:40 +01:00
Dmitriy Rabotyagov
99415e7692 Fix PKI regen behaviour
We have introduced variables to control CA/certificates regeneration
however never used them anywhere.
This patch fixes that, so that haproxy_pki_regen_cert and
haproxy_pki_regen_ca are respected now.
Change-Id: Id6d5395d5976ec9393a55be7fe9a946cf9ce745e
2021年09月09日 11:36:03 +03:00
Zuul
96087b0867 Merge "Fix service removal condition" 2021年08月31日 11:36:07 +00:00
Andrew Bonney
964a33558b Add configuration option for native prometheus exporter
HAProxy added native Prometheus support from v2.0. This can be
enabled using the existing stats endpoint via an additional
/metrics path.
Change-Id: If9528969c7915db06138c0746dc419d8302f0e7c
2021年07月30日 09:07:50 +01:00
Dmitriy Rabotyagov
691f81a6d9 Fix service removal condition
In order to remove service currently we need to satisfy one of
conditions:
- haproxy_backend_nodes and haproxy_backup_nodes are empty and defined
but must be defined
- haproxy_service_enabled is False
- state is absent
There's big issue with logic regarding haproxy_backend_nodes and
haproxy_backup_nodes since they both should be defined and empy,
but in case haproxy_backup_nodes is not defined but haproxy_backend_nodes
is empty we should consider this as condition for removal as well.
But this will make it too complicated.
This change suggest consider rely only on haproxy_service_enabled and
state keys of haproxy_service_configs, as it's sufficient to
drop service based on these 2 options.
Change-Id: Ib37445ad852bcbd8d44d9eda9293565a4e52262b
2021年07月23日 12:25:20 +00:00
Zuul
1dc4fa621c Merge "Generate self-signed SSL per listen IP" 2021年06月25日 17:21:17 +00:00
Dmitriy Rabotyagov
f14ba91798 Generate self-signed SSL per listen IP
We're providing an option to have an IP address per VIP
address. Currently it's used only for creating self-signed
SSLs signed with internal CA per each VIP. With follow-up
patches that will also allow to provide user certificates
per VIP, making possible to cover internal and external
endpoints with different non-wildcard certs.
Change-Id: I0a9eb7689eb42b50daf5c94c874bb7429b271efe
2021年06月25日 13:30:25 +00:00
James Gibson
3139772435 Add variable to disable stick-table
In some use cases you may want to define your own stick-table and
rules, this can be done using the backend_arguments variables.
As you can have only one stick-table per backend or frontend
the default stick-table needs to be disabled.
I am also not convinved the default stick-table is used for anything,
it just logs requests and never uses the logs, i think it could be
removed.
Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/797819
Change-Id: I54307c00673ababb277257f2bb0e456e3e011ac4
2021年06月24日 11:53:32 +01:00
Dmitriy Rabotyagov
f058cf8d61 Replace whitelist with allowlist naming
Change-Id: I568273d0ef1d5ee391a42981e66cc9895b9d71b6
2021年06月16日 14:40:19 +03:00
Zuul
834b2927a7 Merge "Use external PKI role to manage haproxy self-signed certificates" 2021年06月10日 13:38:55 +00:00
Zuul
96c572d507 Merge "Update documentation for keepalived ping addresses" 2021年06月03日 11:25:17 +00:00
Jonathan Rosser
fd7509cd43 Use external PKI role to manage haproxy self-signed certificates
The external PKI role can generate a self signed CA and Intermediate
certificate, and then create a server certificate for haproxy if
no defaults are overridden.
The new openstack_pki_* settings allow an external self signed CA
to be used, but still create valid haproxy server certificates from
that external CA in an openstack-ansible deployment.
The original beheviour providing user supplied certificates in the
haproxy_user_ssl_* variables will still work, disabling the generation
of certificates but using the external PKI role to just install the
supplied certs and keys.
Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/788031
Change-Id: I7482f55e991bacd9dccd2748c236dcd9d01124f3
2021年06月01日 15:37:29 +00:00
Jonathan Rosser
ca76349e9f Use http-request set-header instead of reqadd
This is needed for HAProxy 2.1 which is in Debian Bullseye
Change-Id: I912c6d810acc137c3b3e73dc40160d6376cb3884
2021年05月13日 16:08:50 +00:00
Jonathan Rosser
51af3928f8 Use integrated tests for haproxy_server
Change-Id: Ie985d5140e0b9cf5f6248a66db057f67ba354fb1
2021年05月12日 06:36:13 +00:00
Dmitriy Rabotyagov
bec3c0e872 Fix haproxy logging
Due to error during migration to journald [1], rsyslog config has
remained intact, which caused logs from journald being copied to
regular logfile, without proper logrotate.
Now we're fixing this and dropping rsyslog config as well.
This will affect only ppl that are upgrading their environments since
Stein
[1] https://review.opendev.org/c/openstack/openstack-ansible-haproxy_server/+/672039/4/tasks/haproxy_post_install.yml#b38
Change-Id: I01689bbb3f331b4d8d4afe9d096a4213072ad7c0
2021年04月16日 21:35:04 +03:00
Jonathan Rosser
abafc878c2 Fix retrieving variable from inside ansible_facts[]
Do not use the dot notation.
Change-Id: Iab7c31624dc0e9b20ff70fd55bbd2bf1091ba857
2021年04月02日 10:39:04 +00:00
Andrew Bonney
357daad5c8 Allow HAProxy stats to be pinned to one or more processes
When HAProxy is run in multi-process mode, the single stats page
shows metrics for one of the processes at a time, with a random
selection made on page reload.
Whilst a more complete solution may be to enable a stats page for
each process, this is a little cumbersome. This addition allows
the stats page to be pinned to one process, providing a partial
snapshot of the state of the instance.
Change-Id: Id9314e5b267aafeaf34c82874eb8bfe0713dfac3
2021年03月25日 14:08:15 +00:00
Andrew Bonney
ed8c437a8c Update documentation for keepalived ping addresses
This update matches changes in the openstack-ansible repo to
enable checks against both internal and external addresses.
Depends-On: https://review.opendev.org/782374
Change-Id: Iedbe887a3d75c240dffcc7998f25d1ee5a09c1e5
2021年03月23日 08:33:07 +00:00
Zuul
93ca84c825 Merge "Updated from OpenStack Ansible Tests" 2021年03月22日 10:47:33 +00:00
OpenStack Proposal Bot
3695146789 Updated from OpenStack Ansible Tests
Change-Id: I3a5b19f348162931e5c1702eda5c60ddfbd4636b
2021年03月22日 08:44:37 +00:00
Jonathan Rosser
a10d00766e Remove references to unsupported operating systems
All references to Gentoo, SUSE, Debian stretch and Centos-7 are removed.
Conditional tasks, ternary operators and variables are simplified where possible
OS specific variables files are generalised where possible
Change-Id: If9dfa6aaa1e90856c6a4c074fd33b8e49b57a5fc
2021年03月21日 20:48:54 +01:00
Zuul
718b163002 Merge "[reno] Stop publishing release notes" 2021年03月18日 09:34:51 +00:00
OpenStack Proposal Bot
cafd5ce7f1 Updated from OpenStack Ansible Tests
Change-Id: Ie849053102ef75755a50d5bd20b1c9f7ad620026
2021年03月12日 22:16:01 +00:00
Jonathan Rosser
d78f6d5528 Use ansible_facts[] instead of fact variables
See https://github.com/ansible/ansible/issues/73654
Change-Id: Id98f052df73587f209b9621da0874ce506899f9b
2021年02月23日 09:09:46 +00:00
Dmitriy Rabotyagov
2e29dc94f1 Fix tags usage
This replace include with imports where applicable and fixes
tags usage for include where it needs to be left.
Change-Id: Id7284431e9f97e5b4939472e0a07d573186440a6
2021年02月16日 21:48:23 +02:00
dmitriy
55c6ca9705 [reno] Stop publishing release notes
Since we copy all release notes to the integrated repo there is not need
in publishing release notes for each repository. We should only verify their
validity and linting.
Change-Id: I441126861e4f35e6ae1c96d8acf643bf2c453ed3
2021年01月22日 18:23:17 +02:00
Zuul
fbc7a600c4 Merge "Fix HATop for haproxy" 2020年12月30日 19:12:39 +00:00
Satish Patel
0ef22fa4df Fix HATop for haproxy
Readjust hatop installtion method, removed haproxy_hatop_downloader and
deployment-host variables. added "haproxy_hatop_install | bool" condition.
Change-Id: I51423fff67e6e427f6c7d163d8d1aac6bcd82ca9
2020年12月30日 17:20:42 +00:00
zhangboye
718cc6f388 Add Victoria release info
Add the lack of release information for Victoria, this patch added it.
Change-Id: I4b88f6aaa5841813994d606a7b171ab7fec8db0b
2020年12月29日 14:03:38 +08:00
Marc Gariepy
ca2c011cf2 Add haproxy_frontend_only and haproxy_raw feature.
you can add prometheus metric exposed directly via haproxy if your
version is recent enough.
https://www.haproxy.com/blog/haproxy-exposes-a-prometheus-metrics-endpoint/
Change-Id: I10e7220071290301a85409a1f74fcbad2743d19d
2020年12月14日 19:10:29 +00:00
Satish Patel
a46106d4e7 Python3 supported version of hatop
New hatop package has python3 support.
Change-Id: I69c01f330feb67d92b6b01fea589a35969879da2
2020年12月04日 14:27:42 +00:00
zhoulinhui
7f15ec569f Replace deprecated UPPER_CONSTRAINTS_FILE variable
Change-Id: Id4c2b579bc0c9737d5353c992484f2c872b94151
2020年11月10日 13:11:23 +08:00
Zuul
bc00c85d8f Merge "Define http-01 params with already provided variables" 2020年10月06日 08:04:57 +00:00
Jonathan Rosser
605d889343 Fix linter errors
Change-Id: I5d9d407dc031b86d592a0e56e9a6e4dc04873ad6
2020年10月02日 07:30:16 +01:00
OpenStack Proposal Bot
c815d82949 Updated from OpenStack Ansible Tests
Change-Id: I7e99dc9b93e7faf3bc3d90f3c66af65b64f29c6a
2020年09月24日 16:53:47 +00:00
Dmitriy Rabotyagov
0343893881 Define http-01 params with already provided variables
There's no real need in asking user to manually provide http-01 port and
address when we already have corresponding variables we rely on.
Change-Id: Id0d2a73c863d9bbb8b6280ce42f918127baea354
2020年09月24日 09:55:09 +00:00
Zuul
5d7da9df3b Merge "Add haproxy_backend_only flag to service template" 2020年09月01日 18:51:47 +00:00
Danny Meloy
8120c9a3c5 Add haproxy_backend_only flag to service template
Addition of a `haproxy_backend_only` flag to the service template
for instances in which a frontend service uses ACLs to propgate
requests to multiple backend services, and not all backend services
require a corresponding frontend. This should prevent the
proliferation of spurious frontend services.
Change-Id: I8c419be82cffd289ffcc5086afac923d6eb1a78a
2020年09月01日 11:14:55 +00:00
Dmitriy Rabotyagov
6bd42911f7 Add haproxy_ssl_all_vips variable
This variable will allow to globally control if SSL should be also used
for internal/admin endpoints, or for public only
Change-Id: I1fa990bab5801a6e6fde7176b2011ab1977b30ae
2020年08月20日 13:27:44 +03:00
Jonathan Rosser
4e47093565 Update ansible metadata to indicate support for centos-8
Change-Id: I6b017720f933a06303916e8a1b437c3fb92b7ea6
2020年07月21日 12:44:17 +00:00
Jonathan Rosser
a777bf0721 Update log socket workaround to be for all Centos versions
Change-Id: I49a1b7790bf8c4cba9f0fc140c7282d50d18cb24
2020年07月21日 12:43:58 +00:00
Zuul
065ca5ddf1 Merge "Ensure there is no race between haproxy and certbot for initial cert" 2020年07月03日 17:57:10 +00:00
root
5b589d3dae Add Centos-8 support
Change-Id: I9f579e378effa92ce42ca6219ad7ec09e7feaecb
2020年06月24日 17:46:06 +01:00
Marc Gariepy
6574de7090 remove ansible_python_interpreter
ansible_python_interpreter is now set to auto in the tests repo.
it doesn't need to be overwritten in the test anymore.
Depends-On: https://review.opendev.org/735289
Depends-On: https://review.opendev.org/734676
Change-Id: I46f5ece04b82ff3131f27be2bb98aead2f07b04e
2020年06月16日 10:26:56 +00:00
Jonathan Rosser
5fba658296 Ensure there is no race between haproxy and certbot for initial cert
The certbot pre-hook is not used during initial setup of the cert,
only during renewal. This means that the same race condition exists
at initial configiuration as renewal. This patch uses the same
approach as used in the renewal pre-hook and applies it during
initialisation of certbot. This fixes race condition related failures
during initial provisioning of haproxy+letsencrypt.
Change-Id: Ica5ed5de24e3eb2fb5a743bb877d113ed0bb8a43
2020年06月08日 16:03:55 +01:00
Zuul
6b60e51005 Merge "Use newer openstackdocstheme and reno versions" 2020年06月05日 11:01:28 +00:00
OpenStack Proposal Bot
8a07725202 Updated from OpenStack Ansible Tests
Change-Id: I2a5a353f006d5dfa9acc10d998fd57e69a25fab8
2020年06月03日 18:59:57 +00:00