diff --git a/compose.yml b/compose.yml index bec64f6..65c6e6f 100644 --- a/compose.yml +++ b/compose.yml @@ -64,8 +64,6 @@ services: internal: command: --config "/etc/mongod.conf" --replSet rs - # TODO: S3 uploads from the servers use the first part of the path (like - # "mii") as the bucket name instead of "pn-cdn". Why? minio: image: minio/minio:latest ports: diff --git a/config/minio-init.sh b/config/minio-init.sh index 466709c..d09c4f8 100644 --- a/config/minio-init.sh +++ b/config/minio-init.sh @@ -5,9 +5,9 @@ set -eu mc alias set minio http://minio:9000 "$MINIO_ROOT_USER" "$MINIO_ROOT_PASSWORD" mc admin info minio -buckets="mii paintings screenshots" +buckets="pn-cdn" -# Create a bucket named mii and allow public access +# Create buckets allow public access for bucket in $buckets; do mc mb "minio/$bucket" mc anonymous set download "minio/$bucket" diff --git a/config/nginx/cdn.conf b/config/nginx/cdn.conf index 13aa2b2..2506edf 100644 --- a/config/nginx/cdn.conf +++ b/config/nginx/cdn.conf @@ -2,7 +2,7 @@ server { listen 80; server_name cdn.pretendo.cc; - set $upstream http://minio:9000; + set $upstream http://pn-cdn.minio:9000; location / { limit_except GET HEAD { deny all; diff --git a/config/website-config.json b/config/website-config.json index 327332e..63124ae 100644 --- a/config/website-config.json +++ b/config/website-config.json @@ -1,7 +1,7 @@ { "http": { "port": 8080, - "base_url": "http://www.pretendo.cc" + "base_url": "https://pretendo.network" }, "api_base": "http://api.pretendo.cc", "database": { diff --git a/environment/minio.env b/environment/minio.env index e69de29..1680ce3 100644 --- a/environment/minio.env +++ b/environment/minio.env @@ -0,0 +1 @@ +MINIO_DOMAIN=minio