5htp 0.3.5 → 0.3.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (102) hide show
  1. package/package.json +4 -3
  2. package/skeleton/docker-compose.yml +7 -15
  3. package/skeleton/identity.yaml +12 -8
  4. package/skeleton/package.json +25 -7
  5. package/skeleton/src/client/assets/identity/logo.svg +13 -63
  6. package/skeleton/src/client/assets/identity/logoAndText.svg +9 -104
  7. package/skeleton/src/client/assets/identity/logoAndTextBlack.svg +11 -0
  8. package/skeleton/src/client/assets/illustration/landing/banner.webp +0 -0
  9. package/skeleton/src/client/assets/illustration/landing/candidate/employers.webp +0 -0
  10. package/skeleton/src/client/assets/illustration/landing/candidate/hero.webp +0 -0
  11. package/skeleton/src/client/assets/illustration/landing/candidate/mentors.webp +0 -0
  12. package/skeleton/src/client/assets/illustration/landing/headhunter/hero.webp +0 -0
  13. package/skeleton/src/client/assets/illustration/landing/hero.jpeg +0 -0
  14. package/skeleton/src/client/assets/illustration/landing/hero.webp +0 -0
  15. package/skeleton/src/client/assets/illustration/landing/hero.xcf +0 -0
  16. package/skeleton/src/client/assets/illustration/landing/recruiter/onboarding.webp +0 -0
  17. package/skeleton/src/client/assets/illustration/landing/team/andre.png +0 -0
  18. package/skeleton/src/client/assets/illustration/landing/team/emma.png +0 -0
  19. package/skeleton/src/client/assets/illustration/landing/team/fei.png +0 -0
  20. package/skeleton/src/client/assets/illustration/landing/team/gaetan.png +0 -0
  21. package/skeleton/src/client/assets/illustration/landing/team/jordan.png +0 -0
  22. package/skeleton/src/client/assets/illustration/landing/team/lery.png +0 -0
  23. package/skeleton/src/client/assets/illustration/landing/team/mehdi.png +0 -0
  24. package/skeleton/src/client/assets/illustration/landing/team/omkar.png +0 -0
  25. package/skeleton/src/client/assets/illustration/landing/team/thibaut.png +0 -0
  26. package/skeleton/src/client/assets/img/background/header-blur.png +0 -0
  27. package/skeleton/src/client/assets/img/partners/citron.svg +987 -0
  28. package/skeleton/src/client/assets/patterns/dots.png +0 -0
  29. package/skeleton/src/client/assets/theme.less +179 -226
  30. package/skeleton/src/client/assets/vars.less +54 -0
  31. package/skeleton/src/client/context.ts +23 -0
  32. package/skeleton/src/client/index.ts +59 -0
  33. package/skeleton/src/client/pages/_messages/400.tsx +45 -0
  34. package/skeleton/src/client/pages/_messages/401.tsx +39 -0
  35. package/skeleton/src/client/pages/_messages/403.tsx +43 -0
  36. package/skeleton/src/client/pages/_messages/404.tsx +42 -0
  37. package/skeleton/src/client/pages/_messages/500.tsx +42 -0
  38. package/skeleton/src/client/pages/platform/Header.less +12 -0
  39. package/skeleton/src/client/pages/platform/Header.tsx +119 -0
  40. package/skeleton/src/client/pages/platform/_layout/index.less +118 -0
  41. package/skeleton/src/client/pages/platform/_layout/index.tsx +131 -0
  42. package/skeleton/src/client/pages/platform/_layout/mobile.less +114 -0
  43. package/skeleton/src/client/pages/platform/_page.tsx +54 -0
  44. package/skeleton/src/client/pages/platform/headhunters/index.tsx +88 -0
  45. package/skeleton/src/client/pages/platform/index.tsx +58 -0
  46. package/skeleton/src/client/pages/platform/missions/index.tsx +149 -0
  47. package/skeleton/src/client/services/metrics/index.ts +59 -0
  48. package/skeleton/src/client/tsconfig.json +4 -1
  49. package/skeleton/src/common/config/router.ts +16 -0
  50. package/skeleton/src/common/forms/company/bookCall.ts +25 -0
  51. package/skeleton/src/common/forms/company/importJob.ts +26 -0
  52. package/skeleton/src/common/forms/company/signup.ts +31 -0
  53. package/skeleton/src/common/forms/headhunter/feedback.ts +31 -0
  54. package/skeleton/src/common/forms/headhunter/mission/cancel.ts +26 -0
  55. package/skeleton/src/common/forms/headhunter/mission/candidate/availability.ts +31 -0
  56. package/skeleton/src/common/forms/headhunter/mission/candidate/education.ts +19 -0
  57. package/skeleton/src/common/forms/headhunter/mission/candidate/identity.ts +31 -0
  58. package/skeleton/src/common/forms/headhunter/mission/candidate/others.ts +19 -0
  59. package/skeleton/src/common/forms/headhunter/mission/candidate/skills.ts +21 -0
  60. package/skeleton/src/common/forms/headhunter/mission/reject.ts +23 -0
  61. package/skeleton/src/common/forms/headhunter/mission/search.ts +78 -0
  62. package/skeleton/src/common/forms/headhunter/signup.ts +34 -0
  63. package/skeleton/src/common/libs/headhunter/candidate/index.ts +155 -0
  64. package/skeleton/src/common/libs/headhunter/mission/index.ts +30 -0
  65. package/skeleton/src/common/libs/hub/index.ts +41 -0
  66. package/skeleton/src/server/config/communication.ts +48 -0
  67. package/skeleton/src/server/config/crosspath.ts +9 -0
  68. package/skeleton/src/server/config/data.ts +34 -0
  69. package/skeleton/src/server/config/database.ts +26 -0
  70. package/skeleton/src/server/config/internal.ts +21 -0
  71. package/skeleton/src/server/config/user.ts +90 -0
  72. package/skeleton/src/server/index.ts +111 -23
  73. package/skeleton/src/server/libs/utils/slug.ts +11 -0
  74. package/skeleton/src/server/routes/global.ts +33 -0
  75. package/skeleton/src/server/routes/headhunters.ts +24 -0
  76. package/skeleton/src/server/routes/missions.ts +50 -0
  77. package/skeleton/src/server/services/Headhunter/index.ts +127 -0
  78. package/skeleton/src/server/services/Headhunter/service.json +6 -0
  79. package/skeleton/src/server/services/Mission/index.ts +174 -0
  80. package/skeleton/src/server/services/Mission/service.json +6 -0
  81. package/skeleton/src/server/services/email/sendgrid/index.ts +97 -0
  82. package/skeleton/src/server/services/email/sendgrid/service.json +6 -0
  83. package/skeleton/src/server/services/slack/index.ts +105 -0
  84. package/skeleton/src/server/services/slack/service.json +6 -0
  85. package/skeleton/src/server/services/users/index.ts +133 -0
  86. package/skeleton/src/server/services/users/service.json +6 -0
  87. package/skeleton/src/server/tsconfig.json +6 -8
  88. package/skeleton/var/typings/routes.d.ts +541 -0
  89. package/src/compiler/common/babel/index.ts +28 -25
  90. package/src/index.ts +1 -1
  91. package/src/utils/keyboard.ts +1 -1
  92. package/skeleton/package-lock.json +0 -6139
  93. package/skeleton/src/client/components/LoginModal.tsx +0 -45
  94. package/skeleton/src/client/pages/app/_layout/index.less +0 -20
  95. package/skeleton/src/client/pages/app/_layout/index.tsx +0 -33
  96. package/skeleton/src/client/pages/app/index.tsx +0 -57
  97. package/skeleton/src/client/pages/landing/_layout/index.less +0 -145
  98. package/skeleton/src/client/pages/landing/_layout/index.tsx +0 -63
  99. package/skeleton/src/client/pages/landing/index.tsx +0 -73
  100. package/skeleton/src/server/models.ts +0 -117
  101. package/skeleton/src/server/routes/general.ts +0 -66
  102. package/skeleton/src/server/services/auth/index.ts +0 -80
