Verified Commit 11e026e0 authored by les's avatar les
Browse files

fix docker setup

parent c42d5d42
FROM node:buster
RUN yarn global add --silent https://gancio.org/latest.tgz 2> /dev/null
ADD entrypoint.sh /
RUN chmod 755 /entrypoint.sh
ENTRYPOINT [ "/bin/sh", "/entrypoint.sh" ]
#!/bin/bash
chown -R node:node /home/node
su node -c "$*"
......@@ -19,12 +19,13 @@ services:
build: .
restart: always
image: node:buster
user: node
container_name: gancio
environment:
- PATH=$PATH:/home/node/.yarn/bin
- GANCIO_DATA=/home/node/data
- NODE_ENV=production
command: gancio start --docker
entrypoint: /entrypoint.sh
volumes:
- ./data:/home/node/data
ports:
......
......@@ -5,11 +5,12 @@ services:
build: .
restart: always
image: node:buster
user: node
container_name: gancio
environment:
- PATH=$PATH:/home/node/.yarn/bin
- GANCIO_DATA=/home/node/data
- NODE_ENV=production
entrypoint: /entrypoint.sh
command: gancio start --docker
volumes:
- ./data:/home/node/data
......
......@@ -13,12 +13,9 @@ nav_order: 2
## Initial setup
> info "Clone not needed"
> You do not need to clone the full repo, a `Dockerfile` and a `docker-compose.yml` are enough.
- __Create a directory where everything related to gancio is stored__
```bash
mkdir -p /opt/gancio/data
mkdir -p /opt/gancio
cd /opt/gancio
```
......@@ -27,6 +24,7 @@ cd /opt/gancio
1. **Download docker-compose.yml and Dockerfile**
```bash
wget {{site.url}}{% link /docker/Dockerfile %}
wget {{site.url}}{% link /docker/entrypoint.sh %}
wget {{site.url}}{% link /docker/sqlite/docker-compose.yml %}
```
......@@ -44,6 +42,7 @@ docker-compose run --rm gancio gancio setup --docker --db=sqlite
1. **Download docker-compose.yml and Dockerfile**
```bash
wget {{site.url}}{% link /docker/Dockerfile %}
wget {{site.url}}{% link /docker/entrypoint.sh %}
wget {{site.url}}{% link /docker/postgres/docker-compose.yml %}
```
......@@ -86,6 +85,7 @@ tail -f data/logs/gancio.log
> 1. `cd /opt/gancio`
> 1. [Backup your data]({% link install/backup.md %})
> 1. Download new `Dockerfile` <br/> `wget {{site.url}}{% link /docker/Dockerfile %}`
> 1. Download new `entrypoint.sh` <br/> `wget {{site.url}}{% link /docker/entrypoint.sh %}`
> 1. Download new `docker-compose.yml` (substitute `sqlite` with `postgres` in case): <br/>`wget {{site.url}}{% link /docker/sqlite/docker-compose.yml %}`
> 1. Build the new container `docker-compose build`
> 1. Extract your backup into `./data` <br/>`mkdir data; tar xvzf gancio-<yourLastBackup>-backup.tgz -C data`
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment