1
0
Fork 0
mirror of https://github.com/postmannen/ctrl.git synced 2024-12-14 12:37:31 +00:00
ctrl/scripts/nats-server/README.md

30 lines
1.2 KiB
Markdown
Raw Normal View History

# nats-server configuration
This folder contains several scripts to help out setting up the nats-server configuration.
You can run each script individually, or you can use one of the wrapper scripts.
2021-12-07 13:20:46 +00:00
## Setup
2021-12-07 13:20:46 +00:00
### Generate docker-compose files
2021-12-07 15:17:10 +00:00
Create a directory where you want your docker compose files, and enter that directory.
2021-12-07 13:20:46 +00:00
Clone the steward repository:
```bash
mkdir my_dir
cd my_dir
git clone https://github.com/RaaLabs/steward.git
```
Execute the wrapper script with the following arguments:
2021-12-07 15:17:10 +00:00
`./steward/scripts/nats-server/wrapper.sh <fqdn of nats server> <nats-server listen port>`
This will create all files needed, but you need to add user configuration to the **nats.conf** file manually.
A template for the central steward instance are added by default, but **you need** to edit the file and replace the **`FILL-IN...`** fields with your central user key, and **organization name** according to the naming you want to use as node names. **Read more about the naming in the main README.md.**
2021-12-07 15:17:10 +00:00
**NB**: LetsEncrypt certificate are generated by using <https://github.com/RaaLabs/certupdater>, and it need to be present on the host where this wrapper script is run. The certupdater contains a Dockerfile and instruction for how to build it.