underpost 2.8.65 → 2.8.67

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/cli.md ADDED
@@ -0,0 +1,451 @@
1
+ ## underpost ci/cd cli v2.8.67
2
+
3
+ ### Usage: `underpost [options] [command]`
4
+ ```
5
+ Options:
6
+ -V, --version output the version number
7
+ -h, --help display help for command
8
+
9
+ Commands:
10
+ new <app-name> Create a new project
11
+ start [options] <deploy-id> [env] Start up server, build pipelines, or services
12
+ clone [options] <uri> Clone github repository
13
+ pull <path> <uri> Pull github repository
14
+ cmt [options] <path> <commit-type> [module-tag] [message] Commit github repository
15
+ push [options] <path> <uri> Push github repository
16
+ env <deploy-id> [env] Set environment variables files and conf related to <deploy-id>
17
+ config <operator> [key] [value] Manage configuration, operators
18
+ root Get npm root path
19
+ cluster [options] [pod-name] Manage cluster, for default initialization base kind cluster
20
+ deploy [options] <deploy-list> [env] Manage deployment, for default deploy development pods
21
+ secret [options] <platform> Manage secrets
22
+ dockerfile-image-build [options] Build image from Dockerfile
23
+ dockerfile-pull-base-images Pull underpost dockerfile images requirements
24
+ install Fast import underpost npm dependencies
25
+ db [options] <deploy-list> Manage databases
26
+ script [options] <operator> <script-name> [script-value] Supports a number of built-in underpost global scripts and their preset life cycle events as well as arbitrary scripts
27
+ cron [options] [deploy-list] [job-list] Cron jobs management
28
+ fs [options] [path] File storage management, for default upload file
29
+ test [options] [deploy-list] Manage Test, for default run current underpost default test
30
+ monitor [options] <deploy-id> [env] Monitor health server management
31
+ help [command] display help for command
32
+
33
+ ```
34
+
35
+ ## Commands:
36
+
37
+
38
+ ### `new` :
39
+ ```
40
+ Usage: underpost new [options] <app-name>
41
+
42
+ Create a new project
43
+
44
+ Arguments:
45
+ app-name Application name
46
+
47
+ Options:
48
+ -h, --help display help for command
49
+
50
+ ```
51
+
52
+
53
+ ### `start` :
54
+ ```
55
+ Usage: underpost start [options] <deploy-id> [env]
56
+
57
+ Start up server, build pipelines, or services
58
+
59
+ Arguments:
60
+ deploy-id Deploy configuration id
61
+ env Optional environment, for default is development
62
+
63
+ Options:
64
+ --run Run app servers and monitor health server
65
+ --build Build app client
66
+ -h, --help display help for command
67
+
68
+ ```
69
+
70
+
71
+ ### `clone` :
72
+ ```
73
+ Usage: underpost clone [options] <uri>
74
+
75
+ Clone github repository
76
+
77
+ Arguments:
78
+ uri e.g. username/repository
79
+
80
+ Options:
81
+ --bare Clone only .git files
82
+ -h, --help display help for command
83
+
84
+ ```
85
+
86
+
87
+ ### `pull` :
88
+ ```
89
+ Usage: underpost pull [options] <path> <uri>
90
+
91
+ Pull github repository
92
+
93
+ Arguments:
94
+ path Absolute or relative directory
95
+ uri e.g. username/repository
96
+
97
+ Options:
98
+ -h, --help display help for command
99
+
100
+ ```
101
+
102
+
103
+ ### `cmt` :
104
+ ```
105
+ Usage: underpost cmt [options] <path> <commit-type> [module-tag] [message]
106
+
107
+ Commit github repository
108
+
109
+ Arguments:
110
+ path Absolute or relative directory
111
+ commit-type Options:
112
+ feat,fix,docs,style,refactor,perf,cd,test,build,ci,chore,revert,backup
113
+ module-tag Optional set module tag
114
+ message Optional set additional message
115
+
116
+ Options:
117
+ --empty Allow empty files
118
+ --copy Copy to clipboard message
119
+ --info Info commit types
120
+ -h, --help display help for command
121
+
122
+ ```
123
+
124
+
125
+ ### `push` :
126
+ ```
127
+ Usage: underpost push [options] <path> <uri>
128
+
129
+ Push github repository
130
+
131
+ Arguments:
132
+ path Absolute or relative directory
133
+ uri e.g. username/repository
134
+
135
+ Options:
136
+ -f Force push overwriting repository
137
+ -h, --help display help for command
138
+
139
+ ```
140
+
141
+
142
+ ### `env` :
143
+ ```
144
+ Usage: underpost env [options] <deploy-id> [env]
145
+
146
+ Set environment variables files and conf related to <deploy-id>
147
+
148
+ Arguments:
149
+ deploy-id deploy configuration id, if 'clean' restore default
150
+ env Optional environment, for default is production
151
+
152
+ Options:
153
+ -h, --help display help for command
154
+
155
+ ```
156
+
157
+
158
+ ### `config` :
159
+ ```
160
+ Usage: underpost config [options] <operator> [key] [value]
161
+
162
+ Manage configuration, operators
163
+
164
+ Arguments:
165
+ operator Options: set,delete,get,list,clean
166
+ key Config key
167
+ value Config value
168
+
169
+ Options:
170
+ -h, --help display help for command
171
+
172
+ ```
173
+
174
+
175
+ ### `root` :
176
+ ```
177
+ Usage: underpost root [options]
178
+
179
+ Get npm root path
180
+
181
+ Options:
182
+ -h, --help display help for command
183
+
184
+ ```
185
+
186
+
187
+ ### `cluster` :
188
+ ```
189
+ Usage: underpost cluster [options] [pod-name]
190
+
191
+ Manage cluster, for default initialization base kind cluster
192
+
193
+ Arguments:
194
+ pod-name Optional pod name filter
195
+
196
+ Options:
197
+ --reset Delete all clusters and prune all data and caches
198
+ --mariadb Init with mariadb statefulset
199
+ --mongodb Init with mongodb statefulset
200
+ --postgresql Init with postgresql statefulset
201
+ --mongodb4 Init with mongodb 4.4 service
202
+ --istio Init base istio cluster
203
+ --valkey Init with valkey service
204
+ --contour Init with project contour base HTTPProxy and envoy
205
+ --cert-manager Init with letsencrypt-prod ClusterIssuer
206
+ --info Get all kinds objects deployed
207
+ --full Init with all statefulsets and services available
208
+ --ns-use <ns-name> Switches current context to namespace
209
+ --dev init with dev cluster
210
+ --list-pods Display list pods information
211
+ --info-capacity display current total machine capacity info
212
+ --info-capacity-pod display current machine capacity pod info
213
+ --pull-image Set optional pull associated image
214
+ -h, --help display help for command
215
+
216
+ ```
217
+
218
+
219
+ ### `deploy` :
220
+ ```
221
+ Usage: underpost deploy [options] <deploy-list> [env]
222
+
223
+ Manage deployment, for default deploy development pods
224
+
225
+ Arguments:
226
+ deploy-list Deploy id list, e.g. default-a,default-b
227
+ env Optional environment, for default is
228
+ development
229
+
230
+ Options:
231
+ --remove Delete deployments and services
232
+ --sync Sync deployments env, ports, and replicas
233
+ --info-router Display router structure
234
+ --expose Expose service match deploy-list
235
+ --info-util Display kubectl util management commands
236
+ --cert Reset tls/ssl certificate secrets
237
+ --build-manifest Build kind yaml manifests: deployments,
238
+ services, proxy and secrets
239
+ --dashboard-update Update dashboard instance data with current
240
+ router config
241
+ --replicas <replicas> Set custom number of replicas
242
+ --versions <deployment-versions> Comma separated custom deployment versions
243
+ --traffic <traffic-versions> Comma separated custom deployment traffic
244
+ --disable-update-deployment Disable update deployments
245
+ --info-traffic get traffic conf form current resources
246
+ deployments
247
+ --rebuild-clients-bundle Inside container, rebuild clients bundle,
248
+ only static public or storage client files
249
+ -h, --help display help for command
250
+
251
+ ```
252
+
253
+
254
+ ### `secret` :
255
+ ```
256
+ Usage: underpost secret [options] <platform>
257
+
258
+ Manage secrets
259
+
260
+ Arguments:
261
+ platform Options: docker,underpost
262
+
263
+ Options:
264
+ --init Init secrets platform environment
265
+ --create-from-file <path-env-file> Create secret from env file
266
+ --list Lists secrets
267
+ -h, --help display help for command
268
+
269
+ ```
270
+
271
+
272
+ ### `dockerfile-image-build` :
273
+ ```
274
+ Usage: underpost dockerfile-image-build [options]
275
+
276
+ Build image from Dockerfile
277
+
278
+ Options:
279
+ --path [path] Dockerfile path
280
+ --image-name [image-name] Set image name
281
+ --image-path [image-path] Set tar image path
282
+ --dockerfile-name [dockerfile-name] set Dockerfile name
283
+ --podman-save Export tar file from podman
284
+ --kind-load Import tar image to Kind cluster
285
+ --secrets Dockerfile env secrets
286
+ --secrets-path [secrets-path] Dockerfile custom path env secrets
287
+ --no-cache Build without using cache
288
+ -h, --help display help for command
289
+
290
+ ```
291
+
292
+
293
+ ### `dockerfile-pull-base-images` :
294
+ ```
295
+ Usage: underpost dockerfile-pull-base-images [options]
296
+
297
+ Pull underpost dockerfile images requirements
298
+
299
+ Options:
300
+ -h, --help display help for command
301
+
302
+ ```
303
+
304
+
305
+ ### `install` :
306
+ ```
307
+ Usage: underpost install [options]
308
+
309
+ Fast import underpost npm dependencies
310
+
311
+ Options:
312
+ -h, --help display help for command
313
+
314
+ ```
315
+
316
+
317
+ ### `db` :
318
+ ```
319
+ Usage: underpost db [options] <deploy-list>
320
+
321
+ Manage databases
322
+
323
+ Arguments:
324
+ deploy-list Deploy id list, e.g. default-a,default-b
325
+
326
+ Options:
327
+ --import Import container backups from repositories
328
+ --export Export container backups to repositories
329
+ --pod-name <pod-name> Optional pod context
330
+ --collections <collections> Comma separated collections
331
+ --out-path <out-path> Custom out path backup
332
+ --drop Drop databases
333
+ --preserveUUID Preserve Ids
334
+ --git Upload to github
335
+ --hosts <hosts> Comma separated hosts
336
+ --paths <paths> Comma separated paths
337
+ --ns <ns-name> Optional name space context
338
+ -h, --help display help for command
339
+
340
+ ```
341
+
342
+
343
+ ### `script` :
344
+ ```
345
+ Usage: underpost script [options] <operator> <script-name> [script-value]
346
+
347
+ Supports a number of built-in underpost global scripts and their preset life
348
+ cycle events as well as arbitrary scripts
349
+
350
+ Arguments:
351
+ operator Options: set,run,get
352
+ script-name Script name
353
+ script-value Literal command, or path
354
+
355
+ Options:
356
+ --itc Inside container execution context
357
+ --itc-path Inside container path options
358
+ --ns <ns-name> Options name space context
359
+ --pod-name <pod-name>
360
+ -h, --help display help for command
361
+
362
+ ```
363
+
364
+
365
+ ### `cron` :
366
+ ```
367
+ Usage: underpost cron [options] [deploy-list] [job-list]
368
+
369
+ Cron jobs management
370
+
371
+ Arguments:
372
+ deploy-list Deploy id list, e.g. default-a,default-b
373
+ job-list Deploy id list, e.g. callback,updateDashboardData, for
374
+ default all available jobs
375
+
376
+ Options:
377
+ --itc Inside container execution context
378
+ --init Init cron jobs for cron job default deploy id
379
+ --git Upload to github
380
+ --dashboard-update Update dashboard cron data with current jobs config
381
+ -h, --help display help for command
382
+
383
+ ```
384
+
385
+
386
+ ### `fs` :
387
+ ```
388
+ Usage: underpost fs [options] [path]
389
+
390
+ File storage management, for default upload file
391
+
392
+ Arguments:
393
+ path Absolute or relative directory
394
+
395
+ Options:
396
+ --rm Remove file
397
+ --git Current git changes
398
+ --recursive Upload files recursively
399
+ --deploy-id <deploy-id> Deploy configuration id
400
+ --pull Download file
401
+ --force Force action
402
+ --storage-file-path <storage-file-path> custom file storage path
403
+ -h, --help display help for command
404
+
405
+ ```
406
+
407
+
408
+ ### `test` :
409
+ ```
410
+ Usage: underpost test [options] [deploy-list]
411
+
412
+ Manage Test, for default run current underpost default test
413
+
414
+ Arguments:
415
+ deploy-list Deploy id list, e.g. default-a,default-b
416
+
417
+ Options:
418
+ --itc Inside container execution context
419
+ --sh Copy to clipboard, container entrypoint shell
420
+ command
421
+ --logs Display container logs
422
+ --pod-name <pod-name>
423
+ --pod-status <pod-status>
424
+ --kind-type <kind-type>
425
+ -h, --help display help for command
426
+
427
+ ```
428
+
429
+
430
+ ### `monitor` :
431
+ ```
432
+ Usage: underpost monitor [options] <deploy-id> [env]
433
+
434
+ Monitor health server management
435
+
436
+ Arguments:
437
+ deploy-id Deploy configuration id
438
+ env Optional environment, for default is development
439
+
440
+ Options:
441
+ --ms-interval <ms-interval> Custom ms interval delta time
442
+ --now Exec immediately monitor script
443
+ --single Disable recurrence
444
+ --replicas <replicas> Set custom number of replicas
445
+ --type <type> Set custom monitor type
446
+ --sync Sync with current proxy deployments proxy
447
+ traffic
448
+ -h, --help display help for command
449
+
450
+ ```
451
+
@@ -58,7 +58,7 @@ services:
58
58
  cpus: '0.25'
59
59
  memory: 20M
60
60
  labels: # labels in Compose file instead of Dockerfile
61
- engine.version: '2.8.65'
61
+ engine.version: '2.8.67'
62
62
  networks:
63
63
  - load-balancer
64
64
 
package/jsdoc.json CHANGED
@@ -23,7 +23,7 @@
23
23
  "homepageTitle": "Docs",
24
24
  "favicon": "./public/www.nexodev.org/"
25
25
  },
26
- "tutorials": "./public/www.nexodev.org/docs/learn"
26
+ "tutorials": "./public/www.nexodev.org/docs/references"
27
27
  },
28
28
  "markdown": {
29
29
  "hardwrap": false,
@@ -0,0 +1,25 @@
1
+ # This section includes base Calico installation configuration.
2
+ # For more information, see: https://projectcalico.docs.tigera.io/master/reference/installation/api#operator.tigera.io/v1.Installation
3
+ apiVersion: operator.tigera.io/v1
4
+ kind: Installation
5
+ metadata:
6
+ name: default
7
+ spec:
8
+ # Configures Calico networking.
9
+ calicoNetwork:
10
+ # Note: The ipPools section cannot be modified post-install.
11
+ ipPools:
12
+ - blockSize: 26
13
+ cidr: 192.168.0.0/16
14
+ encapsulation: VXLANCrossSubnet
15
+ natOutgoing: Enabled
16
+ nodeSelector: all()
17
+
18
+ ---
19
+ # This section configures the Calico API server.
20
+ # For more information, see: https://projectcalico.docs.tigera.io/master/reference/installation/api#operator.tigera.io/v1.APIServer
21
+ apiVersion: operator.tigera.io/v1
22
+ kind: APIServer
23
+ metadata:
24
+ name: default
25
+ spec: {}
@@ -0,0 +1,32 @@
1
+ apiVersion: apps/v1
2
+ kind: Deployment
3
+ metadata:
4
+ name: adminer
5
+ labels:
6
+ app: adminer
7
+ group: db
8
+ spec:
9
+ replicas: 1
10
+ selector:
11
+ matchLabels:
12
+ app: adminer
13
+ template:
14
+ metadata:
15
+ labels:
16
+ app: adminer
17
+ group: db
18
+ spec:
19
+ containers:
20
+ - name: adminer
21
+ image: adminer:4.7.6-standalone
22
+ ports:
23
+ - containerPort: 8080
24
+ env:
25
+ - name: ADMINER_DESIGN
26
+ value: pepa-linha
27
+ - name: ADMINER_DEFAULT_SERVER
28
+ value: postgres
29
+ resources:
30
+ limits:
31
+ memory: '256Mi'
32
+ cpu: '500m'
@@ -0,0 +1,7 @@
1
+ ---
2
+ # kubectl apply -k manifests/deployment/adminer/.
3
+ apiVersion: kustomize.config.k8s.io/v1beta1
4
+ kind: Kustomization
5
+ resources:
6
+ - deployment.yaml
7
+ - service.yaml
@@ -0,0 +1,13 @@
1
+ apiVersion: v1
2
+ kind: Service
3
+ metadata:
4
+ name: adminer
5
+ labels:
6
+ group: db
7
+ spec:
8
+ type: ClusterIP
9
+ selector:
10
+ app: adminer
11
+ ports:
12
+ - port: 8080
13
+ targetPort: 8080
@@ -16,7 +16,7 @@ spec:
16
16
  hostname: mongo
17
17
  containers:
18
18
  - name: mongodb
19
- image: docker.io/library/mongo:4.4
19
+ image: mongo:4.4
20
20
  command: ['mongod', '--replSet', 'rs0', '--bind_ip_all']
21
21
  # -- bash
22
22
  # mongo
@@ -0,0 +1,9 @@
1
+ apiVersion: v1
2
+ kind: ConfigMap
3
+ metadata:
4
+ name: postgres-config
5
+ labels:
6
+ app: postgres
7
+ data:
8
+ POSTGRES_DB: postgresdb
9
+ POSTGRES_USER: admin
@@ -0,0 +1,10 @@
1
+ ---
2
+ # kubectl apply -k postgresql/.
3
+ apiVersion: kustomize.config.k8s.io/v1beta1
4
+ kind: Kustomization
5
+ resources:
6
+ - pv.yaml
7
+ - pvc.yaml
8
+ - configmap.yaml
9
+ - statefulset.yaml
10
+ - service.yaml
@@ -0,0 +1,15 @@
1
+ kind: PersistentVolume
2
+ apiVersion: v1
3
+ metadata:
4
+ name: postgres-pv-volume
5
+ labels:
6
+ type: local
7
+ app: postgres
8
+ spec:
9
+ storageClassName: manual
10
+ capacity:
11
+ storage: 5Gi
12
+ accessModes:
13
+ - ReadWriteMany
14
+ hostPath:
15
+ path: '/mnt/data'
@@ -0,0 +1,13 @@
1
+ kind: PersistentVolumeClaim
2
+ apiVersion: v1
3
+ metadata:
4
+ name: postgres-pv-claim
5
+ labels:
6
+ app: postgres
7
+ spec:
8
+ storageClassName: manual
9
+ accessModes:
10
+ - ReadWriteMany
11
+ resources:
12
+ requests:
13
+ storage: 5Gi
@@ -0,0 +1,10 @@
1
+ apiVersion: v1
2
+ kind: Service
3
+ metadata:
4
+ name: postgres-service
5
+ spec:
6
+ clusterIP: None
7
+ selector:
8
+ app: postgres
9
+ ports:
10
+ - port: 5432
@@ -0,0 +1,37 @@
1
+ apiVersion: apps/v1
2
+ kind: StatefulSet
3
+ metadata:
4
+ name: postgres
5
+ spec:
6
+ serviceName: postgres
7
+ replicas: 3
8
+ selector:
9
+ matchLabels:
10
+ app: postgres
11
+ template:
12
+ metadata:
13
+ labels:
14
+ app: postgres
15
+ spec:
16
+ containers:
17
+ - name: postgres
18
+ image: postgres:latest
19
+ imagePullPolicy: Never
20
+ ports:
21
+ - containerPort: 5432
22
+ envFrom:
23
+ - configMapRef:
24
+ name: postgres-config
25
+ env:
26
+ - name: POSTGRES_PASSWORD
27
+ valueFrom:
28
+ secretKeyRef:
29
+ name: postgres-secret
30
+ key: password
31
+ volumeMounts:
32
+ - mountPath: /var/lib/postgresql/data
33
+ name: postgredb
34
+ volumes:
35
+ - name: postgredb
36
+ persistentVolumeClaim:
37
+ claimName: postgres-pv-claim
@@ -1,4 +1,3 @@
1
- ---
2
1
  apiVersion: apps/v1
3
2
  kind: StatefulSet
4
3
  metadata:
@@ -15,9 +14,14 @@ spec:
15
14
  labels:
16
15
  app: service-valkey
17
16
  spec:
17
+ # Prevent automatic token mounting if you're not using the default ServiceAccount
18
+ automountServiceAccountToken: false
19
+
18
20
  containers:
19
21
  - name: service-valkey
20
- image: docker.io/valkey/valkey:latest
22
+ image: valkey/valkey:latest
23
+ # Ensure you pull only if not present (Never will error if missing)
24
+ imagePullPolicy: Never
21
25
  env:
22
26
  - name: TZ
23
27
  value: Europe/Zurich
@@ -35,5 +39,3 @@ spec:
35
39
  failureThreshold: 2
36
40
  periodSeconds: 30
37
41
  timeoutSeconds: 5
38
- restartPolicy: Always
39
- automountServiceAccountToken: false