Init borgbackup based backup solution for home server

This commit is contained in:
tkl
2024-07-01 07:39:16 +02:00
commit 51d4d1988e
8 changed files with 276 additions and 0 deletions

20
docker/gitea/start.sh Executable file
View File

@@ -0,0 +1,20 @@
#!/bin/sh
IMAGE_NAME=gitea/gitea
IMAGE_TAG=latest
CONTAINER_NAME=gitea
HOST_DIR=/srv/$CONTAINER_NAME
SLAVE_DIR=/data
docker run \
--detach \
--restart always \
--hostname git \
--publish 8002:3000 \
--publish 2222:22 \
--name $CONTAINER_NAME \
--volume $HOST_DIR:$SLAVE_DIR \
$IMAGE_NAME:$IMAGE_TAG

10
docker/grafana/start.sh Executable file
View File

@@ -0,0 +1,10 @@
#!/bin/sh
docker run \
--detach \
--user root \
--volume "/srv/grafana:/var/lib/grafana" \
--publish 3000:3000 \
--name grafana \
--restart unless-stopped \
grafana/grafana-oss

9
docker/influx/start.sh Executable file
View File

@@ -0,0 +1,9 @@
#!/bin/sh
docker run \
--detach \
--publish 8086:8086 \
--volume /srv/influx:/var/lib/influxdb2 \
--restart unless-stopped \
--name influx \
influxdb:latest

View File

@@ -0,0 +1,27 @@
services:
nextcloud:
image: nextcloud
ports:
- "8008:80"
volumes:
- /srv/nextcloud/:/var/www/html
restart: always
environment:
- POSTGRES_HOST=nextcloud_db_1 # service name for postgres as assigned by Docker
- POSTGRES_DB=nextcloud_db
- POSTGRES_USER=postgres # will access postgres over 5432
- POSTGRES_PASSWORD=ncdbpwd
- PHP_MEMORY_LIMIT=1024M
- PHP_UPLOAD_LIMIT=1024M
depends_on:
- db
db:
image: postgres:13
restart: always
volumes:
- /srv/postgres-data:/var/lib/postgresql/data
environment:
- POSTGRES_DB=nextcloud_db
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=ncdbpwd