@@ -0,0 +1,78 @@
1
+ /*----------------------------------
2
+ - DEPENDANCES
3
+ ----------------------------------*/
4
+
5
+ // Core
6
+ import { Schema, Validators } from '@common/validation';
7
+
8
+ // TODO: impoer each validator independently via spread
9
+ const field = new Validators();
10
+
11
+ /*----------------------------------
12
+ - SCHEMA
13
+ ----------------------------------*/
14
+ export default new Schema({
15
+
16
+ jobType: field.choice([{
17
+ label: 'Full Time',
18
+ value: 'fullTime'
19
+ },{
20
+ label: 'Freelance',
21
+ value: 'freelance'
22
+ }], { opt: true }),
23
+
24
+ status: field.choice([{
25
+ label: 'Active',
26
+ value: 'Active'
27
+ },{
28
+ label: 'Paused',
29
+ value: 'Paused'
30
+ },{
31
+ label: 'Closed',
32
+ value: 'Closed'
33
+ }], { opt: true, multiple: true }),
34
+
35
+ sectors: field.choice(undefined, {
36
+ multiple: true,
37
+ opt: true
38
+ }),
39
+
40
+ positions: field.choice(undefined, {
41
+ multiple: true,
42
+ opt: true
43
+ }),
44
+
45
+ skills: field.choice(undefined, {
46
+ multiple: true,
47
+ opt: true
48
+ }),
49
+
50
+ languages: field.choice(undefined, {
51
+ multiple: true,
52
+ opt: true
53
+ }),
54
+
55
+ locations: field.choice(undefined, {
56
+ multiple: true,
57
+ opt: true
58
+ }),
59
+
60
+ companySizes: field.choice(undefined, {
61
+ multiple: true,
62
+ opt: true
63
+ }),
64
+
65
+ seniority: field.choice(undefined, {
66
+ multiple: true,
67
+ opt: true
68
+ }),
69
+
70
+ sort: field.choice([{
71
+ label: 'Date Posted',
72
+ value: 'Date Posted'
73
+ },{
74
+ label: 'Relevency',
75
+ value: 'Relevency'
76
+ }], { opt: true }),
77
+
78
+ });
@@ -0,0 +1,34 @@
1
+ /*----------------------------------
2
+ - DEPENDANCES
3
+ ----------------------------------*/
4
+
5
+ // Core
6
+ import { Schema, Validators } from '@common/validation';
7
+
8
+ // TODO: impoer each validator independently via spread
9
+ const field = new Validators();
10
+
11
+ /*----------------------------------
12
+ - SCHEMA
13
+ ----------------------------------*/
14
+ export default new Schema({
15
+
16
+ firstName: field.string(),
17
+
18
+ lastName: field.string(),
19
+
20
+ email: field.email(),
21
+
22
+ linkedInUrl: field.url(),
23
+
24
+ phone: field.string(),
25
+
26
+ password: field.string({ min: 10 }),
27
+
28
+ // Tracking
29
+
30
+ referrerId: field.string({ opt: true }),
31
+ utm_medium: field.string({ opt: true }),
32
+ utm_source: field.string({ opt: true }),
33
+
34
+ });
@@ -0,0 +1,155 @@
1
+
2
+ export const statuses: {
3
+ [statusName: string]: {
4
+ progress: number,
5
+ color: string,
6
+ hint: string,
7
+ failed?: boolean
8
+ }
9
+ } = {
10
+
11
+ // STEP 1
12
+ 'Sourced': {
13
+ progress: 10,
14
+ color: '#afe9b5',
15
+ hint: "The candidate you submitted is waiting to be verified by the client."
16
+ },
17
+ 'Being Screened': {
18
+ progress: 20,
19
+ color: '#afe9b5',
20
+ hint: "The candidate you submitted is waiting to be verified by the client."
21
+ },
22
+ 'Rejected by CP': {
23
+ progress: 20,
24
+ color: '#df6232',
25
+ hint: "The candidate has been rejected by the client.",
26
+ failed: true
27
+ },
28
+ 'Sent to Client': {
29
+ progress: 30,
30
+ color: '#afe9b5',
31
+ hint: "We sent the candidate to the client, and we're waiting for his feedbacks."
32
+ },
33
+
34
+ // STEP 2
35
+ 'Candidate Not Reachable': {
36
+ progress: 40,
37
+ color: '#b10f41',
38
+ hint: "We contacted the candidate, and he said not being interested by the offer.",
39
+ failed: true
40
+ },
41
+ 'Candidate not interested': {
42
+ progress: 40,
43
+ color: '#b10f41',
44
+ hint: "We contacted the candidate, and he said not being interested by the offer.",
45
+ failed: true
46
+ },
47
+ 'Already In Client Pipeline': {
48
+ progress: 40,
49
+ color: '#df6232',
50
+ hint: "The candidate has already been interviewed by the client.",
51
+ failed: true
52
+ },
53
+ 'Waiting list': {
54
+ progress: 40,
55
+ color: '#fbc541',
56
+ hint: "The client is okay to onboard the candidate, but he prefer to wait if we find a better profile.",
57
+ },
58
+
59
+ // STEP 3: Interview
60
+ 'Interview Process - 1st Round': {
61
+ progress: 50,
62
+ color: '#fbc541',
63
+ hint: "The candidate is currently being interviewed by the client."
64
+ },
65
+ 'Interview Process - 2nd Round': {
66
+ progress: 50,
67
+ color: '#fbc541',
68
+ hint: "The candidate is currently being interviewed by the client."
69
+ },
70
+ 'Interview Process - 3rd Round': {
71
+ progress: 50,
72
+ color: '#fbc541',
73
+ hint: "The candidate is currently being interviewed by the client."
74
+ },
75
+ 'Interview Process - 4th Round': {
76
+ progress: 50,
77
+ color: '#fbc541',
78
+ hint: "The candidate is currently being interviewed by the client."
79
+ },
80
+ 'Interview Process - 5th Round': {
81
+ progress: 50,
82
+ color: '#fbc541',
83
+ hint: "The candidate is currently being interviewed by the client."
84
+ },
85
+
86
+ // STEP 4: Feedback from Interview
87
+ 'Rejected by client': {
88
+ progress: 60,
89
+ color: '#b10f41',
90
+ hint: "The candidate has been rejected by the client.",
91
+ failed: true
92
+ },
93
+ 'Mission closed by client': {
94
+ progress: 60,
95
+ color: '#b10f41',
96
+ hint: '',
97
+ failed: true
98
+ },
99
+ 'Offer sent': {
100
+ progress: 70,
101
+ color: '#fbc541',
102
+ hint: "The client accepted the candidate and just sent an offer to him. We're waiting for an answer from the candidate.",
103
+ },
104
+ 'Signed': {
105
+ progress: 80,
106
+ color: '#b10f41',
107
+ hint: ''
108
+ },
109
+ 'Trial Not Passed': {
110
+ progress: 90,
111
+ color: '#b10f41',
112
+ hint: '',
113
+ failed: true
114
+ },
115
+ 'Trial Passed': {
116
+ progress: 100,
117
+ color: '#006400',
118
+ hint: ''
119
+ },
120
+
121
+ // Deprecated
122
+ 'To Be Screened by CV Validator': {
123
+ progress: 10,
124
+ color: '#afe9b5',
125
+ hint: "The candidate you submitted is waiting to be verified by the client."
126
+ },
127
+ 'Screened by CP': {
128
+ progress: 20,
129
+ color: '#afe9b5',
130
+ hint: "The candidate has just been double-checked by our internal team, and is about to be sent to the client."
131
+ },
132
+ 'Interview Process': {
133
+ progress: 40,
134
+ color: '#fbc541',
135
+ hint: "The candidate is currently being interviewed by the client."
136
+ },
137
+ 'Rejected by client 2nd round': {
138
+ progress: 60,
139
+ color: '#b10f41',
140
+ hint: "The candidate has been rejected by the client after the 2nd round of interview.",
141
+ failed: true
142
+ },
143
+ 'Rejected by client 3rd round': {
144
+ progress: 65,
145
+ color: '#b10f41',
146
+ hint: "The candidate has been rejected by the client after the 2nd round of interview.",
147
+ failed: true
148
+ },
149
+ 'Rejected by client 4th round': {
150
+ progress: 70,
151
+ color: '#b10f41',
152
+ hint: "The candidate has been rejected by the client after the 2nd round of interview.",
153
+ failed: true
154
+ },
155
+ }
@@ -0,0 +1,30 @@
1
+ import abr from 'number-abbreviate';
2
+
3
+ const range = ( min?: number, max?: number, unit?: string ) => {
4
+ unit = unit || '';
5
+ if (min === undefined && max === undefined)
6
+ return 'Not precised';
7
+ else if (min === max)
8
+ return abr(max) as number + ' ' + ' ' + unit;
9
+ else if (min !== undefined && max !== undefined)
10
+ return abr(min) + ' - ' + abr(max) + ' ' + unit;
11
+ else if (min !== undefined)
12
+ return 'Starting from ' + abr(min) + ' ' + unit;
13
+ else if (max !== undefined)
14
+ return 'Up to ' + abr(max) + ' ' + unit;
15
+ }
16
+
17
+ export const rejectionReasons = [
18
+ "No time",
19
+ "Not my specialty",
20
+ "I don't want to work for this client",
21
+ "It's already my client",
22
+ "Fee not interesting enough",
23
+ "I don't have candidates for this position for the moment",
24
+ "Other",
25
+ ].map(v => ({
26
+ label: v,
27
+ value: v
28
+ }))
29
+
30
+ export default { range }
@@ -0,0 +1,41 @@
1
+
2
+ // ! Pleaseensure those values are always sync with the one in database enums / set
3
+ export const Genders = [{
4
+ label: 'Male',
5
+ value: 'Male',
6
+ }, {
7
+ label: 'Female',
8
+ value: 'Female',
9
+ }, {
10
+ label: 'Non-Binary',
11
+ value: 'Non-Binary',
12
+ }, {
13
+ label: 'Transgender',
14
+ value: 'Transgender',
15
+ }, {
16
+ label: 'Other',
17
+ value: 'Other',
18
+ }]
19
+
20
+ export const Currencies = [{
21
+ label: 'Dollar (USD)',
22
+ value: '$'
23
+ }, {
24
+
25
+ label: 'Euro (EUR)',
26
+ value: '€'
27
+ }, {
28
+ label: 'Pounds (GBP)',
29
+ value: '£'
30
+ }]
31
+
32
+ export const MobilityModes = [{
33
+ label: 'On-site',
34
+ value: 'On-site',
35
+ },{
36
+ label: 'Hybrid',
37
+ value: 'Hybrid',
38
+ },{
39
+ label: 'Full Remote',
40
+ value: 'Full Remote',
41
+ }]
@@ -0,0 +1,48 @@
1
+ import { Environment, Services } from '@app';
2
+
3
+ Services.setup('Core/Email', {
4
+ debug: false,
5
+ simulateWhenLocal: true,
6
+ default: {
7
+ transporter: 'sendgrid',
8
+ from: {
9
+ // Users should have the ability to answers to emails
10
+ name: 'Gaëtan from CrossPath',
11
+ email: 'gaetan@becrosspath.com'
12
+ },
13
+ },
14
+ bugReport: {
15
+ from: {
16
+ name: 'CrossPath Robot',
17
+ email: 'system@becrosspath.com'
18
+ },
19
+ to: {
20
+ name: 'CrossPath Engineering Team',
21
+ email: 'engineering@becrosspath.com'
22
+ }
23
+ }
24
+ });
25
+
26
+ Services.setup('CrossPath/Email/Sendgrid', {
27
+ api: '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'
28
+ });
29
+
30
+ Services.setup('CrossPath/Slack', {
31
+ token: 'xoxb-4679987012741-4734346927492-M7VSHqd8uHg4KYHlEByaIRLL',
32
+ channels: {
33
+ 'default': 'C04L5C6LLBW',
34
+ 'engineering-alerts': 'C04L5C6LLBW',
35
+ 'product': 'C04L2TGR5J6',
36
+ 'headhunters': 'C04L2TNC6F4',
37
+ 'customer-success': Environment.name === 'local'
38
+ ? 'C04L5C6LLBW'// Engineering alerts
39
+ : 'C04L2TNC6F4',
40
+ 'sales': Environment.name === 'local'
41
+ ? 'C04L5C6LLBW' // Engineering alerts
42
+ : 'C04L2TVJ0LS'
43
+ }
44
+ });
45
+
46
+ Services.setup('Core/Fetch', {
47
+ disk: 'default'
48
+ })
@@ -0,0 +1,9 @@
1
+ import { Services } from '@app';
2
+
3
+ Services.setup('CrossPath/Mission', {
4
+
5
+ });
6
+
7
+ Services.setup('CrossPath/Headhunter', {
8
+
9
+ });
@@ -0,0 +1,34 @@
1
+ import { Services, Environment } from '@app';
2
+
3
+ Services.setup('Core/Disks', {
4
+ debug: true,
5
+ default: Environment.name === 'local'
6
+ ? 'local'
7
+ : 's3'
8
+ })
9
+
10
+ Services.setup('Core/Disks/S3', {
11
+ debug: true,
12
+
13
+ accessKeyId: 'AKIAXEP3ITBHFW6BF2WM',
14
+ secretAccessKey: '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',
15
+ region: 'eu-west-2',
16
+
17
+ rootDir: '.',
18
+ buckets: {
19
+ data: 'crosspath-platform'
20
+ },
21
+ });
22
+
23
+ Services.setup('Core/Disks/Local', {
24
+ debug: true,
25
+ rootDir: '.',
26
+ buckets: {
27
+ data: 'data'
28
+ }
29
+ });
30
+
31
+ /*Services.setup('Core/Cache', {
32
+ debug: true,
33
+ disk: 'default'
34
+ })*/
@@ -0,0 +1,26 @@
1
+ import { Environment, Services } from '@app';
2
+
3
+ Services.setup('Core/Database/SQL', {
4
+ debug: true,
5
+
6
+ // MySQL server should be configured to 3x connectionLimit
7
+ // (1 production server + 1 deployment testing + TablePlus)
8
+ connectionsLimit: 30,
9
+ connections: Environment.profile === 'dev'
10
+ ? [{
11
+ name: 'local',
12
+ databases: ['crosspath'],
13
+ host: '127.0.0.1',
14
+ port: 3306,
15
+ login: 'gaetan',
16
+ password: "$mdp=MySQL!159753",
17
+ }]
18
+ : [{
19
+ name: 'aws',
20
+ databases: ['crosspath'],
21
+ host: 'crosspathdb.czmbpbfhocbe.eu-west-2.rds.amazonaws.com',
22
+ port: 8888,
23
+ login: 'admin', // TODO: create limited user on AWS
24
+ password: "oyx82StLt2qKfF",
25
+ }]
26
+ })
@@ -0,0 +1,21 @@
1
+ import { Services } from '@app';
2
+
3
+ Services.setup('Core/Console', {
4
+ debug: false,
5
+ bufferLimit: 10000,
6
+ dev: {
7
+ level: 'log'
8
+ },
9
+ prod: {
10
+ level: 'log'
11
+ }
12
+ })
13
+
14
+ Services.setup('Core/Cron', {});
15
+
16
+ Services.setup('Core/Encryption/AES', {
17
+ iv: '2smIsdJTIZX56htS',
18
+ keys: {
19
+ activationToken: 's5v8y/B?D(G+KbPeShVmYq3t6w9z$C&F'
20
+ }
21
+ });
@@ -0,0 +1,90 @@
1
+ import { Services, Environment } from '@app';
2
+
3
+ import { domains } from '@/common/config/router';
4
+
5
+ Services.setup('CrossPath/Users', {
6
+
7
+ debug: true,
8
+ logoutUrl: '/',
9
+
10
+ jwt: {
11
+ // 2048 bits
12
+ key: "A?D(G+KbPeShVmYq3t6w9y$B&E)H@McQfTjWnZr4u7x!A%C*F-JaNdRgUkXp2s5v8y/B?E(G+KbPeShVmYq3t6w9z$C&F)J@McQfTjWnZr4u7x!A%D*G-KaPdRgUkXp2s5v8y/B?E(H+MbQeThVmYq3t6w9z$C&F)J@NcRfUjXnZr4u7x!A%D*G-KaPdSgVkYp3s5v8y/B?E(H+MbQeThWmZq4t7w9z$C&F)J@NcRfUjXn2r5u8x/A%D*G-KaPdS",
13
+ expiration: "7 days",
14
+ }
15
+ })
16
+
17
+ Services.setup('Core/Router', {
18
+
19
+ debug: false,
20
+
21
+ disk: 'default',
22
+
23
+ domains: Environment.name === 'local' ? {
24
+ ...domains.local,
25
+ current: domains.local.csm,
26
+ } : {
27
+ ...domains.prod,
28
+ current: domains.prod.csm,
29
+ },
30
+
31
+ http: {
32
+ // Access
33
+ domain: 'csm.becrosspath.com',
34
+ port: 3014,
35
+ ssl: true,
36
+
37
+ // Limitations
38
+ upload: {
39
+ maxSize: '10mb'
40
+ },
41
+ csp: {
42
+ scripts: [
43
+ // Whitelist external js scripts
44
+ "https://www.googletagmanager.com/gtag/js",
45
+ "https://cdn.jsdelivr.net",
46
+ "https://static.hotjar.com",
47
+ "https://script.hotjar.com",
48
+ "https://js.stripe.com/v3/pricing-table.js",
49
+ "https://snap.licdn.com",
50
+ ]
51
+ },
52
+ cors: {
53
+ origin: [
54
+ // Landing Page
55
+ 'http://localhost:3011',
56
+ 'https://becrosspath.com',
57
+ 'https://www.becrosspath.com',
58
+ ]
59
+ }
60
+ },
61
+
62
+ // Protections against bots
63
+ // TODO: distinct service
64
+ /*security: {
65
+ // https://www.google.com/recaptcha/admin/site/346699952
66
+ recaptcha: {
67
+ pub: '6LewOKoUAAAAAKmaDqpcNaQz31z_AJarSs0sQvft',
68
+ prv: '6LewOKoUAAAAAOAj80m9vOJuP9YcR7PnYQ3E-y4o'
69
+ },
70
+ iphub: "Mzk3MzpLWE84eHhXQ0ZvUlNQODh0M3J0OXpDTGE2WGx5Szl6OA=="
71
+ },*/
72
+
73
+ // WARN: The data returned by this function should be safe to be epxosed to the frontend
74
+ // TODO: remove and replace by
75
+ context: (request, app) => ({
76
+
77
+ user: app.Users.forSSR(request)
78
+
79
+ })
80
+ });
81
+
82
+ Services.setup('Core/Users/Router', {});
83
+
84
+ Services.setup('Core/Schema/Router', {
85
+ debug: false
86
+ });
87
+
88
+ Services.setup('Core/Socket', {
89
+ port: 3011,
90
+ });