@underpostnet/cyberia 3.2.90 → 3.3.0

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 (129) hide show
  1. package/.env.example +16 -0
  2. package/.github/workflows/coverall.cyberia.ci.yml +87 -0
  3. package/.github/workflows/cyberia-client.cd.yml +1 -18
  4. package/.github/workflows/cyberia-server.cd.yml +1 -18
  5. package/.github/workflows/docker-image.cyberia-client.ci.yml +1 -1
  6. package/.github/workflows/docker-image.cyberia-client.dev.ci.yml +1 -1
  7. package/.github/workflows/docker-image.cyberia-server.ci.yml +1 -1
  8. package/.github/workflows/docker-image.cyberia-server.dev.ci.yml +1 -1
  9. package/.github/workflows/docker-image.engine-cyberia.ci.yml +1 -1
  10. package/.github/workflows/docker-image.engine-cyberia.dev.ci.yml +1 -1
  11. package/.github/workflows/engine-cyberia.cd.yml +3 -78
  12. package/.github/workflows/ghpkg.ci.yml +7 -1
  13. package/.github/workflows/pwa-microservices-template-page.cd.yml +1 -16
  14. package/.github/workflows/pwa-microservices-template-test.ci.yml +1 -1
  15. package/.github/workflows/release.cd.yml +1 -9
  16. package/CHANGELOG.md +110 -1
  17. package/CLI-HELP.md +139 -9
  18. package/Dockerfile +1 -1
  19. package/Dockerfile.dev +1 -1
  20. package/Dockerfile.test +1 -1
  21. package/bin/build.js +7 -5
  22. package/bin/cyberia.js +73 -53
  23. package/bin/deploy.js +1 -1
  24. package/bin/index.js +73 -53
  25. package/compose.env +16 -0
  26. package/conf.js +2 -0
  27. package/deploy/dd-cyberia/deploy.sh +42 -0
  28. package/deploy/dd-cyberia/init.sh +63 -0
  29. package/deploy/dd-cyberia/sync-deploy.sh +194 -0
  30. package/deploy/lib/logging.sh +96 -0
  31. package/deploy/pwa-microservices-template/deploy.sh +72 -0
  32. package/deploy/release/deploy.sh +62 -0
  33. package/deployment.yaml +1 -1
  34. package/docker-compose.yml +31 -37
  35. package/hardhat/package-lock.json +9 -9
  36. package/hardhat/package.json +3 -3
  37. package/manifests/cronjobs/dd-cron/dd-cron-backup.yaml +5 -1
  38. package/manifests/cronjobs/dd-cron/dd-cron-dns.yaml +1 -1
  39. package/manifests/cronjobs/dd-cron/dd-cron-vultr.yaml +52 -0
  40. package/manifests/deployment/dd-cyberia-development/deployment.yaml +1 -1
  41. package/manifests/deployment/dd-default-development/deployment.yaml +2 -2
  42. package/package.json +2 -2
  43. package/scripts/audit-selinux.sh +64 -0
  44. package/scripts/coverall-test-cyberia.sh +24 -0
  45. package/scripts/coverall-test.sh +24 -0
  46. package/scripts/gpu-diag.sh +0 -0
  47. package/scripts/ip-info.sh +0 -0
  48. package/scripts/k3s-node-setup.sh +18 -15
  49. package/scripts/kubeadm-node-setup.sh +12 -23
  50. package/scripts/link-local-underpost-cli.sh +0 -0
  51. package/scripts/lxd-vm-setup.sh +0 -0
  52. package/scripts/maas-nat-firewalld.sh +0 -0
  53. package/scripts/nat-iptables.sh +2 -0
  54. package/scripts/rhel-grpc-setup.sh +0 -0
  55. package/scripts/rocky-kickstart.sh +25 -9
  56. package/scripts/test-monitor.sh +1 -1
  57. package/src/api/cyberia-instance/cyberia-fallback-default-items.js +63 -0
  58. package/src/api/cyberia-instance/cyberia-fallback-world.js +8 -1
  59. package/src/api/cyberia-instance/cyberia-instance.controller.js +3 -0
  60. package/src/api/cyberia-instance/cyberia-instance.router.js +13 -0
  61. package/src/api/cyberia-instance/cyberia-instance.service.js +43 -0
  62. package/src/api/cyberia-instance-conf/cyberia-instance-conf.model.js +1 -0
  63. package/src/api/cyberia-server-defaults/cyberia-server-defaults.js +16 -3
  64. package/src/api/object-layer/object-layer.model.js +204 -3
  65. package/src/api/object-layer/object-layer.service.js +1 -14
  66. package/src/cli/baremetal.js +1 -2
  67. package/src/cli/cloud-init.js +1 -1
  68. package/src/cli/cluster.js +73 -68
  69. package/src/cli/db.js +9 -2
  70. package/src/cli/deploy.js +21 -5
  71. package/src/cli/docker-compose.js +1 -1
  72. package/src/cli/env.js +1 -1
  73. package/src/cli/image.js +0 -1
  74. package/src/cli/index.js +121 -9
  75. package/src/cli/lxd.js +1 -1
  76. package/src/cli/monitor.js +1 -1
  77. package/src/cli/release.js +57 -22
  78. package/src/cli/repository.js +11 -9
  79. package/src/cli/run.js +36 -9
  80. package/src/cli/ssh.js +198 -77
  81. package/src/cli/system.js +26 -13
  82. package/src/cli/test.js +1 -1
  83. package/src/cli/vultr.js +583 -0
  84. package/src/cli/wireguard.js +2125 -0
  85. package/src/client/components/cyberia/FallbackWorldEngineCyberia.js +368 -0
  86. package/src/client/components/cyberia-portal/AppShellCyberiaPortal.js +33 -0
  87. package/src/client/components/cyberia-portal/RouterCyberiaPortal.js +4 -0
  88. package/src/client/components/cyberia-portal/TranslateCyberiaPortal.js +4 -0
  89. package/src/client/public/cyberia-docs/ARCHITECTURE.md +17 -3
  90. package/src/client/public/cyberia-docs/CYBERIA-SERVER.md +1 -1
  91. package/src/client/public/cyberia-docs/ROADMAP.md +1 -1
  92. package/src/client/public/cyberia-docs/WHITE-PAPER.md +1 -1
  93. package/src/client/services/cyberia-instance/cyberia-instance.service.js +40 -0
  94. package/src/client/services/object-layer/object-layer.management.js +4 -4
  95. package/src/client-builder/client-build.js +20 -14
  96. package/src/db/mongo/MongooseDB.js +4 -0
  97. package/src/index.js +25 -1
  98. package/src/projects/cyberia/catalog-cyberia.js +5 -0
  99. package/src/projects/cyberia/generate-saga.js +14 -23
  100. package/src/projects/cyberia/instance-data.js +21 -2
  101. package/src/projects/cyberia/object-layer.js +11 -21
  102. package/src/projects/underpost/catalog-underpost.js +4 -1
  103. package/src/runtime/cyberia-client/Dockerfile +1 -1
  104. package/src/runtime/cyberia-client/Dockerfile.dev +1 -1
  105. package/src/runtime/cyberia-server/Dockerfile +1 -1
  106. package/src/runtime/cyberia-server/Dockerfile.dev +1 -1
  107. package/src/runtime/engine-cyberia/Dockerfile +1 -1
  108. package/src/runtime/engine-cyberia/Dockerfile.dev +1 -1
  109. package/src/runtime/engine-cyberia/Dockerfile.test +1 -1
  110. package/src/runtime/engine-cyberia/compose.env +16 -0
  111. package/src/runtime/engine-cyberia/docker-compose.yml +31 -37
  112. package/src/server/backup.js +1 -1
  113. package/src/server/conf.js +18 -108
  114. package/src/server/cron.js +249 -51
  115. package/src/server/dns.js +100 -6
  116. package/src/server/environment.js +98 -0
  117. package/src/server/forward-proxy.js +549 -0
  118. package/src/server/middlewares.js +56 -1
  119. package/src/server/process.js +0 -1
  120. package/src/server/selinux.js +185 -0
  121. package/src/server/systemd.js +205 -0
  122. package/src/server/underpost-compression.js +186 -0
  123. package/src/server/underpost-gateway.js +20 -10
  124. package/src/server/underpost-ingress.js +18 -2
  125. package/test/cyberia-instance-conf-defaults.test.js +1 -0
  126. package/test/selinux.test.js +71 -0
  127. package/test/underpost-gateway.test.js +41 -0
  128. package/test/underpost-ingress.test.js +52 -0
  129. package/test/wireguard-edge.test.js +1177 -0
