-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathdocker-compose.yaml
49 lines (49 loc) · 1.71 KB
/
docker-compose.yaml
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
41
42
43
44
45
46
47
48
49
version: "3.9"
services:
db:
# Use the official postgres:15 image
image: postgres:15
restart: always
environment:
# Set the password, username and database name
POSTGRES_PASSWORD: postgres
POSTGRES_USER: postgres
POSTGRES_DB: wiggle-paw
volumes:
# Map the local pgdata folder to the container's /var/lib/postgresql/data directory
- ./pgdata:/var/lib/postgresql/data
ports:
# Expose port 6969 on the host to port 5432 in the container
- "6969:5432"
minio:
# Use minio for local development storage (compatible with S3).
# Production storage maybe other service like AWS S3, Cloudfare R2, etc.
image: minio/minio:latest
restart: always
environment:
MINIO_ROOT_USER: "root"
MINIO_ROOT_PASSWORD: "password"
MINIO_API_CORS_ALLOW_ORIGIN: "*"
volumes:
# Map the local storage folder to the container's /data/minio directory
- ./s3-data:/data/minio
ports:
# Expose port 9003 on the host to port 9000 in the container.
# This is for the minio server.
- "9003:9000"
# Expose port 9099 on the host to port 9090 in the container.
# This is for the minio console.
- "9099:9090"
command: minio server /data/minio --console-address ":9090"
minio-mc:
# Use minio client to create a bucket for the minio server.
image: minio/mc:latest
depends_on:
- minio
entrypoint: >
/bin/sh -c "
mc config host add minio http://minio:9000 root password;
mc mb --quiet minio/wigglepaw;
mc anonymous set download minio/wigglepaw;
mc admin user svcacct add --access-key J9jiu0i7jrqoJEwO --secret-key 29oOdS0Buo99jA4KXeKwLfbK1cTbIDpm minio root
"