Page MenuHomeDevCentral

WIP: Configure RabbitMQ credentials from Vault
ClosedPublic

Authored by dereckson on Feb 9 2023, 23:19.
Tags
None
Referenced Files
F3714990: D2792.id7097.diff
Mon, Nov 4, 23:28
Unknown Object (File)
Sun, Nov 3, 16:12
Unknown Object (File)
Fri, Nov 1, 14:53
Unknown Object (File)
Fri, Nov 1, 09:54
Unknown Object (File)
Wed, Oct 30, 16:14
Unknown Object (File)
Tue, Oct 29, 12:52
Unknown Object (File)
Sun, Oct 27, 05:29
Unknown Object (File)
Sat, Oct 26, 08:59
Subscribers
None

Details

Summary

RabbitMQ clusters need the following important credentials:

  • Erlang cookie, to allow cluster components to communicate
  • An administrator account to allow maintenance tasks

Both are stored in Vault, cookie can be set in host data volume,
administrator account is set when container is initialized.
A file-as-flag is then created to indicate that's part is done.

References:

Ref T752

Test Plan

Provision white-rabbit on docker-002

Diff Detail

Repository
rOPS Nasqueron Operations
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

dereckson retitled this revision from Configure RabbitMQ credentials from Vault to WIP: Configure RabbitMQ credentials from Vault.Feb 10 2023, 01:27
dereckson added inline comments.
roles/paas-docker/containers/rabbitmq.sls
67

Switching do cmd.script, and wait 20 seconds RabbitMQ started:

docker logs white-rabbit
2023-02-10 00:28:41.201991+00:00 [info] <0.491.0> Server startup complete; 7 plugins started.
2023-02-10 00:28:41.201991+00:00 [info] <0.491.0>  * rabbitmq_prometheus
2023-02-10 00:28:41.201991+00:00 [info] <0.491.0>  * rabbitmq_mqtt
2023-02-10 00:28:41.201991+00:00 [info] <0.491.0>  * rabbitmq_web_stomp
2023-02-10 00:28:41.201991+00:00 [info] <0.491.0>  * rabbitmq_stomp
2023-02-10 00:28:41.201991+00:00 [info] <0.491.0>  * rabbitmq_management
2023-02-10 00:28:41.201991+00:00 [info] <0.491.0>  * rabbitmq_web_dispatch
2023-02-10 00:28:41.201991+00:00 [info] <0.491.0>  * rabbitmq_management_agent
2023-02-10 00:28:58.228618+00:00 [info] <0.678.0> Created user 'root'
2023-02-10 00:28:58.279681+00:00 [info] <0.685.0> Successfully set user tags for user 'root' to [administrator]

How to properly escape password is still to determine, yaml_squote doesn't give correct result.

Rebased against docker-001 config. Ready to review.

Works correctly on docker-002 for white-rabbit container.

This revision is now accepted and ready to land.Feb 20 2023, 23:30