chore: update instructions

This commit is contained in:
digikwal 2025-06-24 17:09:57 +02:00
parent a92deb6cc5
commit cf37a7f757
No known key found for this signature in database
4 changed files with 70 additions and 2 deletions

View file

@ -3,6 +3,13 @@
Everything about [Frappe](https://github.com/frappe/frappe) and [ERPNext](https://github.com/frappe/erpnext) in containers. Everything about [Frappe](https://github.com/frappe/frappe) and [ERPNext](https://github.com/frappe/erpnext) in containers.
# First things first
I recommend adding the following to bashrc, profile or whatever loads on login, ssh etc..:
```sh
export APPS_JSON_BASE64=$(base64 -w 0 /home/frappe/frappe_docker/apps.json)
```
# Getting Started # Getting Started
To get started you need [Docker](https://docs.docker.com/get-docker/), [docker-compose](https://docs.docker.com/compose/), and [git](https://docs.github.com/en/get-started/getting-started-with-git/set-up-git) setup on your machine. For Docker basics and best practices refer to Docker's [documentation](http://docs.docker.com). To get started you need [Docker](https://docs.docker.com/get-docker/), [docker-compose](https://docs.docker.com/compose/), and [git](https://docs.github.com/en/get-started/getting-started-with-git/set-up-git) setup on your machine. For Docker basics and best practices refer to Docker's [documentation](http://docs.docker.com).

14
apps.json Normal file
View file

@ -0,0 +1,14 @@
[
{
"url": "https://github.com/frappe/erpnext",
"branch": "version-15"
},
{
"url": "https://github.com/frappe/builder",
"branch": "master"
},
{
"url": "https://github.com/digikwal/fieldmate",
"branch": "main"
}
]

View file

@ -31,14 +31,19 @@ services:
- --certificatesresolvers.le.acme.email=${EMAIL:?No EMAIL set} - --certificatesresolvers.le.acme.email=${EMAIL:?No EMAIL set}
# Store the Let's Encrypt certificates in the mounted volume # Store the Let's Encrypt certificates in the mounted volume
- --certificatesresolvers.le.acme.storage=/certificates/acme.json - --certificatesresolvers.le.acme.storage=/certificates/acme.json
# Use the TLS Challenge for Let's Encrypt # Use the DNS Challenge for Let's Encrypt
- --certificatesresolvers.le.acme.tlschallenge=true - --certificatesresolvers.le.acme.dnschallenge=true
- --certificatesresolvers.le.acme.dnschallenge.provider=cloudflare
- --certificatesresolvers.le.acme.dnschallenge.resolvers=1.1.1.1:53
# Enable the access log, with HTTP requests # Enable the access log, with HTTP requests
- --accesslog - --accesslog
# Enable the Traefik log, for configurations and errors # Enable the Traefik log, for configurations and errors
- --log - --log
# Enable the Dashboard and API # Enable the Dashboard and API
- --api - --api
environment:
- CF_API_EMAIL=${CF_API_EMAIL}
- CF_DNS_API_TOKEN=${CF_API_KEY}
ports: ports:
- ${HTTPS_PUBLISH_PORT:-443}:443 - ${HTTPS_PUBLISH_PORT:-443}:443
volumes: volumes:

42
stack.sh Executable file
View file

@ -0,0 +1,42 @@
#!/bin/sh
# Usage: ./stack.sh up -d or ./stack.sh down --remove-orphans
set -e
ACTION="$1"
shift
ARGS="$@"
if [ "$ACTION" != "up" ] && [ "$ACTION" != "down" ]; then
echo "Usage: $0 up|down [extra docker compose flags]"
exit 1
fi
cd /home/frappe/frappe_docker || {
echo "Cannot find directory /home/frappe/frappe_docker"
exit 1
}
# Uncomment this block when using traefik container by frappe
# echo "==> Traefik $ACTION $ARGS"
# docker compose \
# --project-name traefik \
# --env-file /home/frappe/gitops/traefik.env \
# -f overrides/compose.traefik.yaml \
# -f overrides/compose.traefik-ssl.yaml \
# "$ACTION" $ARGS
# Uncomment this block when using mariadb container by frappe
echo "==> MariaDB $ACTION $ARGS"
docker compose \
--project-name mariadb \
--env-file /home/frappe/gitops/mariadb.env \
-f overrides/compose.mariadb-shared.yaml \
"$ACTION" $ARGS
echo "==> ERPNext $ACTION $ARGS"
docker compose \
--project-name erpnext-one \
-f /home/frappe/gitops/erpnext-one.yaml \
"$ACTION" $ARGS