-
Notifications
You must be signed in to change notification settings - Fork 28
/
config.sample.toml
293 lines (223 loc) · 9.21 KB
/
config.sample.toml
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
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
# Configuration sample for Gasper
############################
# Global Configuration #
############################
# Run Gasper in Debug mode ?
# Set this value to `false` in Production.
debug = true
# Root domain for all deployed applications and databases.
domain = "sdslabs.co"
# Secret Key used for internal communication in the Gasper ecosystem.
secret = "YOUR_SECRET_KEY"
# Root of the deployed application in the docker container's filesystem.
project_root = "/gasper"
# Name of the file used for building and running applications.
# This file is application specific and must be present in an application's git repository's root.
# The contents of the file must be linux shell commands separated by newlines.
rc_file = "Gasperfile.txt"
# Run Gasper in Offline mode.
# For Development purposes only.
offline_mode = false
# DNS nameservers used by docker containers created by Gasper.
dns_servers = [
"8.8.8.8",
"8.8.4.4",
]
###########################
# Admin Configuration #
###########################
# Default admin credentials for the Gasper ecosystem.
[admin]
email = "[email protected]"
username = "alphadose"
password = "alphadose"
#############################
# MongoDB Configuration #
#############################
[mongo]
# For databases with authentication
# use the following URL format `mongodb://username:password@host:port/?authSource=admin`.
url = "mongodb://alphadose:alphadose@localhost:27019/?authSource=admin"
###########################
# Redis Configuration #
###########################
# Acts as a central-registry for the Gasper ecosystem.
[redis]
host = "localhost"
port = 6380
password = "alphadose"
db = 0
#########################
# JWT Configuration #
#########################
# Configuration for the JSON Web Token (JWT) authentication mechanism.
[jwt]
# timeout refers to the duration in which the JWT is valid.
# max_refresh refers to the duration in which the JWT can be refreshed after its expiry.
# Both timeout and max_refresh are in seconds
# Total refresh time = max_refresh + timeout
timeout = 3600 # 1 hour
max_refresh = 2419200 # 28 days
################################
# CloudFlare Configuration #
################################
[cloudflare]
# API Token used for creating/updating Cloudflare's DNS records.
# This token must have the scopes ZONE:ZONE:EDIT and ZONE:DNS:EDIT.
api_token = ""
plugin = false # Use Cloudflare Plugin?
public_ip = "" # IPv4 address for Cloudflare's DNS records to point to.
###################################
# Docker Images Configuration #
###################################
[images]
static = "docker.io/sdslabs/static:latest"
php = "docker.io/sdslabs/php:latest"
nodejs = "docker.io/sdslabs/node:latest"
python2 = "docker.io/sdslabs/python2:latest"
python3 = "docker.io/sdslabs/python3:latest"
golang = "docker.io/sdslabs/golang:latest"
ruby = "docker.io/sdslabs/ruby:latest"
rust = "docker.io/sdslabs/rust:latest"
mysql = "docker.io/mysql:latest"
mongodb = "docker.io/sdslabs/alpine-mongo:latest"
postgresql = "docker.io/postgres:latest"
redis = "docker.io/redis:6.0-rc3-alpine3.11"
##############################
# Services Configuration #
##############################
# Configuration for the various microservices comprising the Gasper ecosystem.
[services]
# Time Interval (in seconds) in which the current node updates
# the central registry-server with the status of its microservices.
exposure_interval = 30
# Rate limit of deploying number of app/DB per unit time
# Set rate_limit = -1 if no rate limit is to be imposed
rate_limit = 2
# Time interval (in hours) for rate limiting for App/DB creation
rate_interval = 24
############################
# Master Configuration #
############################
[services.master]
# Time Interval (in seconds) in which `Master` sends health-check probes
# to all worker nodes and removes inactive nodes from the central registry-server.
cleanup_interval = 600
deploy = true # Deploy Master?
port = 3000
# Configuration for the MongoDB service container required by all deployed services.
[services.master.mongodb]
plugin = true # Deploy MongoDB server and let `Master` manage it?
container_port = 27019 # Port on which the MongoDB server container will run
# Environment variables for MongoDB docker container.
[services.master.mongodb.env]
MONGO_INITDB_ROOT_USERNAME = "alphadose" # Root user of MongoDB server inside the container
MONGO_INITDB_ROOT_PASSWORD = "alphadose" # Root password of MongoDB server inside the container
# Configuration for the Redis service container required by all deployed services.
[services.master.redis]
plugin = true # Deploy Redis server and let `Master` manage it?
container_port = 6380 # Port on which the Redis server container will run
password = "alphadose"
##############################
# GenProxy Configuration #
##############################
[services.genproxy]
# Time Interval (in seconds) in which `GenProxy` updates its
# `Reverse-Proxy Record Storage` by polling the central registry-server.
record_update_interval = 15
deploy = false # Deploy GenProxy?
port = 80
# Configuration for using SSL with `GenProxy`.
[services.genproxy.ssl]
plugin = false # Use SSL with GenProxy?
port = 443
certificate = "/home/user/fullchain.pem" # Certificate Location
private_key = "/home/user/privkey.pem" # Private Key Location
##############################
# AppMaker Configuration #
##############################
[services.appmaker]
deploy = true # Deploy AppMaker?
port = 4000
# Time Interval (in seconds) in which metrics of all application containers
# running in the current node are collected and stored in the central mongoDB database
metrics_interval = 600
# Time Interval (in seconds) in which health is checked of all application containers and if unhealthy, they are restarted
health_interval = 300
# Hard Limits the total number of app instances that can be deployed by an user
# Set app_limit = -1 if no hard limit is to be imposed
app_limit = 10
#############################
# DbMaker Configuration #
#############################
[services.dbmaker]
deploy = false # Deploy DbMaker?
port = 9000
# Hard Limits the total number of db instances that can be deployed by an user
# Set db_limit = -1 if no hard limit is to be imposed
db_limit= 10
# Configuration for MySQL database server managed by `DbMaker`
[services.dbmaker.mysql]
plugin = false # Deploy MySQL server and let `DbMaker` manage it?
container_port = 33061 # Port on which the MySQL server container will run
# Environment variables for MySQL docker container.
[services.dbmaker.mysql.env]
MYSQL_ROOT_PASSWORD = "YOUR_MYSQL_PASSWORD" # Root password of MySQL server inside the container
# Configuration for PostgreSQL database server managed by `DbMaker`
[services.dbmaker.postgresql]
plugin = false # Deploy PostgreSQL server and let `DbMaker` manage it?
container_port = 29121 # Port on which the PostgreSQL server container will run
# Environment variables for PostgreSQL docker container.
[services.dbmaker.postgresql.env]
POSTGRES_USER = "YOUR_ROOT_NAME" # Root user of PostgreSQL server inside the container
POSTGRES_PASSWORD = "YOUR_ROOT_PASSWORD" # Root password of PostgreSQL server inside the container
# Configuration for MongoDB database server managed by `DbMaker`
[services.dbmaker.mongodb]
plugin = false # Deploy MongoDB server and let `DbMaker` manage it
container_port = 27018 # Port on which the MongoDB server container will run
# Environment variables for MongoDB docker container.
[services.dbmaker.mongodb.env]
MONGO_INITDB_ROOT_USERNAME = "YOUR_ROOT_NAME" # Root user of MongoDB server inside the container
MONGO_INITDB_ROOT_PASSWORD = "YOUR_ROOT_PASSWORD" # Root password of MongoDB server inside the container
# Configuration for Redis database server managed by `DbMaker`
[services.dbmaker.redis]
plugin = false # Deploy RedisDB server and let `DbMaker` manage it
############################
# GenDNS Configuration #
############################
[services.gendns]
# Time Interval (in seconds) in which `GenDNS` updates its
# `DNS Record Storage` by polling the central registry-server.
record_update_interval = 15
deploy = false # Deploy GenDNS?
port = 53
############################
# GenSSH Configuration #
############################
[services.genssh]
deploy = false # Deploy GenSSH?
port = 2222
# Location of Private Key for creating the SSH Signer.
host_signers = ["/home/user/.ssh/id_rsa"]
using_passphrase = false # Private Key is passphrase protected?
passphrase = "" # Passphrase (if any) for decrypting the Private Key
# IP address to establish a SSH connection to.
# Equal to the current node's IP address if left blank.
# This field is only for information of the client who will create applications
# and this field's value will not affect GenSSH's functioning in any manner.
# To be used when the current node is only accessible by a jump host or
# behind some network forwarding rule or proxy setup.
entrypoint_ip = ""
###########################
# Jikan Configuration #
###########################
[services.jikan]
deploy = false # Deploy Jikan?
port = 3333
############################
# Github Configuration #
############################
[github]
username = "gasper-github-username"
email = "gasper-mail-id"
pat = "personal-access-token"