forked from mozilla/fxa-auth-db-mysql
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
114 lines (78 loc) · 2.78 KB
/
Dockerfile
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
FROM node:5.5-slim
#FROM mhart/alpine-node
#RUN adduser -S fxa
COPY bin /app/bin
COPY config /app/config
COPY fxa-auth-db-server /app/fxa-auth-db-server
COPY lib /app/lib
COPY test /app/test
ADD AUTHORS /app/AUTHORS
ADD CONTRIBUTING.md /app/CONTRIBUTING.md
ADD LICENSE /app/LICENSE
ADD README.md /app/README.md
ADD index.js /app/index.js
ADD package.json /app/package.json
WORKDIR /app
EXPOSE 8000
RUN ["cat", "/etc/hosts"]
RUN ["npm", "install", "--production"]
# The current node.js environment
ENV NODE_ENV prod
# The IP address the server should bind to
ENV HOST 127.0.0.1
# The port the server should bind to
ENV PORT 8000
ENV LOG_LEVEL info
# The name of the row in the dbMetadata table which stores the patch level
ENV SCHEMA_PATCH_KEY schema-patch-level
# Enables (true) or disables (false) pruning
ENV ENABLE_PRUNING false
# Approximate time between prunes (in ms)
ENV PRUNE_EVERY 30 minutes
# The user to connect to for MySql
ENV MYSQL_USER root
# The password to connect to for MySql
ENV MYSQL_PASSWORD=
# The database to connect to for MySql
ENV MYSQL_DATABASE fxa
# The host to connect to for MySql
ENV MYSQL_HOST 127.0.0.1
# The port to connect to for MySql
ENV MYSQL_PORT 3306
# The maximum number of connections to create at once.
ENV MYSQL_CONNECTION_LIMIT 10
# Determines the pools action when no connections are available and the limit has been reached.
ENV MYSQL_WAIT_FOR_CONNECTIONS true
# Determines the maximum size of the pools waiting-for-connections queue.
ENV MYSQL_QUEUE_LIMIT 100
# The user to connect to for MySql
ENV MYSQL_SLAVE_USER root
# The password to connect to for MySql
ENV MYSQL_SLAVE_PASSWORD=
# The database to connect to for MySql
ENV MYSQL_SLAVE_DATABASE fxa
# The host to connect to for MySql
ENV MYSQL_SLAVE_HOST 127.0.0.1
# The port to connect to for MySql
ENV MYSQL_SLAVE_PORT 3306
# The maximum number of connections to create at once.
ENV MYSQL_SLAVE_CONNECTION_LIMIT 10
# Determines the pools action when no connections are available and the limit has been reached.
ENV MYSQL_SLAVE_WAIT_FOR_CONNECTIONS true
# Determines the maximum size of the pools waiting-for-connections queue.
ENV MYSQL_SLAVE_QUEUE_LIMIT 100
# Url at which to publish account lifecycle events (empty to disable publishing).
ENV NOTIFICATIONS_PUBLISH_URL=
# Interval to sleep between polling for unpublished events in seconds
ENV NOTIFICATIONS_POLL_INTERVAL 10
# Secret key to use for signing JWTs a PEM-encoded file.
#ENV NOTIFICATIONS_JWT_SECRET_KEY_FILE priv.pem
# Issuer field to use for JWTs.
ENV NOTIFICATIONS_JWT_ISS localhost
# Key-ID field to use for JWTs.
ENV NOTIFICATIONS_JWT_KID test
# JWK url field to use for JWTs.
ENV NOTIFICATIONS_JWT_JKU localhost
# CMD ["npm", "start"]
#RUN ["node", "./bin/db_patcher.js"]
CMD ["node", "./bin/server.js"]