Atention! This is NOT a oficial branch of Snipe-it. This is a simple deployment with docker-compose and some configs that worked for me.
-
I choose the Ubuntu 16.04 LTS to deploy everything into, you can work on another that have at least 2 GB of RAM and 1 CPU.
1.1 Update the packages.
sudo apt -y update && sudo apt -y dist-upgrade
-
curl -fsSL https://get.docker.com -o get-docker.sh sh get-docker.sh
-
sudo curl -L https://github.com/docker/compose/releases/download/1.18.0/docker-compose-`uname -s`- `uname -m` -o /usr/local/bin/docker-compose
chmod +x /usr/local/bin/docker-compose
-
4.1 Pass the files from this repository to the deployment machine. Maybe you'll need sudo to do some operations here. If you're rebuilding the application (see the section below about backup for more details), please use
rsync -ahzv /src/folder/ /dest/folder
to avoid fadiga.4.2 Configure the variables, walkthrough the
.my-env-file
anddocker-compose.yml
and configure your deployment as you wish. -
sudo docker-compose up -d
-
To the Mail service work properly 6.1 Get in the container
sudo docker exec -it snipe-it /bin/bash
6.2 Run the commands
openssl genrsa -out /var/www/html/storage/oauth-private.key 4096
and
openssl rsa -in /var/www/html/storage/oauth-private.key -pubout > /var/www/html/storage/oauth-public.key
-
The Backup works basically on save the folder that contains the volume of the DB and put it back on the same folder at host before run the compose.
7.1 Acess the machine as
sudo
7.2 Stop the containers 7.3 Do thersync
of volume, put it safe on somewhere else!rsync -ahzv /var/bin/docker/volumes/<snipesomething> /backup/folder
Or... just save the folder that are mounted as the
docker-compose.yml
specifies.