Redmine is an open-source project management platform you can install on your local LAN or to a third-party cloud host. This take on project management includes multiple project support, flexible role-based access control, flexible issue tracking, Gantt charts, calendars, news, documents and file management, feeds and email notifications, per-project wikis, and per-project forums.
SEE: Hiring kit: Project manager (TechRepublic Premium)
Redmine is free to use and can be installed manually or via Docker. Since the manual installation can be a bit cumbersome for some, the more logical and portable method is to deploy the platform by way of Docker. And that’s exactly what I want to show you.
What you’ll need to deploy Redmine with Docker Compose
In order to make this work, you’ll need an operating system that supports Docker. I’ll be demonstrating with Ubuntu Server 22.04, but you can work with any operating system that supports the container runtime in question.
With your OS of choice at the ready, let’s get to it.
How to install the latest version of Docker
On the off-chance your operating system doesn’t already include Docker, let’s install it.
The first thing we’ll do is add the official Docker GPG key with:
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg
Next, add the Docker repository:
echo "deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
Install the necessary dependencies with the command:
sudo apt-get install apt-transport-https ca-certificates curl gnupg lsb-release -y
sudo apt-get update
Install the latest version of the Docker engine with the command:
sudo apt-get install docker-ce docker-ce-cli containerd.io -y
To finish things up, make sure your user is still a member of the docker group with the command:
sudo usermod -aG docker $USER
Log out and log back in for the changes to take effect.
You should now have both the docker and docker-compose commands ready to use.
How to create the Dockerfile
Next, we need to create a Dockerfile that will define the version of Redmine we’ll be using. We’re going to use the latest, which is 5.0.3. Create a new directory with the command:
Change into that directory with:
Create the Dockerfile with:
In that file, paste the following:
FROM redmine:5.0.3 RUN apt-get update
Save and close the file.
How to create the docker-compose.yml file
We’ll now create the docker-compose.yml file with the command:
nano docker-compose.yml version: '3.3' services: postgres: image: postgres:10 volumes: - ./storage/postgresql-data:/var/lib/postgresql/data environment: POSTGRES_PASSWORD: "PASSWORD" POSTGRES_DB: "redmine" PGDATA: "/var/lib/postgresql/data" restart: always redmine: build: context: . image: redmine:custom ports: - 80:3000 volumes: - ./storage/docker_redmine-plugins:/usr/src/redmine/plugins - ./storage/docker_redmine-themes:/usr/src/redmine/public/themes - ./storage/docker_redmine-data:/usr/src/redmine/files environment: REDMINE_DB_POSTGRES: "postgres" REDMINE_DB_USERNAME: "postgres" REDMINE_DB_PASSWORD: "PASSWORD" REDMINE_DB_DATABASE: "redmine" REDMINE_SECRET_KEY_BASE: "…" restart: always
Make sure to change PASSWORD to a strong and unique password.
Save and close the file. The above docker-compose file configures everything necessary and even sets up volumes for persistent data.
How to deploy the container
We can now deploy the container with the command:
docker-compose up -d
How to access Redmine
After the images are pulled and the container deployed, give it a minute to settle, and then, point your web browser to http://SERVER, where SERVER is the hosting server IP address.
You should be presented with the Redmine login page, where you’ll use the credentials admin/admin. Upon successful login, you’ll be prompted to immediately change the admin user password (Figure A).
After resetting the admin password, you will then be presented with a window where you can customize your account settings (Figure B).
After you take care of that, click Administration in the top menu bar. In the resulting window (Figure C), make sure to go through all of the administration tasks, such as creating users/groups/roles, configuring the workflow, taking care of general settings, etc.
And there you go. Redmine is up and running and ready to help you manage those projects like a boss.
Subscribe to the Developer Insider Newsletter
From the hottest programming languages to commentary on the Linux OS, get the developer and open source news and tips you need to know. Delivered Tuesdays and Thursdays