commit
b54c726390
29
templates/consul/0/README.md
Normal file
29
templates/consul/0/README.md
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
# Consul Cluster
|
||||||
|
|
||||||
|
|
||||||
|
### Info:
|
||||||
|
|
||||||
|
This template creates 3 Consul nodes that uses RPC encryption with TLS and gossip encryption to secure connection between consul cluster nodes, configuration is generated with confd from Rancher metadata.
|
||||||
|
TLS is used to verify the authenticity of the servers and the clients using the verify_incoming and verify_outgoing options.
|
||||||
|
|
||||||
|
The variables used in this template include:
|
||||||
|
|
||||||
|
- Certificates and keys for Consul nodes.
|
||||||
|
- CA certificate.
|
||||||
|
- 16-bytes, Base64 encoded gossip encryption key.
|
||||||
|
|
||||||
|
|
||||||
|
The templates uses two Docker images one as the main image and the other one is the sidekick:
|
||||||
|
|
||||||
|
- [consul](https://github.com/galal-hussein/consul-rancher).
|
||||||
|
- [consul-config](https://github.com/galal-hussein/consul-config).
|
||||||
|
|
||||||
|
### Usage:
|
||||||
|
|
||||||
|
Select Consul from catalog.
|
||||||
|
|
||||||
|
Enter the certificates and keys for consul nodes, ca certificates, and the encryption key.
|
||||||
|
|
||||||
|
Click deploy.
|
||||||
|
|
||||||
|
The consul nodes will be bound to the Rancher managed network IPs.
|
15
templates/consul/0/docker-compose.yml
Normal file
15
templates/consul/0/docker-compose.yml
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
consul-conf:
|
||||||
|
image: husseingalal/consul-config
|
||||||
|
labels:
|
||||||
|
io.rancher.container.hostname_override: container_name
|
||||||
|
volumes_from:
|
||||||
|
- consul
|
||||||
|
net: "container:consul"
|
||||||
|
consul:
|
||||||
|
image: husseingalal/consul
|
||||||
|
labels:
|
||||||
|
io.rancher.sidekicks: consul-conf
|
||||||
|
volumes:
|
||||||
|
- /opt/rancher/ssl
|
||||||
|
- /opt/rancher/config
|
||||||
|
- /var/consul
|
56
templates/consul/0/rancher-compose.yml
Normal file
56
templates/consul/0/rancher-compose.yml
Normal file
@ -0,0 +1,56 @@
|
|||||||
|
.catalog:
|
||||||
|
name: "Consul"
|
||||||
|
description: "Secure Consul cluster"
|
||||||
|
version: "0.6-rancher1"
|
||||||
|
uuid: consul-0
|
||||||
|
questions:
|
||||||
|
- variable: ca_crt
|
||||||
|
label: "CA certificate"
|
||||||
|
type: "multiline"
|
||||||
|
required: true
|
||||||
|
- variable: consul1_key
|
||||||
|
label: "First consul key"
|
||||||
|
type: "multiline"
|
||||||
|
required: true
|
||||||
|
- variable: consul1_crt
|
||||||
|
label: "First consul certificate"
|
||||||
|
type: "multiline"
|
||||||
|
required: true
|
||||||
|
- variable: consul2_key
|
||||||
|
label: "Second consul key"
|
||||||
|
type: "multiline"
|
||||||
|
required: true
|
||||||
|
- variable: consul2_crt
|
||||||
|
label: "Second consul certificate"
|
||||||
|
type: "multiline"
|
||||||
|
required: true
|
||||||
|
- variable: consul3_key
|
||||||
|
label: "Third consul key"
|
||||||
|
type: "multiline"
|
||||||
|
required: true
|
||||||
|
- variable: consul3_crt
|
||||||
|
label: "Third consul certificate"
|
||||||
|
type: "multiline"
|
||||||
|
required: true
|
||||||
|
- variable: gossip_key
|
||||||
|
label: "Communication gossip key"
|
||||||
|
type: "multiline"
|
||||||
|
required: true
|
||||||
|
consul:
|
||||||
|
scale: 3
|
||||||
|
metadata:
|
||||||
|
ca.crt: |
|
||||||
|
${ca_crt}
|
||||||
|
consul1.crt: |
|
||||||
|
${consul1_crt}
|
||||||
|
consul1.key: |
|
||||||
|
${consul1_key}
|
||||||
|
consul2.crt: |
|
||||||
|
${consul2_crt}
|
||||||
|
consul2.key: |
|
||||||
|
${consul2_key}
|
||||||
|
consul3.crt: |
|
||||||
|
${consul3_crt}
|
||||||
|
consul3.key: |
|
||||||
|
${consul3_key}
|
||||||
|
enc.key: "${gossip_key}"
|
BIN
templates/consul/catalogIcon-consul.png
Normal file
BIN
templates/consul/catalogIcon-consul.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 42 KiB |
5
templates/consul/config.yml
Normal file
5
templates/consul/config.yml
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
name: Consul Cluster
|
||||||
|
description: |
|
||||||
|
Consul cluster
|
||||||
|
version: 0.6-rancher1
|
||||||
|
category: Clustering
|
Loading…
x
Reference in New Issue
Block a user