sightbox/scripts/dev.sh

29 lines
982 B
Bash
Executable File

#!/usr/bin/env bash
# Local iteration loop: build both custom images for this machine's own
# architecture (fast, no registry push — see erpnext-image/build.sh and
# backend/build.sh's own local-vs-registry branching) and bring the
# affected services up immediately so you can test against them. Run this
# as often as you want while developing; nothing here touches git or the
# registry — see scripts/prod.sh for shipping what you've tested here.
#
# Usage (from the sightbox/ project root or from here — either works):
# ./scripts/dev.sh
set -euo pipefail
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
ROOT_DIR="$(cd "${SCRIPT_DIR}/.." && pwd)"
cd "$ROOT_DIR"
./erpnext-image/build.sh
./backend/build.sh
echo
echo "Bringing up the affected services locally..."
docker compose up -d --force-recreate \
configurator backend frontend websocket queue-short queue-long scheduler \
backend-billing
echo
echo "Done — test against your local stack now."