From da4c279fff5b30af6bdf6d8c999e58a25b64e6cc Mon Sep 17 00:00:00 2001 From: sn0w Date: Sun, 25 Aug 2019 23:41:08 +0200 Subject: [PATCH] documentation updates --- Dockerfile | 2 -- README.md | 2 +- config.dist.exs | 29 +++++++++++++++-------------- docker-compose.yml | 15 +++++++++++---- 4 files changed, 27 insertions(+), 21 deletions(-) diff --git a/Dockerfile b/Dockerfile index 6ea2ebd..ed96195 100644 --- a/Dockerfile +++ b/Dockerfile @@ -61,8 +61,6 @@ WORKDIR /home/pleroma/pleroma # Bust the build cache (if needed) # This works by setting an environment variable with the last # used version/branch/tag/commit/... which originates in the script. -# If the host doesn't have the required tool for "smart version detection" -# we'll just use the current timestamp here which forces a rebuild every time. ARG __CACHE_TAG ENV __CACHE_TAG $__CACHE_TAG diff --git a/README.md b/README.md index 9e275b0..26b2c0f 100644 --- a/README.md +++ b/README.md @@ -53,7 +53,7 @@ For other problems related to this script, contact me or open an issue :) - Clone this repository - Create a `config.exs` and `.env` file - Run `./pleroma.sh build` and `./pleroma.sh up` -- Configure a reverse-proxy +- [Configure a reverse-proxy](#my-instance-is-up-how-do-i-reach-it) - Profit! Hint:
diff --git a/config.dist.exs b/config.dist.exs index 059762c..803a033 100644 --- a/config.dist.exs +++ b/config.dist.exs @@ -1,19 +1,8 @@ use Mix.Config -# pleroma/pleroma/pleroma are the default credentials for the -# managed database container. "db" is the default interlinked hostname. -# You shouldn't need to change this unless you modifed .env -config :pleroma, Pleroma.Repo, - adapter: Ecto.Adapters.Postgres, - username: "pleroma", - password: "pleroma", - database: "pleroma", - hostname: "db", - pool_size: 10 - -# Listening to 0.0.0.0 is required in a container since the IP is not known in advance -# You should not change the options below this. -# Instead, go change the mapping to your host ports in "docker-compose.yml" +# Listening to 0.0.0.0 is required in a container since the IP is not known in advance. +# You should not change the following three ip/port mappings. +# Instead, change the mapping to your host ports in "docker-compose.yml". config :pleroma, Pleroma.Web.Endpoint, http: [ @@ -28,7 +17,19 @@ config :pleroma, :gopher, config :esshd, port: 2222 +# pleroma/pleroma/pleroma are the default credentials. +# "db" is the default interlinked hostname. +# You shouldn't need to change this. +config :pleroma, Pleroma.Repo, + adapter: Ecto.Adapters.Postgres, + username: "pleroma", + password: "pleroma", + database: "pleroma", + hostname: "db" + +# # vvv Your awesome config options go here vvv +# ### # Here are some example values. diff --git a/docker-compose.yml b/docker-compose.yml index dc66a2e..9f4c367 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -5,10 +5,17 @@ services: image: postgres:10-alpine init: true restart: unless-stopped - environment: - POSTGRES_DB: pleroma - POSTGRES_USER: pleroma - POSTGRES_PASSWORD: pleroma + environment: { + # This might seem insecure but is usually not a problem. + # You should leave this at the "pleroma" default. + # The DB is only reachable by containers in the same docker network, + # and is not exposed to the open internet. + # + # If you do change this, remember to update "config.exs". + POSTGRES_DB: pleroma, + POSTGRES_USER: pleroma, + POSTGRES_PASSWORD: pleroma, + } volumes: - $DOCKER_DATADIR/db:/var/lib/postgresql/data - ./initdb.sql:/docker-entrypoint-initdb.d/pleroma.sql