-
-
Save AlbinoDrought/843e588d16063248c2e30ec53c711312 to your computer and use it in GitHub Desktop.
Invoice-Ninja for Rancher
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '2' | |
volumes: | |
invoiceninja-db: | |
external: true | |
driver: rancher-nfs | |
invoiceninja-storage: | |
external: true | |
driver: rancher-nfs | |
invoiceninja-logo: | |
external: true | |
driver: rancher-nfs | |
services: | |
app: | |
image: invoiceninja/invoiceninja | |
environment: | |
DB_DATABASE: ninja | |
DB_HOST: mysql | |
DB_PASSWORD: pwd | |
DB_USERNAME: ninja | |
volumes: | |
- invoiceninja-storage:/var/www/app/storage | |
- invoiceninja-logo:/var/www/app/public/logo | |
links: | |
- db:mysql | |
labels: | |
io.rancher.container.pull_image: always | |
cron: | |
image: invoiceninja/invoiceninja | |
environment: | |
DB_DATABASE: ninja | |
DB_HOST: mysql | |
DB_PASSWORD: pwd | |
DB_USERNAME: ninja | |
entrypoint: | |
- bash | |
- -c | |
- |- | |
bash -s <<EOF | |
trap "break;exit" SIGHUP SIGINT SIGTERM | |
sleep 300s | |
while /bin/true; do | |
/usr/local/bin/php /var/www/app/artisan ninja:send-invoices | |
/usr/local/bin/php /var/www/app/artisan ninja:send-reminders | |
sleep 1d | |
done | |
EOF | |
volumes_from: | |
- app | |
links: | |
- db:mysql | |
labels: | |
io.rancher.container.pull_image: always | |
db: | |
image: mysql:5 | |
environment: | |
MYSQL_DATABASE: ninja | |
MYSQL_PASSWORD: pwd | |
MYSQL_ROOT_PASSWORD: pwd | |
MYSQL_USER: ninja | |
volumes: | |
- invoiceninja-db:/var/lib/mysql | |
labels: | |
io.rancher.container.pull_image: always |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '2' | |
services: | |
app: | |
scale: 1 | |
start_on_create: true | |
cron: | |
scale: 1 | |
start_on_create: true | |
db: | |
scale: 1 | |
start_on_create: true |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment