underpost 3.1.3 → 3.2.2
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.
- package/.env.example +0 -2
- package/.github/workflows/ghpkg.ci.yml +4 -4
- package/.github/workflows/npmpkg.ci.yml +28 -11
- package/.github/workflows/publish.ci.yml +6 -0
- package/.github/workflows/pwa-microservices-template-page.cd.yml +4 -5
- package/.github/workflows/pwa-microservices-template-test.ci.yml +3 -3
- package/.github/workflows/release.cd.yml +13 -8
- package/CHANGELOG.md +396 -1
- package/CLI-HELP.md +53 -6
- package/Dockerfile +4 -2
- package/README.md +3 -2
- package/bin/build.js +18 -12
- package/bin/deploy.js +177 -124
- package/bin/file.js +3 -0
- package/conf.js +3 -2
- package/manifests/cronjobs/dd-cron/dd-cron-backup.yaml +5 -2
- package/manifests/cronjobs/dd-cron/dd-cron-dns.yaml +5 -2
- package/manifests/deployment/dd-default-development/deployment.yaml +2 -2
- package/manifests/deployment/dd-test-development/deployment.yaml +88 -74
- package/manifests/deployment/dd-test-development/proxy.yaml +13 -4
- package/manifests/deployment/playwright/deployment.yaml +1 -1
- package/nodemon.json +1 -1
- package/package.json +22 -15
- package/scripts/rhel-grpc-setup.sh +56 -0
- package/src/api/file/file.ref.json +18 -0
- package/src/api/user/user.service.js +8 -7
- package/src/cli/cluster.js +7 -7
- package/src/cli/db.js +726 -825
- package/src/cli/deploy.js +151 -93
- package/src/cli/env.js +19 -0
- package/src/cli/fs.js +5 -2
- package/src/cli/index.js +45 -2
- package/src/cli/kubectl.js +211 -0
- package/src/cli/release.js +284 -0
- package/src/cli/repository.js +434 -75
- package/src/cli/run.js +189 -34
- package/src/cli/secrets.js +73 -0
- package/src/cli/test.js +3 -3
- package/src/client/Default.index.js +3 -4
- package/src/client/components/core/AppStore.js +69 -0
- package/src/client/components/core/CalendarCore.js +2 -2
- package/src/client/components/core/DropDown.js +137 -17
- package/src/client/components/core/Keyboard.js +2 -2
- package/src/client/components/core/LogIn.js +2 -2
- package/src/client/components/core/LogOut.js +2 -2
- package/src/client/components/core/Modal.js +0 -1
- package/src/client/components/core/Panel.js +0 -1
- package/src/client/components/core/PanelForm.js +19 -19
- package/src/client/components/core/SocketIo.js +82 -29
- package/src/client/components/core/SocketIoHandler.js +75 -0
- package/src/client/components/core/Stream.js +143 -95
- package/src/client/components/core/Webhook.js +40 -7
- package/src/client/components/default/AppStoreDefault.js +5 -0
- package/src/client/components/default/LogInDefault.js +3 -3
- package/src/client/components/default/LogOutDefault.js +2 -2
- package/src/client/components/default/MenuDefault.js +5 -5
- package/src/client/components/default/SocketIoDefault.js +3 -51
- package/src/client/services/core/core.service.js +20 -8
- package/src/client/services/user/user.management.js +2 -2
- package/src/index.js +24 -1
- package/src/runtime/express/Dockerfile +4 -0
- package/src/runtime/express/Express.js +18 -1
- package/src/runtime/lampp/Dockerfile +13 -2
- package/src/runtime/lampp/Lampp.js +27 -4
- package/src/runtime/wp/Dockerfile +68 -0
- package/src/runtime/wp/Wp.js +639 -0
- package/src/server/auth.js +24 -1
- package/src/server/backup.js +57 -23
- package/src/server/client-build-docs.js +9 -2
- package/src/server/client-build.js +31 -31
- package/src/server/client-formatted.js +109 -57
- package/src/server/cron.js +23 -18
- package/src/server/ipfs-client.js +24 -1
- package/src/server/peer.js +8 -0
- package/src/server/runtime.js +25 -1
- package/src/server/start.js +3 -2
- package/src/ws/IoInterface.js +1 -10
- package/src/ws/IoServer.js +14 -33
- package/src/ws/core/channels/core.ws.chat.js +65 -20
- package/src/ws/core/channels/core.ws.mailer.js +113 -32
- package/src/ws/core/channels/core.ws.stream.js +90 -31
- package/src/ws/core/core.ws.connection.js +12 -33
- package/src/ws/core/core.ws.emit.js +10 -26
- package/src/ws/core/core.ws.server.js +25 -58
- package/src/ws/default/channels/default.ws.main.js +53 -12
- package/src/ws/default/default.ws.connection.js +26 -13
- package/src/ws/default/default.ws.server.js +30 -12
- package/src/client/components/default/ElementsDefault.js +0 -38
- package/src/ws/core/management/core.ws.chat.js +0 -8
- package/src/ws/core/management/core.ws.mailer.js +0 -16
- package/src/ws/core/management/core.ws.stream.js +0 -8
- package/src/ws/default/management/default.ws.main.js +0 -8
|
@@ -23,12 +23,15 @@ spec:
|
|
|
23
23
|
spec:
|
|
24
24
|
containers:
|
|
25
25
|
- name: dd-cron-backup
|
|
26
|
-
image: underpost/underpost-engine:v3.
|
|
26
|
+
image: underpost/underpost-engine:v3.2.2
|
|
27
27
|
command:
|
|
28
28
|
- /bin/sh
|
|
29
29
|
- -c
|
|
30
30
|
- >
|
|
31
|
-
|
|
31
|
+
cd /home/dd/engine &&
|
|
32
|
+
node bin run secret &&
|
|
33
|
+
node bin env dd-cron production &&
|
|
34
|
+
node bin cron --git --dev --kubeadm dd-lampp,dd-cyberia,dd-core,dd-test backup
|
|
32
35
|
volumeMounts:
|
|
33
36
|
- mountPath: /home/dd/engine
|
|
34
37
|
name: underpost-cron-container-volume
|
|
@@ -23,12 +23,15 @@ spec:
|
|
|
23
23
|
spec:
|
|
24
24
|
containers:
|
|
25
25
|
- name: dd-cron-dns
|
|
26
|
-
image: underpost/underpost-engine:v3.
|
|
26
|
+
image: underpost/underpost-engine:v3.2.2
|
|
27
27
|
command:
|
|
28
28
|
- /bin/sh
|
|
29
29
|
- -c
|
|
30
30
|
- >
|
|
31
|
-
|
|
31
|
+
cd /home/dd/engine &&
|
|
32
|
+
node bin run secret &&
|
|
33
|
+
node bin env dd-cron production &&
|
|
34
|
+
node bin cron --git --dev --kubeadm dd-cron dns
|
|
32
35
|
volumeMounts:
|
|
33
36
|
- mountPath: /home/dd/engine
|
|
34
37
|
name: underpost-cron-container-volume
|
|
@@ -17,7 +17,7 @@ spec:
|
|
|
17
17
|
spec:
|
|
18
18
|
containers:
|
|
19
19
|
- name: dd-default-development-blue
|
|
20
|
-
image: localhost/rockylinux9-underpost:v3.
|
|
20
|
+
image: localhost/rockylinux9-underpost:v3.2.2
|
|
21
21
|
# resources:
|
|
22
22
|
# requests:
|
|
23
23
|
# memory: "124Ki"
|
|
@@ -100,7 +100,7 @@ spec:
|
|
|
100
100
|
spec:
|
|
101
101
|
containers:
|
|
102
102
|
- name: dd-default-development-green
|
|
103
|
-
image: localhost/rockylinux9-underpost:v3.
|
|
103
|
+
image: localhost/rockylinux9-underpost:v3.2.2
|
|
104
104
|
# resources:
|
|
105
105
|
# requests:
|
|
106
106
|
# memory: "124Ki"
|
|
@@ -6,6 +6,7 @@ metadata:
|
|
|
6
6
|
namespace: default
|
|
7
7
|
labels:
|
|
8
8
|
app: dd-test-development-blue
|
|
9
|
+
deploy-id: dd-test-development
|
|
9
10
|
spec:
|
|
10
11
|
replicas: 1
|
|
11
12
|
selector:
|
|
@@ -15,28 +16,25 @@ spec:
|
|
|
15
16
|
metadata:
|
|
16
17
|
labels:
|
|
17
18
|
app: dd-test-development-blue
|
|
19
|
+
deploy-id: dd-test-development
|
|
18
20
|
spec:
|
|
19
21
|
containers:
|
|
20
22
|
- name: dd-test-development-blue
|
|
21
|
-
image: localhost/rockylinux9-underpost:v3.
|
|
23
|
+
image: localhost/rockylinux9-underpost:v3.2.2
|
|
24
|
+
envFrom:
|
|
25
|
+
- secretRef:
|
|
26
|
+
name: underpost-config
|
|
22
27
|
|
|
23
28
|
command:
|
|
24
29
|
- /bin/sh
|
|
25
30
|
- -c
|
|
26
31
|
- >
|
|
27
|
-
npm install -g npm@11.2.0 &&
|
|
32
|
+
npm install -g npm@11.2.0 &&
|
|
33
|
+
npm install -g underpost &&
|
|
34
|
+
underpost secret underpost --create-from-env &&
|
|
35
|
+
underpost start --build --run dd-test development
|
|
36
|
+
|
|
28
37
|
|
|
29
|
-
|
|
30
|
-
volumeMounts:
|
|
31
|
-
- name: config-volume-dd-test-development-blue
|
|
32
|
-
mountPath: /etc/config
|
|
33
|
-
|
|
34
|
-
volumes:
|
|
35
|
-
- name: config-volume-dd-test-development-blue
|
|
36
|
-
configMap:
|
|
37
|
-
name: underpost-config
|
|
38
|
-
|
|
39
|
-
|
|
40
38
|
---
|
|
41
39
|
apiVersion: v1
|
|
42
40
|
kind: Service
|
|
@@ -47,41 +45,50 @@ spec:
|
|
|
47
45
|
selector:
|
|
48
46
|
app: dd-test-development-blue
|
|
49
47
|
ports:
|
|
50
|
-
- name: 'tcp-
|
|
48
|
+
- name: 'tcp-4046'
|
|
49
|
+
protocol: TCP
|
|
50
|
+
port: 4046
|
|
51
|
+
targetPort: 4046
|
|
52
|
+
- name: 'udp-4046'
|
|
53
|
+
protocol: UDP
|
|
54
|
+
port: 4046
|
|
55
|
+
targetPort: 4046
|
|
56
|
+
|
|
57
|
+
- name: 'tcp-4047'
|
|
51
58
|
protocol: TCP
|
|
52
|
-
port:
|
|
53
|
-
targetPort:
|
|
54
|
-
- name: 'udp-
|
|
59
|
+
port: 4047
|
|
60
|
+
targetPort: 4047
|
|
61
|
+
- name: 'udp-4047'
|
|
55
62
|
protocol: UDP
|
|
56
|
-
port:
|
|
57
|
-
targetPort:
|
|
63
|
+
port: 4047
|
|
64
|
+
targetPort: 4047
|
|
58
65
|
|
|
59
|
-
- name: 'tcp-
|
|
66
|
+
- name: 'tcp-4048'
|
|
60
67
|
protocol: TCP
|
|
61
|
-
port:
|
|
62
|
-
targetPort:
|
|
63
|
-
- name: 'udp-
|
|
68
|
+
port: 4048
|
|
69
|
+
targetPort: 4048
|
|
70
|
+
- name: 'udp-4048'
|
|
64
71
|
protocol: UDP
|
|
65
|
-
port:
|
|
66
|
-
targetPort:
|
|
72
|
+
port: 4048
|
|
73
|
+
targetPort: 4048
|
|
67
74
|
|
|
68
|
-
- name: 'tcp-
|
|
75
|
+
- name: 'tcp-4049'
|
|
69
76
|
protocol: TCP
|
|
70
|
-
port:
|
|
71
|
-
targetPort:
|
|
72
|
-
- name: 'udp-
|
|
77
|
+
port: 4049
|
|
78
|
+
targetPort: 4049
|
|
79
|
+
- name: 'udp-4049'
|
|
73
80
|
protocol: UDP
|
|
74
|
-
port:
|
|
75
|
-
targetPort:
|
|
81
|
+
port: 4049
|
|
82
|
+
targetPort: 4049
|
|
76
83
|
|
|
77
|
-
- name: 'tcp-
|
|
84
|
+
- name: 'tcp-4050'
|
|
78
85
|
protocol: TCP
|
|
79
|
-
port:
|
|
80
|
-
targetPort:
|
|
81
|
-
- name: 'udp-
|
|
86
|
+
port: 4050
|
|
87
|
+
targetPort: 4050
|
|
88
|
+
- name: 'udp-4050'
|
|
82
89
|
protocol: UDP
|
|
83
|
-
port:
|
|
84
|
-
targetPort:
|
|
90
|
+
port: 4050
|
|
91
|
+
targetPort: 4050
|
|
85
92
|
type: LoadBalancer
|
|
86
93
|
---
|
|
87
94
|
apiVersion: apps/v1
|
|
@@ -91,6 +98,7 @@ metadata:
|
|
|
91
98
|
namespace: default
|
|
92
99
|
labels:
|
|
93
100
|
app: dd-test-development-green
|
|
101
|
+
deploy-id: dd-test-development
|
|
94
102
|
spec:
|
|
95
103
|
replicas: 1
|
|
96
104
|
selector:
|
|
@@ -100,28 +108,25 @@ spec:
|
|
|
100
108
|
metadata:
|
|
101
109
|
labels:
|
|
102
110
|
app: dd-test-development-green
|
|
111
|
+
deploy-id: dd-test-development
|
|
103
112
|
spec:
|
|
104
113
|
containers:
|
|
105
114
|
- name: dd-test-development-green
|
|
106
|
-
image: localhost/rockylinux9-underpost:v3.
|
|
115
|
+
image: localhost/rockylinux9-underpost:v3.2.2
|
|
116
|
+
envFrom:
|
|
117
|
+
- secretRef:
|
|
118
|
+
name: underpost-config
|
|
107
119
|
|
|
108
120
|
command:
|
|
109
121
|
- /bin/sh
|
|
110
122
|
- -c
|
|
111
123
|
- >
|
|
112
|
-
npm install -g npm@11.2.0 &&
|
|
124
|
+
npm install -g npm@11.2.0 &&
|
|
125
|
+
npm install -g underpost &&
|
|
126
|
+
underpost secret underpost --create-from-env &&
|
|
127
|
+
underpost start --build --run dd-test development
|
|
128
|
+
|
|
113
129
|
|
|
114
|
-
|
|
115
|
-
volumeMounts:
|
|
116
|
-
- name: config-volume-dd-test-development-green
|
|
117
|
-
mountPath: /etc/config
|
|
118
|
-
|
|
119
|
-
volumes:
|
|
120
|
-
- name: config-volume-dd-test-development-green
|
|
121
|
-
configMap:
|
|
122
|
-
name: underpost-config
|
|
123
|
-
|
|
124
|
-
|
|
125
130
|
---
|
|
126
131
|
apiVersion: v1
|
|
127
132
|
kind: Service
|
|
@@ -132,39 +137,48 @@ spec:
|
|
|
132
137
|
selector:
|
|
133
138
|
app: dd-test-development-green
|
|
134
139
|
ports:
|
|
135
|
-
- name: 'tcp-
|
|
140
|
+
- name: 'tcp-4046'
|
|
141
|
+
protocol: TCP
|
|
142
|
+
port: 4046
|
|
143
|
+
targetPort: 4046
|
|
144
|
+
- name: 'udp-4046'
|
|
145
|
+
protocol: UDP
|
|
146
|
+
port: 4046
|
|
147
|
+
targetPort: 4046
|
|
148
|
+
|
|
149
|
+
- name: 'tcp-4047'
|
|
136
150
|
protocol: TCP
|
|
137
|
-
port:
|
|
138
|
-
targetPort:
|
|
139
|
-
- name: 'udp-
|
|
151
|
+
port: 4047
|
|
152
|
+
targetPort: 4047
|
|
153
|
+
- name: 'udp-4047'
|
|
140
154
|
protocol: UDP
|
|
141
|
-
port:
|
|
142
|
-
targetPort:
|
|
155
|
+
port: 4047
|
|
156
|
+
targetPort: 4047
|
|
143
157
|
|
|
144
|
-
- name: 'tcp-
|
|
158
|
+
- name: 'tcp-4048'
|
|
145
159
|
protocol: TCP
|
|
146
|
-
port:
|
|
147
|
-
targetPort:
|
|
148
|
-
- name: 'udp-
|
|
160
|
+
port: 4048
|
|
161
|
+
targetPort: 4048
|
|
162
|
+
- name: 'udp-4048'
|
|
149
163
|
protocol: UDP
|
|
150
|
-
port:
|
|
151
|
-
targetPort:
|
|
164
|
+
port: 4048
|
|
165
|
+
targetPort: 4048
|
|
152
166
|
|
|
153
|
-
- name: 'tcp-
|
|
167
|
+
- name: 'tcp-4049'
|
|
154
168
|
protocol: TCP
|
|
155
|
-
port:
|
|
156
|
-
targetPort:
|
|
157
|
-
- name: 'udp-
|
|
169
|
+
port: 4049
|
|
170
|
+
targetPort: 4049
|
|
171
|
+
- name: 'udp-4049'
|
|
158
172
|
protocol: UDP
|
|
159
|
-
port:
|
|
160
|
-
targetPort:
|
|
173
|
+
port: 4049
|
|
174
|
+
targetPort: 4049
|
|
161
175
|
|
|
162
|
-
- name: 'tcp-
|
|
176
|
+
- name: 'tcp-4050'
|
|
163
177
|
protocol: TCP
|
|
164
|
-
port:
|
|
165
|
-
targetPort:
|
|
166
|
-
- name: 'udp-
|
|
178
|
+
port: 4050
|
|
179
|
+
targetPort: 4050
|
|
180
|
+
- name: 'udp-4050'
|
|
167
181
|
protocol: UDP
|
|
168
|
-
port:
|
|
169
|
-
targetPort:
|
|
182
|
+
port: 4050
|
|
183
|
+
targetPort: 4050
|
|
170
184
|
type: LoadBalancer
|
|
@@ -9,13 +9,22 @@ spec:
|
|
|
9
9
|
virtualhost:
|
|
10
10
|
fqdn: test.nexodev.org
|
|
11
11
|
routes:
|
|
12
|
+
- conditions:
|
|
13
|
+
- prefix: /wp
|
|
14
|
+
|
|
15
|
+
enableWebsockets: true
|
|
16
|
+
services:
|
|
17
|
+
- name: dd-test-development-blue-service
|
|
18
|
+
port: 4046
|
|
19
|
+
weight: 100
|
|
20
|
+
|
|
12
21
|
- conditions:
|
|
13
22
|
- prefix: /
|
|
14
23
|
|
|
15
24
|
enableWebsockets: true
|
|
16
25
|
services:
|
|
17
26
|
- name: dd-test-development-blue-service
|
|
18
|
-
port:
|
|
27
|
+
port: 4047
|
|
19
28
|
weight: 100
|
|
20
29
|
|
|
21
30
|
- conditions:
|
|
@@ -24,7 +33,7 @@ spec:
|
|
|
24
33
|
enableWebsockets: true
|
|
25
34
|
services:
|
|
26
35
|
- name: dd-test-development-blue-service
|
|
27
|
-
port:
|
|
36
|
+
port: 4048
|
|
28
37
|
weight: 100
|
|
29
38
|
|
|
30
39
|
---
|
|
@@ -43,7 +52,7 @@ spec:
|
|
|
43
52
|
enableWebsockets: true
|
|
44
53
|
services:
|
|
45
54
|
- name: dd-test-development-blue-service
|
|
46
|
-
port:
|
|
55
|
+
port: 4049
|
|
47
56
|
weight: 100
|
|
48
57
|
|
|
49
58
|
- conditions:
|
|
@@ -52,6 +61,6 @@ spec:
|
|
|
52
61
|
enableWebsockets: true
|
|
53
62
|
services:
|
|
54
63
|
- name: dd-test-development-blue-service
|
|
55
|
-
port:
|
|
64
|
+
port: 4050
|
|
56
65
|
weight: 100
|
|
57
66
|
|
package/nodemon.json
CHANGED
package/package.json
CHANGED
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
"type": "module",
|
|
3
3
|
"main": "src/index.js",
|
|
4
4
|
"name": "underpost",
|
|
5
|
-
"version": "3.
|
|
5
|
+
"version": "3.2.2",
|
|
6
6
|
"description": "pwa api rest template",
|
|
7
7
|
"scripts": {
|
|
8
|
-
"start": "node --max-old-space-size=8192 src/server
|
|
8
|
+
"start": "node --max-old-space-size=8192 src/server",
|
|
9
9
|
"build": "node bin client",
|
|
10
10
|
"test": "NODE_ENV=test c8 mocha",
|
|
11
11
|
"dev": "NODE_ENV=development nodemon src/server",
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"dev:proxy": "NODE_ENV=development node src/proxy proxy",
|
|
17
17
|
"docs": "jsdoc -c jsdoc.json",
|
|
18
18
|
"install:global": "npm install -g jsdoc && npm install -g prettier",
|
|
19
|
-
"install:test": "npm install -g mocha && npm install -g c8 && npm install -g coveralls",
|
|
19
|
+
"install:test": "npm install -g mocha && npm install -g c8 && npm install -g coveralls-next",
|
|
20
20
|
"install": "npm run install:global && npm run install:test",
|
|
21
21
|
"prettier": "prettier --write .",
|
|
22
22
|
"fix": "npm audit fix --force && npm audit",
|
|
@@ -53,10 +53,12 @@
|
|
|
53
53
|
"dependencies": {
|
|
54
54
|
"@fortawesome/fontawesome-free": "^7.2.0",
|
|
55
55
|
"@fullcalendar/rrule": "^6.1.20",
|
|
56
|
+
"@grpc/grpc-js": "^1.12.5",
|
|
57
|
+
"@grpc/proto-loader": "^0.8.0",
|
|
56
58
|
"@neodrag/vanilla": "^2.3.1",
|
|
57
|
-
"adm-zip": "^0.5.
|
|
58
|
-
"ag-grid-community": "^35.1
|
|
59
|
-
"axios": "^1.
|
|
59
|
+
"adm-zip": "^0.5.17",
|
|
60
|
+
"ag-grid-community": "^35.2.1",
|
|
61
|
+
"axios": "^1.14.0",
|
|
60
62
|
"chai": "^6.2.2",
|
|
61
63
|
"clean-jsdoc-theme": "^4.3.0",
|
|
62
64
|
"clipboardy": "^5.3.1",
|
|
@@ -67,12 +69,13 @@
|
|
|
67
69
|
"cookie-parser": "^1.4.7",
|
|
68
70
|
"cors": "^2.8.6",
|
|
69
71
|
"d3": "^7.9.0",
|
|
70
|
-
"dotenv": "^17.
|
|
72
|
+
"dotenv": "^17.4.2",
|
|
71
73
|
"easymde": "^2.18.0",
|
|
74
|
+
"esbuild": "^0.28.0",
|
|
72
75
|
"escape-string-regexp": "^5.0.0",
|
|
73
76
|
"express": "^5.2.1",
|
|
74
77
|
"express-fileupload": "^1.4.3",
|
|
75
|
-
"express-rate-limit": "^8.3.
|
|
78
|
+
"express-rate-limit": "^8.3.2",
|
|
76
79
|
"express-slow-down": "^3.1.0",
|
|
77
80
|
"fast-json-stable-stringify": "^2.1.0",
|
|
78
81
|
"favicons": "^7.2.0",
|
|
@@ -83,14 +86,15 @@
|
|
|
83
86
|
"http-proxy-middleware": "^3.0.5",
|
|
84
87
|
"ignore-walk": "^8.0.0",
|
|
85
88
|
"iovalkey": "^0.3.3",
|
|
89
|
+
"is-inside-container": "^1.0.0",
|
|
86
90
|
"json-colorizer": "^3.0.1",
|
|
87
91
|
"jsonwebtoken": "^9.0.3",
|
|
88
92
|
"mariadb": "^3.2.2",
|
|
89
|
-
"marked": "^
|
|
93
|
+
"marked": "^18.0.0",
|
|
90
94
|
"mocha": "^11.3.0",
|
|
91
|
-
"mongoose": "^9.
|
|
95
|
+
"mongoose": "^9.4.1",
|
|
92
96
|
"morgan": "^1.10.0",
|
|
93
|
-
"nodemailer": "^8.0.
|
|
97
|
+
"nodemailer": "^8.0.3",
|
|
94
98
|
"nodemon": "^3.0.1",
|
|
95
99
|
"peer": "^1.0.2",
|
|
96
100
|
"peerjs": "^1.5.5",
|
|
@@ -104,9 +108,8 @@
|
|
|
104
108
|
"split-file": "^2.3.0",
|
|
105
109
|
"swagger-autogen": "^2.23.7",
|
|
106
110
|
"swagger-ui-express": "^5.0.0",
|
|
107
|
-
"
|
|
108
|
-
"
|
|
109
|
-
"vanilla-jsoneditor": "^3.11.0",
|
|
111
|
+
"validator": "^13.15.35",
|
|
112
|
+
"vanilla-jsoneditor": "^3.12.0",
|
|
110
113
|
"winston": "^3.19.0"
|
|
111
114
|
},
|
|
112
115
|
"publishConfig": {
|
|
@@ -115,11 +118,15 @@
|
|
|
115
118
|
"registry": "https://registry.npmjs.org/"
|
|
116
119
|
},
|
|
117
120
|
"overrides": {
|
|
121
|
+
"simple-xml-to-json": "1.2.4",
|
|
118
122
|
"minimatch": "^10.2.2",
|
|
119
123
|
"glob": "^11.0.0",
|
|
120
124
|
"diff": ">=8.0.3",
|
|
121
125
|
"js-yaml": ">=3.14.2",
|
|
122
126
|
"debug": ">=4.3.6",
|
|
123
|
-
"serialize-javascript": ">=7.0.
|
|
127
|
+
"serialize-javascript": ">=7.0.5",
|
|
128
|
+
"router": {
|
|
129
|
+
"path-to-regexp": ">=8.4.0"
|
|
130
|
+
}
|
|
124
131
|
}
|
|
125
132
|
}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
set -euo pipefail
|
|
3
|
+
|
|
4
|
+
# ──────────────────────────────────────────────────────────────────
|
|
5
|
+
# rhel-grpc-setup.sh — Install gRPC / Protocol Buffers system
|
|
6
|
+
# packages on RHEL / Rocky Linux / AlmaLinux / Fedora.
|
|
7
|
+
#
|
|
8
|
+
# Installs:
|
|
9
|
+
# 1. protobuf-compiler (protoc) + protobuf-devel
|
|
10
|
+
# 2. grpc / grpc-devel / grpc-plugins (C++ libs + plugin binaries)
|
|
11
|
+
#
|
|
12
|
+
# For Go-specific tooling (protoc-gen-go, protoc-gen-go-grpc,
|
|
13
|
+
# go mod tidy, proto codegen) use:
|
|
14
|
+
# ./cyberia-server/scripts/grpc-setup.sh
|
|
15
|
+
#
|
|
16
|
+
# Usage:
|
|
17
|
+
# sudo ./scripts/rhel-grpc-setup.sh
|
|
18
|
+
# ──────────────────────────────────────────────────────────────────
|
|
19
|
+
|
|
20
|
+
if [[ "${1:-}" == "-h" || "${1:-}" == "--help" ]]; then
|
|
21
|
+
echo "Usage: sudo $0"
|
|
22
|
+
echo "Installs protobuf + gRPC system packages via dnf."
|
|
23
|
+
echo "For Go codegen plugins, run: ./cyberia-server/scripts/grpc-setup.sh"
|
|
24
|
+
exit 0
|
|
25
|
+
fi
|
|
26
|
+
|
|
27
|
+
# ── 1. Enable EPEL (needed for protobuf / grpc on RHEL) ──────────
|
|
28
|
+
echo ">>> Enabling EPEL repository..."
|
|
29
|
+
sudo dnf install -y epel-release || true
|
|
30
|
+
sudo dnf install -y dnf-plugins-core || true
|
|
31
|
+
|
|
32
|
+
# On RHEL proper, enable CRB/PowerTools for devel headers
|
|
33
|
+
if grep -qi 'Red Hat Enterprise' /etc/os-release 2>/dev/null; then
|
|
34
|
+
sudo dnf config-manager --set-enabled codeready-builder-for-rhel-"$(rpm -E %rhel)"-"$(uname -m)-rpms" 2>/dev/null || true
|
|
35
|
+
elif grep -qi 'Rocky\|AlmaLinux' /etc/os-release 2>/dev/null; then
|
|
36
|
+
sudo dnf config-manager --set-enabled crb 2>/dev/null || \
|
|
37
|
+
sudo dnf config-manager --set-enabled powertools 2>/dev/null || true
|
|
38
|
+
fi
|
|
39
|
+
|
|
40
|
+
# ── 2. Install protobuf compiler + gRPC system packages ──────────
|
|
41
|
+
echo ">>> Installing protobuf-compiler, protobuf-devel, grpc, grpc-devel, grpc-plugins..."
|
|
42
|
+
sudo dnf install -y \
|
|
43
|
+
protobuf-compiler \
|
|
44
|
+
protobuf-devel \
|
|
45
|
+
grpc \
|
|
46
|
+
grpc-devel \
|
|
47
|
+
grpc-plugins
|
|
48
|
+
|
|
49
|
+
# ── 3. Verify protoc ─────────────────────────────────────────────
|
|
50
|
+
if command -v protoc &>/dev/null; then
|
|
51
|
+
echo ">>> protoc installed: $(protoc --version)"
|
|
52
|
+
else
|
|
53
|
+
echo "WARNING: protoc not found in PATH after install." >&2
|
|
54
|
+
fi
|
|
55
|
+
|
|
56
|
+
echo ">>> gRPC system packages setup complete."
|
|
@@ -1,10 +1,28 @@
|
|
|
1
1
|
[
|
|
2
|
+
{
|
|
3
|
+
"api": "atlas-sprite-sheet",
|
|
4
|
+
"model": {
|
|
5
|
+
"fileId": true
|
|
6
|
+
}
|
|
7
|
+
},
|
|
2
8
|
{
|
|
3
9
|
"api": "company",
|
|
4
10
|
"model": {
|
|
5
11
|
"logo": true
|
|
6
12
|
}
|
|
7
13
|
},
|
|
14
|
+
{
|
|
15
|
+
"api": "cyberia-instance",
|
|
16
|
+
"model": {
|
|
17
|
+
"thumbnail": true
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
"api": "cyberia-map",
|
|
22
|
+
"model": {
|
|
23
|
+
"thumbnail": true
|
|
24
|
+
}
|
|
25
|
+
},
|
|
8
26
|
{
|
|
9
27
|
"api": "document",
|
|
10
28
|
"model": {
|
|
@@ -13,8 +13,7 @@ import {
|
|
|
13
13
|
validatePasswordMiddleware,
|
|
14
14
|
} from '../../server/auth.js';
|
|
15
15
|
import { MailerProvider } from '../../mailer/MailerProvider.js';
|
|
16
|
-
import {
|
|
17
|
-
import { CoreWsEmit } from '../../ws/core/core.ws.emit.js';
|
|
16
|
+
import { CoreWsEmitter } from '../../ws/core/core.ws.emit.js';
|
|
18
17
|
import { CoreWsMailerChannel } from '../../ws/core/channels/core.ws.mailer.js';
|
|
19
18
|
import validator from 'validator';
|
|
20
19
|
import { DataBaseProvider } from '../../db/DataBaseProvider.js';
|
|
@@ -319,11 +318,13 @@ const UserService = {
|
|
|
319
318
|
{
|
|
320
319
|
const user = await User.findByIdAndUpdate(_id, { emailConfirmed: true }, { runValidators: true });
|
|
321
320
|
}
|
|
322
|
-
const userWsId =
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
321
|
+
const userWsId = CoreWsMailerChannel.getUserWsId(`${options.host}${options.path}`, user._id.toString());
|
|
322
|
+
if (userWsId && CoreWsMailerChannel.client[userWsId]) {
|
|
323
|
+
CoreWsEmitter.emit(CoreWsMailerChannel.channel, CoreWsMailerChannel.client[userWsId], {
|
|
324
|
+
status: 'email-confirmed',
|
|
325
|
+
id: userWsId,
|
|
326
|
+
});
|
|
327
|
+
}
|
|
327
328
|
options.png.header(res, req);
|
|
328
329
|
return options.png.buffer['check'];
|
|
329
330
|
} else {
|
package/src/cli/cluster.js
CHANGED
|
@@ -111,7 +111,7 @@ class UnderpostCluster {
|
|
|
111
111
|
const npmRoot = getNpmRootPath();
|
|
112
112
|
const underpostRoot = options.dev ? '.' : `${npmRoot}/underpost`;
|
|
113
113
|
|
|
114
|
-
if (options.listPods) return console.table(Underpost.
|
|
114
|
+
if (options.listPods) return console.table(Underpost.kubectl.get(podName ?? undefined));
|
|
115
115
|
// Set default namespace if not specified
|
|
116
116
|
if (!options.namespace) options.namespace = 'default';
|
|
117
117
|
|
|
@@ -146,10 +146,10 @@ class UnderpostCluster {
|
|
|
146
146
|
}
|
|
147
147
|
|
|
148
148
|
// Check if a cluster (Kind, Kubeadm, or K3s) is already initialized
|
|
149
|
-
const alreadyKubeadmCluster = Underpost.
|
|
150
|
-
const alreadyKindCluster = Underpost.
|
|
149
|
+
const alreadyKubeadmCluster = Underpost.kubectl.get('calico-kube-controllers')[0];
|
|
150
|
+
const alreadyKindCluster = Underpost.kubectl.get('kube-apiserver-kind-control-plane')[0];
|
|
151
151
|
// K3s pods often contain 'svclb-traefik' in the kube-system namespace
|
|
152
|
-
const alreadyK3sCluster = Underpost.
|
|
152
|
+
const alreadyK3sCluster = Underpost.kubectl.get('svclb-traefik')[0];
|
|
153
153
|
|
|
154
154
|
// --- Kubeadm/Kind/K3s Cluster Initialization ---
|
|
155
155
|
if (!alreadyKubeadmCluster && !alreadyKindCluster && !alreadyK3sCluster) {
|
|
@@ -299,7 +299,7 @@ EOF
|
|
|
299
299
|
members: [{ _id: 0, host: `${options.mongoDbHost}:27017` }],
|
|
300
300
|
};
|
|
301
301
|
|
|
302
|
-
const [pod] = Underpost.
|
|
302
|
+
const [pod] = Underpost.kubectl.get(deploymentName);
|
|
303
303
|
|
|
304
304
|
shellExec(
|
|
305
305
|
`sudo kubectl exec -i ${pod.NAME} -- mongo --quiet \
|
|
@@ -351,7 +351,7 @@ EOF
|
|
|
351
351
|
}
|
|
352
352
|
|
|
353
353
|
if (options.certManager) {
|
|
354
|
-
if (!Underpost.
|
|
354
|
+
if (!Underpost.kubectl.get('cert-manager').find((p) => p.STATUS === 'Running')) {
|
|
355
355
|
shellExec(`helm repo add jetstack https://charts.jetstack.io --force-update`);
|
|
356
356
|
shellExec(
|
|
357
357
|
`helm install cert-manager jetstack/cert-manager \
|
|
@@ -641,7 +641,7 @@ net.ipv4.ip_forward = 1' | sudo tee ${iptableConfPath}`,
|
|
|
641
641
|
const resources = {};
|
|
642
642
|
const nodeName = node
|
|
643
643
|
? node
|
|
644
|
-
: Underpost.
|
|
644
|
+
: Underpost.kubectl.get('kind-control-plane', 'node').length > 0
|
|
645
645
|
? 'kind-control-plane'
|
|
646
646
|
: os.hostname();
|
|
647
647
|
const info = shellExec(`kubectl describe node ${nodeName} | grep -E '(Allocatable:|Capacity:)' -A 6`, {
|