-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfig.js
74 lines (72 loc) · 2.1 KB
/
config.js
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
'use strict';
/* eslint no-process-env: 0 */
const env = process.env.NODE_ENV || 'production';
module.exports = {
dateLocales: 'en-GB',
dateFormat: {
day: '2-digit',
month: 'long',
year: 'numeric'
},
env: env,
govukNotify: {
notifyApiKey: process.env.NOTIFY_KEY,
caseworkerEmail: process.env.CASEWORKER_EMAIL,
userConfirmationTemplateId: process.env.USER_CONFIRMATION_TEMPLATE_ID,
businessConfirmationTemplateId: process.env.BUSINESS_CONFIRMATION_TEMPLATE_ID
},
feedbackUrl: process.env.FEEDBACK_URL,
hosts: {
acceptanceTests: process.env.ACCEPTANCE_HOST_NAME || `http://localhost:${process.env.PORT || 8080}`
},
redis: {
port: process.env.REDIS_PORT || '6379',
host: process.env.REDIS_HOST || '127.0.0.1'
},
sessionDefaults: {
steps: ['/overview', '/what-you-need', '/proof-of-identity', '/proof-of-address', '/update-details']
},
upload: {
maxFileSizeInBytes: 25 * 1024 * 1024, // 25MiB in bytes
hostname: process.env.FILE_VAULT_URL,
allowedMimeTypes: [
'application/pdf',
'image/jpeg',
'image/jpg',
'image/png'
],
documentCategories: {
'identity-documents': {
limit: 6,
limitValidationError: 'maxIdDocsUploads'
},
'home-address-documents': {
limit: 3,
limitValidationError: 'maxAddressDocsUploads'
},
'postal-address-documents': {
limit: 3,
limitValidationError: 'maxAddressDocsUploads'
},
'letter-of-authority': {
limit: 1,
limitValidationError: 'maxCertOfAuthorityUploads'
}
}
},
aws: {
bucket: process.env.AWS_BUCKET,
accessKeyId: process.env.AWS_ACCESS_KEY_ID,
secretAccessKey: process.env.AWS_SECRET_ACCESS_KEY,
signatureVersion: process.env.AWS_SIGNATURE_VERSION,
kmsKeyId: process.env.AWS_KMS_KEY_ID,
region: process.env.AWS_REGION
},
keycloak: {
token: process.env.KEYCLOAK_TOKEN_URL,
username: process.env.KEYCLOAK_USERNAME,
password: process.env.KEYCLOAK_PASSWORD,
clientId: process.env.KEYCLOAK_CLIENT_ID,
secret: process.env.KEYCLOAK_SECRET
}
};