-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.env.example
More file actions
120 lines (95 loc) · 4.35 KB
/
.env.example
File metadata and controls
120 lines (95 loc) · 4.35 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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Variables used to:
# - create and configure 2 databases running inside a Docker container
# The postgres and web ap databases are created **once** when the postgres container
# (aka. learn-dev-postgres service) is run for **the first time**.
# - configure the Docker external port mapping for the postgres container
#
# Procedure:
# - Set a value for POSTGRES_PASSWORD, LEARNDEV_DB_PASSWORD, MONGO_ROOT_PASSWORD
# - Leave other variables unchanged because defaults are fine.
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# ~~~ External port mapping for the postgres Docker container ~~~~~~~~~~~~~~~~~~~~~
# Host port mapped to the internal Postgres container's port 5432.
# Only the host side is configurable here. 5432 is fixed inside the container.
# Use a non-standard port (e.g. 5433) to avoid clashing with a local Postgres install.
# See: https://docs.docker.com/engine/reference/commandline/run/#publish
#
POSTGRES_PORT=5433
# Exposed postgres host network interface.
# Docker accepts incoming requests on this interface and routes them
# to Postgres running in the Docker container.
# Default value (if unset) is 0.0.0.0 (IP v4) and :: (IP V6),
# meaning all network interfaces.
# See: https://docs.docker.com/engine/reference/commandline/run/#publish
#
POSTGRES_HOST=127.0.0.1
## ~~~ Postgres database and user ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Name of the Postgres superuser
# Default value is postgres.
# See: https://hub.docker.com/_/postgres#postgres_user
#
# POSTGRES_USER=postgres
# Name of the default database.
# Default value is the same as POSTGRES_USER (if set), otherwise postgres.
# See: https://hub.docker.com/_/postgres#postgres_db
#
# POSTGRES_DB=postgres
# Authentication method used for host connections.
# Use scram-sha-256 for password authentication.
# See: https://hub.docker.com/_/postgres#postgres_host_auth_method
#
POSTGRES_HOST_AUTH_METHOD=scram-sha-256
# This is the superuser password.
# This is NOT the application database user password.
# See: https://hub.docker.com/_/postgres#postgres_password
#
POSTGRES_PASSWORD=TODO_SET_A_VALUE_HERE
# ~~~ Postgres application database and user ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Created by docker/init/01-create-app-db-user.sh **on first** container start.
# These variables are also referenced in Spring Boot's application.yaml
# configuration file to configure the datasource.
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Name of the (Postgres) application database,
#
LEARNDEV_DB_NAME=learndev
# Name of the application database "user" (regular role, not a superuser role).
#
LEARNDEV_DB_USER=learndev
# Password for the application database user (role).
# This is NOT the superuser password.
#
LEARNDEV_DB_PASSWORD=TODO_SET_A_VALUE_HERE
# ~~~~ MongoDB ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Name of the MongoDB admin user
#
MONGO_ROOT_USERNAME=mongoadmin
# Password for the MongoDB admin user
#
MONGO_ROOT_PASSWORD=TODO_SET_A_VALUE_HERE
# Name of the MongoDB application database
#
LEARNDEV_MONGO_DB_NAME=learndev
# ~~~ External port mapping for the mongo Docker Compose service ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Exposed MongoDB host network interface.
# Docker accepts incoming requests on this interface and routes them
# to MongoDB running in the Docker container.
# Default value (**if unset**) is 0.0.0.0 (IP v4) and :: (IP V6),
# meaning all network interfaces.
# See: https://docs.docker.com/engine/reference/commandline/run/#publish
#
MONGO_HOST=127.0.0.1
# MongoDB port mapped to the internal mongo container's port 27017.
# Only the host side is configurable here. 27017 is fixed inside the container.
# Use a non-standard port (e.g. 27018) to avoid clashing with a local MongoDB install.
#
MONGO_PORT=27018
# ~~~~ Spring Boot ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Default Spring Boot active profile: dev
# Do not set SPRING_PROFILES_ACTIVE for test/staging/production environments,
# because they will be set somewhere else.
# Loads app configuration from application.yaml, then overrides it
# with application-dev.yaml.
# See: https://docs.spring.io/spring-boot/3.5/how-to/properties-and-configuration.html#howto.properties-and-configuration.set-active-spring-profiles
#
SPRING_PROFILES_ACTIVE=dev