Running Wekan with docker
In this post, I show how to run Wekan in multiple setups.
Wekan is a trello-like kanban.
The setup is the same as for Rocker.chat.
The docker image in this setup is the official wekan image.
Contents
-
On a single machine
-
In docker swarm
-
On a single machine with SSL TLS 1.2
-
In docker swarm with SSL TLS 1.2
1. On a single machine
- Run a mongo container and name it mongo.
- Run a wekan container and link it to mongo with the name db, inside the wekan container, the address http://mongo reaches the mongo container.
- The wekan container is named wekan and is binded to port 3000.
To access wekan, enter the address: http://ip_address_of_the_machine_running_docker:3000/
docker run --name mongo -d mongo --smallfiles
docker run --name wekan --link mongo:db -e ROOT_URL=http://localhost -e MONGO_URL=mongodb://db -p 3000:80 -d mquandalle/wekanTo stop wekan:
docker stop wekan mongoTo restart wekan:
docker start mongo
# wait a few seconds
docker start wekan2. In docker swarm
For docker swarm setup see this post.
My docker swarm manager has ip:port=172.16.43.199:3456 and the overlay network is named my-net.
- Run a mongo container connected to my-net and name it mongo, the address http://mongo reaches the mongo container.
- Run a wekan container connected to my-net.
- The wekan container is named wekan and is binded to port 3000.
To access wekan, enter the address: http://ip_address_of_the_machine_running_the_wekan_container:3000/
docker -H tcp://172.16.43.199:3456 run -d --name=mongo --net=my-net mongo --smallfiles
docker -H tcp://172.16.43.199:3456 run --name wekan -e ROOT_URL=http://localhost -e MONGO_URL=mongodb://mongo -p 3000:80 -d --net=my-net mquandalle/wekanTo get the address of node running wekan, run:
docker -H tcp://172.16.43.199:3456 psTo stop wekan:
docker -H tcp://172.16.43.199:3456 stop wekan mongoTo restart wekan:
docker -H tcp://172.16.43.199:3456 start mongo
# wait a few seconds
docker -H tcp://172.16.43.199:3456 start wekan3. On a single machine with SSL TLS 1.2
- Run a mongo container and name it mongo.
- Run a wekan container and link it to mongo with the name db, inside the wekan container, the address http://mongo reaches the mongo container.
- Run a stud container and link it to the wekan with the name app.
The stud docker image used in this setup is remynoulin/stud.
To create a self signed certificate, run this:
mkdir certs
openssl req -x509 -new -newkey rsa:2048 -nodes -keyout key.pem -out cert.pem
cat key.pem cert.pem > certs/ssl.pemTo access wekan, enter the address: https://ip_address_of_the_machine_running_docker:3443/
docker run --name mongo -d mongo --smallfiles
docker run --name wekan --link mongo:db -e ROOT_URL=http://localhost -e MONGO_URL=mongodb://db -p 3000:80 -d mquandalle/wekan
cd certs
docker run --name stud -p 3443:443 --link wekan:app -v $(pwd):/opt/certs -d remynoulin/studTo stop wekan:
docker stop stud wekan mongoTo restart wekan:
docker start mongo
# wait a few seconds
docker start wekan
docker start stud4. In docker swarm with SSL TLS 1.2
For docker swarm setup see this post.
My docker swarm manager has ip:port=172.16.43.199:3456 and the overlay network is named my-net.
- Run a mongo container connected to my-net and name it mongo, the address http://mongo reaches the mongo container.
- Run a wekan container connected to my-net.
- Run a stud container connected to my-net.
The stud docker image used in this setup is remynoulin/stud.
To create a self signed certificate, run this:
mkdir certs
openssl req -x509 -new -newkey rsa:2048 -nodes -keyout key.pem -out cert.pem
cat key.pem cert.pem > certs/ssl.pemTo access wekan, enter the address: https://ip_address_of_the_machine_running_the_wekan_container:3443/
docker -H tcp://172.16.43.199:3456 run -d --name=mongo --net=my-net mongo --smallfiles
docker -H tcp://172.16.43.199:3456 run --name app -e ROOT_URL=http://localhost -e MONGO_URL=mongodb://mongo -d --net=my-net mquandalle/wekan
docker -H tcp://172.16.43.199:3456 run --name stud -p 3443:443 --net=my-net -d remynoulin/stud
docker -H tcp://172.16.43.199:3456 cp certs/ssl.pem stud:/opt/certs/ssl.pemBy default the backend port is app:3000 in remynoulin/stud, change stud.conf to have backend on port 80 since the telescope container exposes port 80:
docker -H tcp://172.16.43.199:3456 cp stud:/opt/stud/stud.conf .
# EDIT stud.conf, change backend = "[app]:3000" to backend = "[app]:80"
docker -H tcp://172.16.43.199:3456 cp stud.conf stud:/opt/stud/stud.confdocker -H tcp://172.16.43.199:3456 start studTo get the address of node running stud, run:
docker -H tcp://172.16.43.199:3456 psTo stop wekan:
docker -H tcp://172.16.43.199:3456 stop stud wekan mongoTo restart wekan:
docker -H tcp://172.16.43.199:3456 start mongo
# wait a few seconds
docker -H tcp://172.16.43.199:3456 start wekan
docker -H tcp://172.16.43.199:3456 start stud