Added kopia, nginx, portainer

This commit is contained in:
Thord Johansson 2024-03-20 11:25:56 +01:00
parent 9b0262dbb2
commit 905691f4bb
3 changed files with 94 additions and 0 deletions

59
kopia/docker-compose.yml Normal file
View File

@ -0,0 +1,59 @@
version: '3.7'
# on naspi for remote docker stop commands:
# sudo visudo
# thord ALL=(ALL) NOPASSWD: /bin/systemctl start docker, /bin/systemctl stop docker
services:
kopia:
image: kopia/kopia:latest
hostname: kopia-host
container_name: kopia
restart: unless-stopped
networks:
vlan:
ipv4_address: 192.168.1.102
ports:
- 51515:51515
command:
- server
- start
- --disable-csrf-token-checks
- --insecure
- --address=0.0.0.0:51515
- --server-username=${KOPIA_USER_NAME}
- --server-password=${KOPIA_USER_PASSWORD}
environment:
# Set repository password
KOPIA_PASSWORD: "${KOPIA_PASSWORD}"
USER: "User"
volumes:
# Mount local folders needed by kopia
- /opt/kopia/config:/app/config
- /opt/kopia/cache:/app/cache
- /opt/kopia/logs:/app/logs
# Use NFS volume for storage
- nfs-naspi:/data/naspi:ro
# Mount repository location locally
- /opt/kopia/repository:/repository
# Mount path for browsing mounted snapshots
- /tmp:/tmp:shared
- /home/thord/.config/rclone:/app/rclone
- /usr/bin/rclone:/app/rclone-bin
volumes:
nfs-naspi:
driver: local
driver_opts:
type: nfs
o: addr=${NFS_SERVER_IP},ro,nolock
device: ":/mnt/data"
networks:
vlan:
driver: macvlan
driver_opts:
parent: eno1 # Adjust the parent interface based on your host configuration
ipam:
config:
- subnet: 192.168.1.0/24
gateway: 192.168.1.1 # Adjust the gateway based on your network configuration

21
nginx/docker-compose.yml Normal file
View File

@ -0,0 +1,21 @@
version: '3.9'
services:
web:
container_name: nginx-server
image: nginx:latest
ports:
- '80:80'
- '443:443'
volumes:
- ./src:/var/www/html
- ./src/minecraft/mods:/home/thord/minecraft/mods
- ./default.conf:/etc/nginx/conf.d/default.conf
links:
- php-fpm
php-fpm:
container_name: nginx-php-fpm
image: php:8-fpm
volumes:
- ./src:/var/www/html

View File

@ -0,0 +1,14 @@
services:
portainer:
image: portainer/portainer-ce:latest
container_name: portainer
restart: always
ports:
- "8000:8000"
- "9443:9443"
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- portainer_data:/data
volumes:
portainer_data: