-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjustfile
More file actions
40 lines (31 loc) · 1.83 KB
/
justfile
File metadata and controls
40 lines (31 loc) · 1.83 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
set dotenv-load := true
set dotenv-filename := ".ENV"
help:
@just --list --unsorted
wasm:
./Scripts/build-bytesized-cafe-app.sh
site:
swift run bytesized
site-release:
swift run -c release bytesized
site-local:
test -n "${BYTESIZED_CAFE_API_URL:-}" || (echo "Missing BYTESIZED_CAFE_API_URL. Set it in .ENV or your shell." >&2; exit 1)
BYTESIZED_CAFE_API_URL="${BYTESIZED_CAFE_API_URL}" swift run bytesized
backend:
test -n "${OPENAI_API_KEY:-}" || (echo "Missing OPENAI_API_KEY. Set it in .ENV or your shell." >&2; exit 1)
test -n "${GENERATED_IMAGES_BUCKET:-}" || (echo "Missing GENERATED_IMAGES_BUCKET. Set it in .ENV or your shell." >&2; exit 1)
test -n "${OPENAI_IMAGE_MODEL:-}" || (echo "Missing OPENAI_IMAGE_MODEL. Set it in .ENV or your shell." >&2; exit 1)
test -n "${IMAGE_GEN_PREFIX:-}" || (echo "Missing IMAGE_GEN_PREFIX. Set it in .ENV or your shell." >&2; exit 1)
test -n "${AWS_REGION:-}" || (echo "Missing AWS_REGION. Set it in .ENV or your shell." >&2; exit 1)
test -n "${AWS_ACCESS_KEY_ID:-}" || (echo "Missing AWS_ACCESS_KEY_ID. Set it in .ENV or your shell." >&2; exit 1)
test -n "${AWS_SECRET_ACCESS_KEY:-}" || (echo "Missing AWS_SECRET_ACCESS_KEY. Set it in .ENV or your shell." >&2; exit 1)
test -n "${HOST:-${BACKEND_HOST:-}}" || (echo "Missing HOST or BACKEND_HOST. Set it in .ENV or your shell." >&2; exit 1)
test -n "${PORT:-${BACKEND_PORT:-}}" || (echo "Missing PORT or BACKEND_PORT. Set it in .ENV or your shell." >&2; exit 1)
swift run --package-path Backend Server
site-deploy:
test -n "${AWS_S3_BUCKET:-}" || (echo "Missing AWS_S3_BUCKET. Set it in .ENV or your shell." >&2; exit 1)
aws s3 sync Output/ "s3://${AWS_S3_BUCKET}" --delete --exclude ".DS_Store"
local:
./Scripts/run-local.sh
validate-deployment:
./Scripts/validate-deployment-config.sh