Compare commits

..

3 Commits

Author SHA1 Message Date
derekc 80561ccbc0 created invoice ninja 2026-06-23 00:31:50 -07:00
derekc 2c4545fb15 added arr network to containers 2026-06-18 16:04:40 -07:00
derekc 835815e349 updated seerr nfs compose file to work with new settings 2026-06-18 16:01:35 -07:00
7 changed files with 246 additions and 6 deletions
+6
View File
@@ -21,6 +21,8 @@ services:
resources: resources:
limits: limits:
memory: 512m memory: 512m
networks:
- arr_network
restart: unless-stopped restart: unless-stopped
volumes: volumes:
@@ -31,3 +33,7 @@ volumes:
type: nfs type: nfs
o: "addr=${FLARESOLVERR_NFS_SERVER},rw,noatime,rsize=65536,wsize=65536,timeo=600,nfsvers=4" o: "addr=${FLARESOLVERR_NFS_SERVER},rw,noatime,rsize=65536,wsize=65536,timeo=600,nfsvers=4"
device: "${FLARESOLVERR_NFS_DEVICE}" device: "${FLARESOLVERR_NFS_DEVICE}"
networks:
arr_network:
external: true
+42
View File
@@ -0,0 +1,42 @@
# === Invoice Ninja ===
# Compose infrastructure (image versions, port, NFS)
IN_VERSION=5
IN_NGINX_VERSION=alpine
IN_DB_VERSION=8
IN_PORT=8080
IN_NFS_SERVER=your-nfs-server-ip
IN_NFS_PUBLIC_DEVICE=:/path/to/invoice-ninja/public
IN_NFS_STORAGE_DEVICE=:/path/to/invoice-ninja/storage
IN_NFS_DB_DEVICE=:/path/to/invoice-ninja/db
# Application
# Generate with: docker compose run --rm app php artisan key:generate --show
APP_KEY=base64:REPLACE_WITH_GENERATED_KEY
APP_URL=https://invoices.yourdomain.com
NINJA_ENVIRONMENT=selfhosted
# Database
DB_HOST=db
DB_PORT=3306
DB_ROOT_PASSWORD=changeme
DB_DATABASE=invoiceninja
DB_USERNAME=invoiceninja
DB_PASSWORD=changeme
# Queue / Cache (defaults work for most self-hosted setups)
QUEUE_CONNECTION=database
CACHE_DRIVER=file
SESSION_DRIVER=file
PDF_GENERATOR=snappdf
LOG_CHANNEL=stderr
# Mail (SMTP)
MAIL_MAILER=smtp
MAIL_HOST=smtp.yourdomain.com
MAIL_PORT=587
MAIL_USERNAME=your@email.com
MAIL_PASSWORD=changeme
MAIL_ENCRYPTION=tls
MAIL_FROM_ADDRESS=invoices@yourdomain.com
MAIL_FROM_NAME=Invoice Ninja
+126
View File
@@ -0,0 +1,126 @@
services:
db:
image: mysql:${IN_DB_VERSION:-8}
container_name: invoice-ninja-db
environment:
MYSQL_ROOT_PASSWORD: ${DB_ROOT_PASSWORD}
MYSQL_DATABASE: ${DB_DATABASE:-invoiceninja}
MYSQL_USER: ${DB_USERNAME:-invoiceninja}
MYSQL_PASSWORD: ${DB_PASSWORD}
volumes:
- in-db:/var/lib/mysql
healthcheck:
test: ["CMD", "mysqladmin", "ping", "-h", "localhost", "-u", "root", "-p${DB_ROOT_PASSWORD}"]
interval: 10s
timeout: 5s
retries: 5
start_period: 30s
deploy:
resources:
limits:
memory: 512m
restart: unless-stopped
app:
image: invoiceninja/invoiceninja:${IN_VERSION:-5}
container_name: invoice-ninja-app
env_file: .env
volumes:
- in-public:/var/www/app/public
- in-storage:/var/www/app/storage
depends_on:
db:
condition: service_healthy
healthcheck:
test: ["CMD", "php", "artisan", "--version"]
interval: 30s
timeout: 15s
retries: 5
start_period: 90s
deploy:
resources:
limits:
memory: 512m
restart: unless-stopped
scheduler:
image: invoiceninja/invoiceninja:${IN_VERSION:-5}
container_name: invoice-ninja-scheduler
env_file: .env
entrypoint: ""
command: ["sh", "-c", "while true; do php /var/www/app/artisan schedule:run --no-interaction; sleep 60; done"]
volumes:
- in-public:/var/www/app/public
- in-storage:/var/www/app/storage
depends_on:
app:
condition: service_healthy
deploy:
resources:
limits:
memory: 256m
restart: unless-stopped
queue:
image: invoiceninja/invoiceninja:${IN_VERSION:-5}
container_name: invoice-ninja-queue
env_file: .env
entrypoint: ""
command: ["php", "/var/www/app/artisan", "queue:work", "--sleep=3", "--tries=3"]
volumes:
- in-public:/var/www/app/public
- in-storage:/var/www/app/storage
depends_on:
app:
condition: service_healthy
deploy:
resources:
limits:
memory: 256m
restart: unless-stopped
nginx:
image: nginx:${IN_NGINX_VERSION:-alpine}
container_name: invoice-ninja-nginx
volumes:
- in-public:/var/www/app/public
- ./nginx/nginx.conf:/etc/nginx/conf.d/default.conf:ro
ports:
- ${IN_PORT:-8080}:80
depends_on:
app:
condition: service_healthy
healthcheck:
test: ["CMD-SHELL", "[ -f /var/run/nginx.pid ] && kill -0 $(cat /var/run/nginx.pid) || exit 1"]
interval: 30s
timeout: 10s
retries: 3
start_period: 30s
deploy:
resources:
limits:
memory: 128m
restart: unless-stopped
volumes:
in-public:
name: invoice-ninja-public
driver: local
driver_opts:
type: nfs
o: "addr=${IN_NFS_SERVER},rw,noatime,rsize=65536,wsize=65536,timeo=600,nfsvers=4"
device: "${IN_NFS_PUBLIC_DEVICE}"
in-storage:
name: invoice-ninja-storage
driver: local
driver_opts:
type: nfs
o: "addr=${IN_NFS_SERVER},rw,noatime,rsize=65536,wsize=65536,timeo=600,nfsvers=4"
device: "${IN_NFS_STORAGE_DEVICE}"
in-db:
name: invoice-ninja-db
driver: local
driver_opts:
type: nfs
o: "addr=${IN_NFS_SERVER},rw,noatime,rsize=65536,wsize=65536,timeo=600,nfsvers=4"
device: "${IN_NFS_DB_DEVICE}"
+33
View File
@@ -0,0 +1,33 @@
server {
listen 80;
server_name _;
root /var/www/app/public;
index index.php;
client_max_body_size 100M;
add_header X-Frame-Options "SAMEORIGIN";
add_header X-Content-Type-Options "nosniff";
charset utf-8;
location / {
try_files $uri $uri/ /index.php?$query_string;
}
location = /favicon.ico { access_log off; log_not_found off; }
location = /robots.txt { access_log off; log_not_found off; }
error_page 404 /index.php;
location ~ \.php$ {
fastcgi_pass app:9000;
fastcgi_param SCRIPT_FILENAME $realpath_root$fastcgi_script_name;
include fastcgi_params;
}
location ~ /\.(?!well-known).* {
deny all;
}
}
+6
View File
@@ -22,6 +22,8 @@ services:
resources: resources:
limits: limits:
memory: 512m memory: 512m
networks:
- arr_network
restart: unless-stopped restart: unless-stopped
volumes: volumes:
@@ -39,3 +41,7 @@ volumes:
type: nfs type: nfs
o: "addr=${JACKETT_NFS_SERVER},rw,noatime,rsize=65536,wsize=65536,timeo=600,nfsvers=4" o: "addr=${JACKETT_NFS_SERVER},rw,noatime,rsize=65536,wsize=65536,timeo=600,nfsvers=4"
device: "${JACKETT_DOWNLOADS_NFS_DEVICE}" device: "${JACKETT_DOWNLOADS_NFS_DEVICE}"
networks:
arr_network:
external: true
+25 -4
View File
@@ -1,17 +1,38 @@
services: services:
app: app:
image: seerr/seerr:latest image: seerr/seerr:${SEERR_VERSON:-latest}
init: true init: true
environment: environment:
- LOG_LEVEL=debug - LOG_LEVEL=debug
- TZ=${SEERR_TZ} - TZ=${SEERR_TZ:-America/Los_Angeles}
- PORT=5055 - PORT=5055
ports: ports:
- ${SEERR_PORT}:5055 - ${SEERR_PORT}:5055
volumes: volumes:
- seerr:/app/config - seerr-app:/app/config
healthcheck:
test: ["CMD-SHELL", "wget --no-verbose --tries=1 --spider http://localhost:5055/api/v1/settings/public || exit 1"]
start_period: 20s
timeout: 3s
interval: 15s
retries: 3
deploy:
resources:
limits:
memory: 512M
networks:
- arr_network
restart: unless-stopped restart: unless-stopped
volumes: volumes:
seerr: seerr-app:
name: seerr-app
driver: local
driver_opts:
type: nfs
o: "addr=${SEERR_NFS_SERVER},rw,noatime,rsize=65536,wsize=65536,timeo=600,nfsvers=4"
device: "${SEERR_NFS_DEVICE}"
networks:
arr_network:
external: true external: true
@@ -36,6 +36,8 @@ services:
resources: resources:
limits: limits:
memory: 512m memory: 512m
networks:
- arr_network
restart: unless-stopped restart: unless-stopped
volumes: volumes:
@@ -46,3 +48,7 @@ volumes:
type: nfs type: nfs
o: "addr=${TRANSMISSION_OPENVPN_NFS_SERVER},rw,noatime,rsize=65536,wsize=65536,timeo=600,nfsvers=4" o: "addr=${TRANSMISSION_OPENVPN_NFS_SERVER},rw,noatime,rsize=65536,wsize=65536,timeo=600,nfsvers=4"
device: "${TRANSMISSION_OPENVPN_NFS_DEVICE}" device: "${TRANSMISSION_OPENVPN_NFS_DEVICE}"
networks:
arr_network:
external: true