package/CLI-HELP.md CHANGED
@@ -1,6 +1,6 @@
1
1
  ## Underpost CLI
2
2
 
3
- > underpost ci/cd cli v3.2.90
3
+ > underpost ci/cd cli v3.3.0
4
4
 
5
5
  **Usage:** `underpost [options] [command]`
6
6
 
@@ -39,6 +39,9 @@
39
39
  | [`test`](#underpost-test) | Manages and runs tests, defaulting to the current Underpost default test suite. |
40
40
  | [`monitor`](#underpost-monitor) | Manages health server monitoring for specified deployments. |
41
41
  | [`ssh`](#underpost-ssh) | Manages SSH credentials and sessions for remote access to cluster nodes or services. |
42
+ | [`wireguard`](#underpost-wireguard) | Manages the WireGuard L3 hub-and-spoke transport and the HAProxy edge gateway in front of it. |
43
+ | [`haproxy`](#underpost-haproxy) | Manages the HAProxy edge gateway over the WireGuard transport (same subsystem as `underpost wireguard`). |
44
+ | [`vultr`](#underpost-vultr) | Meters the edge VPS bandwidth against its Vultr plan quota and blocks egress before overage accrues. |
42
45
  | [`run`](#underpost-run) | Runs specified scripts using various runners. |
43
46
  | [`docker-compose`](#underpost-docker-compose) | General-purpose Docker Compose development pipeline (mirrors the Kubernetes dev stack). |
44
47
  | [`lxd`](#underpost-lxd) | Manages LXD virtual machines as K3s nodes (control plane or workers). |
@@ -106,6 +109,7 @@ Builds client assets, single replicas, and/or syncs environment ports.
106
109
  | `--merge-zip <build-prefix>` | Merge split ZIP parts back into a single ZIP file for the given build prefix |
107
110
  | `--lite-build` | Skip full build (default is full build) |
108
111
  | `--icons-build` | Build icons |
112
+ | `--ssr` | Rebuild only SSR views defined in conf.ssr.json, leaving client assets untouched |
109
113
  | `-h, --help` | display help for command |
110
114
 
111
115
  ---
@@ -227,7 +231,7 @@ Manages commits to a GitHub repository, supporting various commit types and opti
227
231
  | `--has-changes` | Prints "1" if there are staged or unstaged git changes in the repository, empty string otherwise. |
228
232
  | `--remote-url` | Prints the current git remote URL (origin) in plain text. |
229
233
  | `--switch-repo <url>` | Switches the git remote (origin) to <url> and force-pulls the target branch, overwriting the current working tree (discards local commits and tracked changes). Accepts a full URL or "owner/repo". |
230
- | `--target-branch <branch>` | Target branch for --switch-repo (default: master). |
234
+ | `--target-branch <branch>` | Target branch for --switch-repo (default: remote default branch). |
231
235
  | `-h, --help` | display help for command |
232
236
 
233
237
  ---
@@ -389,6 +393,10 @@ Displays the current public machine IP addresses.
389
393
  | `--ban-egress-clear` | Clears all banned egress IP addresses. |
390
394
  | `--ban-both-add` | Adds IP addresses to both banned ingress and egress lists. |
391
395
  | `--ban-both-remove` | Removes IP addresses from both banned ingress and egress lists. |
396
+ | `--block-all-egress` | Blocks all outbound traffic from this host (keeps established/related connections). |
397
+ | `--unblock-all-egress` | Unblocks all outbound traffic and restores default ACCEPT policy. |
398
+ | `--block-all-ingress` | Blocks all new inbound traffic to this host (keeps established/related connections). |
399
+ | `--unblock-all-ingress` | Unblocks all inbound traffic and restores default ACCEPT policy. |
392
400
  | `--mac` | Prints the MAC address of the main network interface. |
393
401
  | `-h, --help` | display help for command |
394
402
 
@@ -678,18 +686,19 @@ Manages cron jobs: execute jobs directly or generate and apply K8s CronJob manif
678
686
 
679
687
  | Argument | Description |
680
688
  | --- | --- |
681
- | `deploy-list` | A comma-separated list of deployment IDs (e.g., "default-a,default-b"). |
682
- | `job-list` | A comma-separated list of job IDs. Options: dns,backup. Defaults to all available jobs. |
689
+ | `deploy-list` | A comma-separated list of deployment IDs (e.g., "default-a,default-b"). In manifest modes its first entry is the manifest owner deploy-id. |
690
+ | `job-list` | A comma-separated list of job IDs. Options: dns,backup,vultr. Defaults to all available jobs, and restricts which jobs are generated in manifest modes. |
683
691
 
684
692
  #### Options
685
693
 
686
694
  | Option | Description |
687
695
  | --- | --- |
688
696
  | `--generate-k8s-cronjobs` | Generates Kubernetes CronJob YAML manifests from cron configuration. |
689
- | `--apply` | Applies generated K8s CronJob manifests to the cluster via kubectl. |
690
- | `--setup-start [deploy-id]` | Updates deploy-id package.json start script and generates+applies its K8s CronJob manifests. |
697
+ | `--apply` | Generates and applies K8s CronJob manifests to the cluster via kubectl (never runs jobs). |
698
+ | `--setup-start` | Updates deploy-list package.json start script and generates+applies its K8s CronJob manifests. |
691
699
  | `--namespace <namespace>` | Kubernetes namespace for the CronJob resources (default: "default"). |
692
700
  | `--image <image>` | Custom container image for the CronJob pods. |
701
+ | `--node-name <node-name>` | Pins the CronJob pods to this node via a kubernetes.io/hostname nodeSelector. |
693
702
  | `--git` | Pass --git flag to cron job execution. |
694
703
  | `--cmd <cmd>` | Optional pre-script commands to run before cron execution. |
695
704
  | `--dev` | Use local ./ base path instead of global underpost installation. |
@@ -697,7 +706,7 @@ Manages cron jobs: execute jobs directly or generate and apply K8s CronJob manif
697
706
  | `--kind` | Use kind cluster context (apply via kind-worker container). |
698
707
  | `--kubeadm` | Use kubeadm cluster context (apply directly on host). |
699
708
  | `--dry-run` | Preview cron jobs without executing them. |
700
- | `--create-job-now` | After applying manifests, immediately create a Job from each CronJob (requires --apply). |
709
+ | `--create-job-now` | Creates a Job from each CronJob on the cluster now (implies manifest mode; combine with --apply to publish first). |
701
710
  | `-h, --help` | display help for command |
702
711
 
703
712
  ---
@@ -827,6 +836,127 @@ Manages SSH credentials and sessions for remote access to cluster nodes or servi
827
836
 
828
837
  ---
829
838
 
839
+ ### underpost wireguard
840
+
841
+ Manages the WireGuard L3 hub-and-spoke transport and the HAProxy edge gateway in front of it.
842
+
843
+ **Usage:** `underpost wireguard [options]`
844
+
845
+ #### Options
846
+
847
+ | Option | Description |
848
+ | --- | --- |
849
+ | `--deploy-id <deploy-id>` | Deploy IDs whose conf.server.json/conf.instances.json define the routes. Accepts one id or a comma-separated list; defaults to "dd", every deploy in dd.router, because the edge holds one pair of map files for the whole cluster. |
850
+ | `--interface <name>` | WireGuard interface name (default: "wg0"). |
851
+ | `--wireguard-install` | Installs the wireguard-tools, haproxy and iptables host packages. |
852
+ | `--wireguard-setup` | Generates keys, builds the interface config, and applies local network rules. |
853
+ | `--server` | Configures this node as the hub endpoint accepting inbound tunnel traffic. |
854
+ | `--client` | Configures this node as a spoke endpoint maintaining an outbound tunnel. |
855
+ | `--port <port>` | WireGuard UDP listening port (default: 51820). |
856
+ | `--cidr <cidr>` | Hub interface address with prefix when used with --server (e.g. "10.0.0.1/24"); the overlay subnet a spoke routes back through the hub when used with --client (default: "10.0.0.0/24"). |
857
+ | `--peer-ip <ip>` | Tunnel address of the target spoke. Required with --client and --peer-add. |
858
+ | `--endpoint <host:port>` | Hub host and port a spoke dials. Required with --client. |
859
+ | `--public-key <key>` | Hub public key with --client; spoke public key with --peer-add. |
860
+ | `--peer-add <peer-id>` | Registers a spoke and applies it to the running hub without a restart. |
861
+ | `--peer-remove <peer-id>` | Removes a spoke from the registry and from the running hub. |
862
+ | `--allowed-ips <cidrs>` | Comma-separated CIDRs routed to the spoke (e.g. "10.0.0.2/32,192.168.10.0/24"). |
863
+ | `--hosts <hosts>` | Comma-separated hostnames bound to the spoke, overriding instance resolution. |
864
+ | `--instances <instances>` | Comma-separated conf.instances.json ids bound to the spoke. |
865
+ | `--default` | Marks the spoke as the fallback for hostnames that match no other binding. |
866
+ | `--haproxy-setup` | Installs HAProxy, publishes the current routes, and enables the daemon. |
867
+ | `--haproxy-sync` | Recompiles the SNI/Host maps from deploy config and hot-reloads HAProxy. |
868
+ | `--status` | Prints the whole edge context without changing anything: role, interface, tunnel address, public key, daemon states, peers with their bindings and link health, and the resolved routing. |
869
+ | `--build-conf` | Writes only engine-private/deploy/conf.wireguard.json and touches no host state. Combine with --wireguard-setup / --peer-add / --peer-remove to author the topology off-box; alone it normalizes and validates the existing registry. |
870
+ | `--forward-proxy-server` | Ensures the hub HTTP/CONNECT forward proxy runs as the underpost-forward-proxy systemd service, bound to the tunnel address only (default port 1080), and returns. Authenticates every request with FORWARD_PROXY_API_KEY, so spokes can reach the internet through the VPS public address. Idempotent: re-running converges on the one service and restarts it only when the unit actually changed. |
871
+ | `--forward-proxy-server-host <host>` | Address the forward proxy binds, overriding the hub tunnel address from the registry. |
872
+ | `--forward-proxy-server-port <port>` | Port the forward proxy binds (default: 1080). |
873
+ | `--ssh-forward-port <port>` | Publishes the default spoke SSH port on this public TCP port of the hub, so CI with no fixed address can reach the cluster node (e.g. 2222). "0" closes it. Stored in the registry. |
874
+ | `--wireguard-start` | Enables and starts wg-quick@<interface> and the QUIC forward. |
875
+ | `--wireguard-stop` | Tears down the interface and removes its transient packet rules. |
876
+ | `--wireguard-reset` | Removes generated configs and packet rules, keeping the key pair and registry. |
877
+ | `--wireguard-reinstall` | Full purge, package reinstall and re-key; every spoke must re-register. |
878
+ | `--dry-run` | Prints the files and commands the run would apply, without touching the host. |
879
+ | `-h, --help` | display help for command |
880
+
881
+ ---
882
+
883
+ ### underpost haproxy
884
+
885
+ Manages the HAProxy edge gateway over the WireGuard transport (same subsystem as `underpost wireguard`).
886
+
887
+ **Usage:** `underpost haproxy [options]`
888
+
889
+ #### Options
890
+
891
+ | Option | Description |
892
+ | --- | --- |
893
+ | `--deploy-id <deploy-id>` | Deploy IDs whose conf.server.json/conf.instances.json define the routes. Accepts one id or a comma-separated list; defaults to "dd", every deploy in dd.router, because the edge holds one pair of map files for the whole cluster. |
894
+ | `--interface <name>` | WireGuard interface name (default: "wg0"). |
895
+ | `--wireguard-install` | Installs the wireguard-tools, haproxy and iptables host packages. |
896
+ | `--wireguard-setup` | Generates keys, builds the interface config, and applies local network rules. |
897
+ | `--server` | Configures this node as the hub endpoint accepting inbound tunnel traffic. |
898
+ | `--client` | Configures this node as a spoke endpoint maintaining an outbound tunnel. |
899
+ | `--port <port>` | WireGuard UDP listening port (default: 51820). |
900
+ | `--cidr <cidr>` | Hub interface address with prefix when used with --server (e.g. "10.0.0.1/24"); the overlay subnet a spoke routes back through the hub when used with --client (default: "10.0.0.0/24"). |
901
+ | `--peer-ip <ip>` | Tunnel address of the target spoke. Required with --client and --peer-add. |
902
+ | `--endpoint <host:port>` | Hub host and port a spoke dials. Required with --client. |
903
+ | `--public-key <key>` | Hub public key with --client; spoke public key with --peer-add. |
904
+ | `--peer-add <peer-id>` | Registers a spoke and applies it to the running hub without a restart. |
905
+ | `--peer-remove <peer-id>` | Removes a spoke from the registry and from the running hub. |
906
+ | `--allowed-ips <cidrs>` | Comma-separated CIDRs routed to the spoke (e.g. "10.0.0.2/32,192.168.10.0/24"). |
907
+ | `--hosts <hosts>` | Comma-separated hostnames bound to the spoke, overriding instance resolution. |
908
+ | `--instances <instances>` | Comma-separated conf.instances.json ids bound to the spoke. |
909
+ | `--default` | Marks the spoke as the fallback for hostnames that match no other binding. |
910
+ | `--haproxy-setup` | Installs HAProxy, publishes the current routes, and enables the daemon. |
911
+ | `--haproxy-sync` | Recompiles the SNI/Host maps from deploy config and hot-reloads HAProxy. |
912
+ | `--status` | Prints the whole edge context without changing anything: role, interface, tunnel address, public key, daemon states, peers with their bindings and link health, and the resolved routing. |
913
+ | `--build-conf` | Writes only engine-private/deploy/conf.wireguard.json and touches no host state. Combine with --wireguard-setup / --peer-add / --peer-remove to author the topology off-box; alone it normalizes and validates the existing registry. |
914
+ | `--forward-proxy-server` | Ensures the hub HTTP/CONNECT forward proxy runs as the underpost-forward-proxy systemd service, bound to the tunnel address only (default port 1080), and returns. Authenticates every request with FORWARD_PROXY_API_KEY, so spokes can reach the internet through the VPS public address. Idempotent: re-running converges on the one service and restarts it only when the unit actually changed. |
915
+ | `--forward-proxy-server-host <host>` | Address the forward proxy binds, overriding the hub tunnel address from the registry. |
916
+ | `--forward-proxy-server-port <port>` | Port the forward proxy binds (default: 1080). |
917
+ | `--ssh-forward-port <port>` | Publishes the default spoke SSH port on this public TCP port of the hub, so CI with no fixed address can reach the cluster node (e.g. 2222). "0" closes it. Stored in the registry. |
918
+ | `--wireguard-start` | Enables and starts wg-quick@<interface> and the QUIC forward. |
919
+ | `--wireguard-stop` | Tears down the interface and removes its transient packet rules. |
920
+ | `--wireguard-reset` | Removes generated configs and packet rules, keeping the key pair and registry. |
921
+ | `--wireguard-reinstall` | Full purge, package reinstall and re-key; every spoke must re-register. |
922
+ | `--dry-run` | Prints the files and commands the run would apply, without touching the host. |
923
+ | `-h, --help` | display help for command |
924
+
925
+ ---
926
+
927
+ ### underpost vultr
928
+
929
+ Meters the edge VPS bandwidth against its Vultr plan quota and blocks egress before overage accrues.
930
+
931
+ **Usage:** `underpost vultr [options] [deploy-list]`
932
+
933
+ #### Arguments
934
+
935
+ | Argument | Description |
936
+ | --- | --- |
937
+ | `deploy-list` | A comma-separated list of deployment IDs, logged for attribution. |
938
+
939
+ #### Options
940
+
941
+ | Option | Description |
942
+ | --- | --- |
943
+ | `--instance-id <instance-id>` | Vultr instance id to meter (default: VULTR_INSTANCE_ID). |
944
+ | `--api-key <api-key>` | Vultr API key (default: VULTR_API_KEY). Prefer the environment over this flag. |
945
+ | `--threshold <ratio>` | Fraction of the plan quota that triggers the egress block; "0.80" and "80" are both accepted (default: 0.80). |
946
+ | `--metric <metric>` | "total" (incoming + outgoing, default) or "outgoing" for egress alone. |
947
+ | `--month <yyyy-mm>` | Billing month to sum (default: the current UTC month). |
948
+ | `--all-dates` | Sum every daily bucket the API returns instead of scoping to one month. |
949
+ | `--host <ip>` | Edge VPS to block (default: VULTR_VPS_IP, then DEFAULT_SSH_HOST). |
950
+ | `--user <user>` | SSH user on the edge VPS (default: VULTR_SSH_USER, then DEFAULT_SSH_USER, then "root"). |
951
+ | `--key-path <path>` | SSH private key (default: VULTR_SSH_KEY_PATH, then DEFAULT_SSH_KEY_PATH). |
952
+ | `--port <port>` | SSH port on the edge VPS (default: VULTR_SSH_PORT, then DEFAULT_SSH_PORT, then 22). |
953
+ | `--force` | Re-apply the egress block even if it was already applied for this cycle. |
954
+ | `--auto-unblock` | Restore egress automatically once consumption falls back under the threshold. |
955
+ | `--dry-run` | Reports the consumption and the action it would take, without touching the edge VPS. |
956
+ | `-h, --help` | display help for command |
957
+
958
+ ---
959
+
830
960
  ### underpost run
831
961
 
832
962
  Runs specified scripts using various runners.
@@ -837,7 +967,7 @@ Runs specified scripts using various runners.
837
967
 
838
968
  | Argument | Description |
839
969
  | --- | --- |
840
- | `runner-id` | The runner ID to run. Options: status,expose,dev-cluster,metadata,ipfs-expose,svc-ls,svc-rm,node-move,dev-hosts-expose,dev-hosts-restore,cluster-build,template-deploy,template-deploy-local,docker-image,clean,pull,release-deploy,ssh-deploy,ide,crypto-policy,sync,stop,tz,get-traffic,restore-mongo,ingress-refresh,instance-promote,instance,deploy-key,instance-build-manifest,ls-deployments,host-update,install-crio,dd-container,ip-info,db-client,git-conf,promote,metrics,cluster,gateway-status,deploy,disk-clean,disk-devices,disk-usage,dev,service,etc-hosts,sh,log,ps,pid-info,background,ports,deploy-test,tf-vae-test,spark-template,pull-rocky-image,rmi,kill,generate-pass,sops-setup,sops-status,secret,underpost-config,gpu-env,tf-gpu-test,deploy-job,push-bundle,pull-bundle,build-cluster-deployment-manifests,monitor-ui,shared-dir,shared-dir-add-user. |
970
+ | `runner-id` | The runner ID to run. Options: status,expose,dev-cluster,metadata,ipfs-expose,svc-ls,svc-rm,node-move,dev-hosts-expose,dev-hosts-restore,cluster-build,template-deploy,template-deploy-local,docker-image,clean,pull,release-deploy,ssh-deploy,ide,crypto-policy,sync,stop,tz,get-traffic,restore-mongo,ingress-refresh,instance-promote,instance,deploy-key,instance-build-manifest,ls-deployments,host-update,install-crio,dd-container,ip-info,db-client,git-conf,promote,metrics,cluster,gateway-status,deploy,disk-clean,disk-devices,disk-usage,dev,service,etc-hosts,sh,log,ps,pid-info,background,ports,deploy-test,tf-vae-test,spark-template,pull-rocky-image,rmi,kill,generate-pass,sops-setup,sops-status,secret,underpost-config,gpu-env,tf-gpu-test,deploy-job,push-bundle,pull-bundle,kubeadm-wireguard,build-cluster-deployment-manifests,monitor-ui,shared-dir,shared-dir-add-user. |
841
971
  | `path` | The input value, identifier, or path for the operation. |
842
972
 
843
973
  #### Options
@@ -887,7 +1017,7 @@ Runs specified scripts using various runners.
887
1017
  | `--conf-server-path <conf-server-path>` | Sets a custom configuration server path. |
888
1018
  | `--underpost-root <underpost-root>` | Sets a custom Underpost root path. |
889
1019
  | `--cmd-cron-jobs <cmd-cron-jobs>` | Pre-script commands to run before cron job execution. |
890
- | `--deploy-id-cron-jobs <deploy-id-cron-jobs>` | Specifies deployment IDs to synchronize cron jobs with during execution. |
1020
+ | `--deploy-id-cron-jobs <deploy-id-cron-jobs>` | Cron deploy-id to set up during sync; defaults to dd.cron, "none" skips cron setup entirely. |
891
1021
  | `--timezone <timezone>` | Sets the timezone for the runner execution. |
892
1022
  | `--kubeadm` | Sets the kubeadm cluster context for the runner execution. |
893
1023
  | `--k3s` | Sets the k3s cluster context for the runner execution. |
package/Dockerfile CHANGED
@@ -6,7 +6,7 @@
6
6
  # Stage 1 — builder: clone the private deploy, build it, then scrub secrets.
7
7
  # ---------------------------------------------------------------------------
8
8
  FROM rockylinux/rockylinux:9 AS builder
9
- ARG UNDERPOST_VERSION=3.2.90
9
+ ARG UNDERPOST_VERSION=3.3.0
10
10
  # Pin Node to an exact patch: dnf's nodejs:24 module lags (24.14.1) while
11
11
  # underpost's dependencies require >=24.15.0, so install the official binary.
12
12
  ARG NODE_VERSION=24.15.0
package/Dockerfile.dev CHANGED
@@ -6,7 +6,7 @@
6
6
  # Stage 1 — builder: clone the private deploy, build it, then scrub secrets.
7
7
  # ---------------------------------------------------------------------------
8
8
  FROM rockylinux/rockylinux:9 AS builder
9
- ARG UNDERPOST_VERSION=3.2.90
9
+ ARG UNDERPOST_VERSION=3.3.0
10
10
  # Pin Node to an exact patch: dnf's nodejs:24 module lags (24.14.1) while
11
11
  # underpost's dependencies require >=24.15.0, so install the official binary.
12
12
  ARG NODE_VERSION=24.15.0
package/Dockerfile.test CHANGED
@@ -6,7 +6,7 @@
6
6
  # Stage 1 — builder: clone the private deploy, build it, then scrub secrets.
7
7
  # ---------------------------------------------------------------------------
8
8
  FROM rockylinux/rockylinux:9 AS builder
9
- ARG UNDERPOST_VERSION=3.2.90
9
+ ARG UNDERPOST_VERSION=3.3.0
10
10
  # Pin Node to an exact patch: dnf's nodejs:24 module lags (24.14.1) while
11
11
  # underpost's dependencies require >=24.15.0, so install the official binary.
12
12
  ARG NODE_VERSION=24.15.0
package/bin/build.js CHANGED
@@ -15,7 +15,6 @@ import {
15
15
  } from '../src/server/conf.js';
16
16
  import { loadDeployCatalog } from '../src/server/catalog.js';
17
17
  import Underpost from '../src/index.js';
18
- import { DOCKER_SCRIPTS } from '../src/api/cyberia-server-defaults/cyberia-server-defaults.js';
19
18
 
20
19
  const baseConfPath = './engine-private/conf/dd-cron/.env.production';
21
20
  if (fs.existsSync(baseConfPath)) dotenv.config({ path: baseConfPath, override: true });
@@ -114,6 +113,9 @@ const buildDeployTemplate = async (confName) => {
114
113
 
115
114
  switch (confName) {
116
115
  case 'dd-cyberia': {
116
+ const { CyberiaDependencies, DOCKER_SCRIPTS } = await import(
117
+ `../src/api/cyberia-server-defaults/cyberia-server-defaults.js`
118
+ );
117
119
  fs.copyFileSync(`./bin/cyberia.js`, `${basePath}/bin/cyberia.js`);
118
120
  fs.copyFileSync(
119
121
  `./.github/workflows/publish.cyberia.ci.yml`,
@@ -124,7 +126,6 @@ const buildDeployTemplate = async (confName) => {
124
126
  packageJson.bin.cyberia = 'bin/index.js';
125
127
  packageJson.keywords = catalog.keywords;
126
128
  packageJson.description = catalog.description;
127
- const { CyberiaDependencies } = await import(`../src/api/cyberia-server-defaults/cyberia-server-defaults.js`);
128
129
  packageJson.dependencies = {
129
130
  underpost: '^' + Underpost.version.replace('v', ''),
130
131
  'adm-zip': '^0.6.0',
@@ -155,9 +156,10 @@ const buildDeployTemplate = async (confName) => {
155
156
  JSON.stringify(packageJson, null, 4).replaceAll('pwa-microservices-template', repoName),
156
157
  'utf8',
157
158
  );
158
-
159
- fs.copySync(`./src/cli`, `${basePath}/src/cli`);
160
- if (!fs.existsSync(`${basePath}/images`)) fs.mkdirSync(`${basePath}/images`);
159
+ if (fs.existsSync(`./deploy/${confName}`))
160
+ fs.copySync(`./deploy/${confName}`, `${basePath}/deploy/${confName}`, {
161
+ overwrite: true,
162
+ });
161
163
 
162
164
  fs.copyFileSync(`./.github/workflows/${repoName}.ci.yml`, `${basePath}/.github/workflows/${repoName}.ci.yml`);
163
165
  if (fs.existsSync(`./.github/workflows/docker-image.${repoName}.ci.yml`))