What is
"Docker"?
Docker
is the world’s leading software container platform. Developers use Docker to
eliminate “works on my machine” problems when collaborating on code with
co-workers. Operators use Docker to run and manage apps side-by-side in
isolated containers to get better compute density. Enterprises use Docker to
build agile software delivery pipelines to ship new features faster, more securely
and with confidence for both Linux and Windows Server apps.
About OpenProject:
OpenProject
is a web-based project management system for location-independent team
collaboration. This open source application is released under the GNU General
Public License Version 3 and is continuously developed by an active open source
community.
In
addition to numerous smaller OpenProject installations there are also some very
large installations in global organizations with more than 2,500 projects
Features:
- Project management and milestones
- Issue management
- Bug tracking,
- project timelines,
- Wiki
- Document management
- Forum
- Time tracking
- Project news
This blog will help you to setup your OpenProject on Docker. Below listed steps will guide you to install docker on
your operating system (Ubuntu) and configure OpenProject on it:
Step 1:
Install Docker on
your machine
->
Use below command to install docker on your machine
Command: sudo apt-get
install docker
Note: You can check by running
the below command whether the docker has successfully been installed or not. If
docker is installed successfully on your machine then you will be able to see
screen like below after running docker command:
Here,
your docker has been successfully installed. Now, before setting up OpenProject
on docker, you need to create few directories to manage your logs and other
data.
Step 2:
Create Folders
(Directories):
You
can run below command to create these directories:
Command: sudo mkdir -p
/var/lib/openproject/{pgdata,logs,static}
Note:
this command will create a directory named "openproject" inside lib
folder and 3 other folders (pgdata, logs, statics) inside openproject folder.
Step 3:
Configure
OpenProject on Docker:
Once
you have successfully installed the docker on your machine, you can hit below
command to setup OpenProject on your
docker:
sudo docker run
--name testopenproject --network="host" -d -p 8080:80
-e SECRET_KEY_BASE=secret
-e
EMAIL_DELIVERY_METHOD="smtp"
-e
SMTP_ADDRESS="smtp.rediffmailpro.com"
-e SMTP_PORT=xxx
-e
SMTP_DOMAIN="abcd.com"
-e SMTP_AUTHENTICATION=plain
-e
SMTP_ENABLE_STARTTLS_AUTO=true
-e
SMTP_USER_NAME="deepak.kumar@hello.com"
-e
SMTP_PASSWORD="hello123"
-v
/var/lib/openproject/pgdata:/var/lib/postgresql/9.4/main
-v
/var/lib/openproject/logs:/var/log/supervisor
-v
/var/lib/openproject/static:/var/db/openproject
openproject/community:5.0
This
command creates a container named "openproject"
configured on port 8080:80 and enables its emailing feature with given SMTP
settings.
Note:
Please do not forget to add "sudo"
before using any command on terminal.
Commands that will help user to play around with Docker
& OpenProject:
1) Display a
list of all running/exited Docker containers:
Command: docker ps -a
Command: docker ps -a
2) Display a list of docker images:
Command: sudo docker images
3) Return the info of the last container started:
Command: docker ps -l
4) To kill already running
container:
Command: sudo docker kill nilehrms
5) To start a stopped
container:
Command: sudo docker start -ai <container-name>
6) Check the IP Addresses:
Command: ifconfig
7) To check the logs:
Command: tail -500f apache2-stdout.log
8) To remove a container:
Command: sudo docker rm <container_name / container ID>
9) To run a command in a running container in a new terminal
session in the container
Command: docker exec -it <container_name> <command_to_execute>
# example : docker exec -it oracle_container /bin/bash to open a new bash terminal inside the already running container named oracle_container.
Command: docker exec -it <container_name> <command_to_execute>
# example : docker exec -it oracle_container /bin/bash to open a new bash terminal inside the already running container named oracle_container.
References:
~ Thanks for visiting.



