If you have deployed the services as part of the TeSLA CE deployment process, you should skip the network creation and load balancer deployment.
Generate deployment scripts
To generate all scripts to deploy the TeSLA CE core on your cluster, run:
tesla_ce deploy_core
This command will create a folder deploy with:
- config: Folder with required configuration files
- secrets: Folder with required secret files
- tesla_lb.yml: Docker Stack file for the Load Balancer
- tesla_core.yml: Docker Stack file to deploy all TeSLA CE core modules
Deploy TeSLA CE core services
Before deploying, move deploy folder to a Docker Swarm master node and move to this folder of the node machine.
Create networks
TeSLA CE will use two different networks, to create them run:
docker network create --driver overlay tesla_public
docker network create --driver overlay tesla_private
Deploy the load balancer
Traefik is used as a default load balancer and certificate management. We need to create a persistence folder for traefik.
All data folders are expected under the folder provided in the deployment_data_path configuration option (see Configuration
).
By default, this folder is /var/tesla
.
sudo mkdir -p /var/tesla/traefik
Now we are ready to deploy the load balancer service:
docker stack deploy -c tesla_lb.yml tesla
You can check the deployment progress with:
watch docker service ls
Deploy services to Docker Swarm cluster
Once Traefik service is up, we can deploy the rest of the services:
docker stack deploy -c tesla_core.yml tesla