Yet another photo library app
Built on top of the amazing RedwoodJS
- Database: PostgreSQL
- Image storing: S3 via minio
- Background jobs: Faktory
- Node.js (for development)
- docker
- docker-compose
Install dependencies and copy environment file
yarn
cp .env.default .env
Adjust .env as you like
Start docker containers
./dcs.sh -e dev up -d
Start worker
yarn s:worker
-- Only on fresh setup:
Prepare database
yarn rw prisma migrate deploy
Prepare S3
./dcs.sh -e dev -t up createbuckets
yarn start
Now you can go on http://localhost:8910
to see the web app.
Lambda functions run on http://localhost:8911
and are also proxied to http://localhost:8910/api/*
.
Upload images to S3
yarn upload -d ./data/images
Then, go on the admin panel and click "scan" or run yarn scan
Stop docker containers, clean volumes/networks
yarn dc:dev:clean
To clean DB/S3/Faktory, remove folders in ./data/dev/...
cp .env.default .env.prod
Adjust .env.prod as you like
Start docker containers
yarn dc:prod up -d
Prepare database
yarn dc:prod up migrate
Setup your Minio users and policies
Upload and scan images
Upload images from a local directory to S3
yarn upload -d ROOT_DIR -p PREFIX
- ROOT_DIR: directory of files to upload
- PREFIX (optional): Add a prefix in S3
Scan images on S3 and add them into the app (DB, tags, miniatures)
yarn scan
- ROOT_DIR: directory of files to upload
- PREFIX (optional): Add a prefix in S3
Used to format log output
yarn upload -d ./data/images | yarn format
yarn scan | yarn format
Open Prisma studio to inspect the database
yarn studio