FusionForge

Docker

From FusionForge Wiki
Jump to: navigation, search


This howto takes as hypothesis that you are aware of docker and how to use docker.
The docker container is not for production usage but for demo or testing.

Get the docker files

The docker files are published in the main fusionforge scm repository: here
Download each file into a working directory.

Build the image

To build the image just use:

# cd <your_working_directory>
# docker build -t <your_image_name> .

The build takes about 15 minutes.

Get the image from docker hub

The FusionForge image is published on docker hub repository. You can pull the image from there. The new image is published almost every month for the master branch.

Run the container

FusionForge requires a valid FQDN and the container exposes 4 ports:

  • 21 for ftp access
  • 22 for ssh access
  • 80 & 443 for http & https access

You need to map these ports locally.
You can use some variables to set the internal configuration of FusionForge:

  • PORT_SSH will configure the ssh port for plugins such as scmgit or scmsvn
  • PORT_HTTP will configure the internal URL to build the different http link
  • PORT_HTTPS ditto PORT_HTTP but for https

FusionForge includes vsftpd server with chroot mechanism. This mechanism uses the mount command to bind internal folders. Therefore you need the CAP_SYS_ADMIN capability to get ftp features working properly. Use Standard running command:

# docker run --cap-add=SYS_ADMIN -h <your_valid_fqdn> -e PORT_SSH=2222 -p 2222:22 -p 21:21 -p 80:80 -p 443:443 -d <your_image_name>

Set admin password

By default FusionForge installation comes with one user: admin but no password is set to this user. You need to set the password of admin user. Use the following command to connect to the container:

# docker exec -it <container_id> /bin/bash

Then set the admin user password

# forge_set_password admin <your_password>

Use the container

Open your browser and go to <your_valid_fqdn>
You can connect as user with the login/password: admin/<your_password>
Enjoy!