Skip to content

Docker Cli

In this section we will see how deploy Teemii using the docker and the dockerfile.

Step 1. Clone the Teemii Repository

Clone the Teemii GitHub repository to your local machine using the following command:

 git clone https://github.com/dokkaner/teemii.git

Step 2. Create a Network for Teemi

docker network create teemii-network

Step 3. Create a Docker Volume

docker volume create teemii-data

Step 4. Build and Run the Backend

Navigate to the server directory:

 cd ../server

Build the Teemii backend Docker image:

 docker build -t teemii-backend .

Run the Teemii backend container with network and volume configurations:

 docker run -d --name teemii-backend --network teemii-network -v teemii-data:/app/data teemii-backend

This will expose the Teemii backend on port 3000 and the WebSocket server on port 1555.

Step 5. Build and Run the Frontend

Navigate to the app directory:

 cd ../app

Build the Teemii frontend Docker image:

 docker build -t teemii-frontend .

Run the Teemii frontend container with network configuration:

 docker run -d -p 8080:80 --name teemii-frontend --network teemii-network teemii-frontend

This will expose the Teemii frontend on port 8080.

Step 6. Access Teemii

Once the containers are running, you can access Teemii in your web browser by navigating to:

 http://localhost:8080

Teemii should now be accessible on your Server.

Stopping and Cleanup

 docker stop teemii-frontend teemii-backend
 docker rm teemii-frontend teemii-backend