underpost 2.8.799 → 2.8.812
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/.github/workflows/ghpkg.yml +23 -21
- package/.github/workflows/npmpkg.yml +16 -11
- package/.github/workflows/pwa-microservices-template.page.yml +12 -3
- package/.github/workflows/pwa-microservices-template.test.yml +20 -17
- package/.vscode/extensions.json +1 -2
- package/.vscode/settings.json +3 -0
- package/Dockerfile +14 -33
- package/README.md +25 -24
- package/bin/deploy.js +409 -112
- package/bin/vs.js +10 -3
- package/cli.md +331 -219
- package/docker-compose.yml +1 -1
- package/manifests/deployment/dd-template-development/deployment.yaml +18 -18
- package/manifests/lxd/underpost-setup.sh +1 -1
- package/manifests/maas/lxd-preseed.yaml +32 -0
- package/manifests/maas/maas-setup.sh +64 -0
- package/manifests/mariadb/statefulset.yaml +2 -1
- package/manifests/mariadb/storage-class.yaml +10 -0
- package/package.json +1 -1
- package/src/cli/baremetal.js +99 -0
- package/src/cli/cluster.js +14 -0
- package/src/cli/deploy.js +1 -1
- package/src/cli/env.js +2 -2
- package/src/cli/image.js +4 -3
- package/src/cli/index.js +244 -239
- package/src/index.js +9 -1
- package/src/runtime/lampp/Dockerfile +41 -47
- package/src/server/conf.js +58 -0
- package/supervisord-openssh-server.conf +0 -5
|
@@ -13,6 +13,8 @@ jobs:
|
|
|
13
13
|
if: github.repository == 'underpostnet/pwa-microservices-template' && startsWith(github.event.head_commit.message, 'ci(package-pwa-microservices-template-ghpkg)')
|
|
14
14
|
name: Update github repo package Jobs
|
|
15
15
|
runs-on: ubuntu-latest
|
|
16
|
+
container:
|
|
17
|
+
image: rockylinux/rockylinux:9
|
|
16
18
|
permissions:
|
|
17
19
|
contents: write
|
|
18
20
|
packages: write
|
|
@@ -20,9 +22,15 @@ jobs:
|
|
|
20
22
|
steps:
|
|
21
23
|
- uses: actions/checkout@v3
|
|
22
24
|
|
|
23
|
-
-
|
|
24
|
-
|
|
25
|
-
|
|
25
|
+
- name: Install required packages
|
|
26
|
+
run: |
|
|
27
|
+
dnf install -y sudo tar gzip bzip2 git
|
|
28
|
+
dnf install -y curl --allowerasing
|
|
29
|
+
|
|
30
|
+
- name: Install Node.js
|
|
31
|
+
run: |
|
|
32
|
+
curl -fsSL https://rpm.nodesource.com/setup_23.x | bash -
|
|
33
|
+
dnf install nodejs -y
|
|
26
34
|
|
|
27
35
|
# - name: Get npm root
|
|
28
36
|
# run: sudo npm root -g
|
|
@@ -47,31 +55,25 @@ jobs:
|
|
|
47
55
|
node ./bin/deploy rename-package @underpostnet/underpost
|
|
48
56
|
node ./bin/deploy set-repo underpostnet/pwa-microservices-template-ghpkg
|
|
49
57
|
|
|
50
|
-
- name:
|
|
51
|
-
run: |
|
|
52
|
-
underpost clone --bare underpostnet/pwa-microservices-template-ghpkg
|
|
53
|
-
rm -rf ./.git
|
|
54
|
-
cp -rf -a ./pwa-microservices-template-ghpkg.git ./.git
|
|
55
|
-
rm -rf ./pwa-microservices-template-ghpkg.git
|
|
56
|
-
|
|
57
|
-
- name: Set git credentials
|
|
58
|
+
- name: Set git global credentials
|
|
58
59
|
run: |
|
|
59
60
|
git config --global credential.helper ""
|
|
60
|
-
git config
|
|
61
|
-
git config --global user.
|
|
62
|
-
git config --global user.email 'development@underpost.net'
|
|
63
|
-
git config --global credential.interactive always
|
|
64
|
-
git config user.name 'underpostnet'
|
|
65
|
-
git config user.email 'development@underpost.net'
|
|
66
|
-
git config credential.interactive always
|
|
61
|
+
git config --global user.name 'underpost.net'
|
|
62
|
+
git config --global user.email 'admin@underpost.net'
|
|
67
63
|
|
|
68
|
-
- name: Push to github package repository
|
|
64
|
+
- name: Clone and Push to github package repository
|
|
69
65
|
run: |
|
|
66
|
+
underpost clone --bare underpostnet/pwa-microservices-template-ghpkg
|
|
67
|
+
rm -rf ./.git
|
|
68
|
+
mv ./pwa-microservices-template-ghpkg.git ./.git
|
|
70
69
|
pwd
|
|
70
|
+
git config --global --add safe.directory /__w/pwa-microservices-template/pwa-microservices-template
|
|
71
|
+
git remote set-url origin git@github.com:underpostnet/pwa-microservices-template-ghpkg.git
|
|
71
72
|
git init
|
|
73
|
+
git config user.name 'underpost.net'
|
|
74
|
+
git config user.email 'admin@underpost.net'
|
|
75
|
+
git add .
|
|
72
76
|
git status
|
|
73
|
-
git remote set-url origin git@github.com:underpostnet/pwa-microservices-template-ghpkg.git
|
|
74
|
-
git add .
|
|
75
77
|
underpost cmt . ci package-pwa-microservices-template-ghpkg 'Update github repo package'
|
|
76
78
|
underpost push . underpostnet/pwa-microservices-template-ghpkg
|
|
77
79
|
|
|
@@ -13,6 +13,8 @@ jobs:
|
|
|
13
13
|
if: github.repository == 'underpostnet/engine' && startsWith(github.event.head_commit.message, 'ci(package-pwa-microservices-template)')
|
|
14
14
|
name: Update npm repo package Jobs
|
|
15
15
|
runs-on: ubuntu-latest
|
|
16
|
+
container:
|
|
17
|
+
image: rockylinux/rockylinux:9
|
|
16
18
|
permissions:
|
|
17
19
|
contents: write
|
|
18
20
|
packages: write
|
|
@@ -20,9 +22,15 @@ jobs:
|
|
|
20
22
|
steps:
|
|
21
23
|
- uses: actions/checkout@v3
|
|
22
24
|
|
|
23
|
-
-
|
|
24
|
-
|
|
25
|
-
|
|
25
|
+
- name: Install required packages
|
|
26
|
+
run: |
|
|
27
|
+
dnf install -y sudo tar gzip bzip2 git
|
|
28
|
+
dnf install -y curl --allowerasing
|
|
29
|
+
|
|
30
|
+
- name: Install Node.js
|
|
31
|
+
run: |
|
|
32
|
+
curl -fsSL https://rpm.nodesource.com/setup_23.x | bash -
|
|
33
|
+
dnf install nodejs -y
|
|
26
34
|
|
|
27
35
|
- name: Install dependencies
|
|
28
36
|
run: |
|
|
@@ -30,16 +38,11 @@ jobs:
|
|
|
30
38
|
underpost config set GITHUB_TOKEN ${{ secrets.GIT_AUTH_TOKEN }}
|
|
31
39
|
npm install
|
|
32
40
|
|
|
33
|
-
- name: Set git credentials
|
|
41
|
+
- name: Set git global credentials
|
|
34
42
|
run: |
|
|
35
43
|
git config --global credential.helper ""
|
|
36
|
-
git config
|
|
37
|
-
git config --global user.
|
|
38
|
-
git config --global user.email 'development@underpost.net'
|
|
39
|
-
git config --global credential.interactive always
|
|
40
|
-
git config user.name 'underpostnet'
|
|
41
|
-
git config user.email 'development@underpost.net'
|
|
42
|
-
git config credential.interactive always
|
|
44
|
+
git config --global user.name 'underpost.net'
|
|
45
|
+
git config --global user.email 'admin@underpost.net'
|
|
43
46
|
|
|
44
47
|
- name: Clone github package repository
|
|
45
48
|
run: |
|
|
@@ -49,6 +52,8 @@ jobs:
|
|
|
49
52
|
cd ../pwa-microservices-template
|
|
50
53
|
git remote set-url origin git@github.com:underpostnet/pwa-microservices-template.git
|
|
51
54
|
git add .
|
|
55
|
+
git config user.name 'underpost.net'
|
|
56
|
+
git config user.email 'admin@underpost.net'
|
|
52
57
|
underpost cmt . ci package-pwa-microservices-template-ghpkg 'Update npm repo package'
|
|
53
58
|
underpost push . underpostnet/pwa-microservices-template
|
|
54
59
|
# cd ../engine
|
|
@@ -29,6 +29,8 @@ jobs:
|
|
|
29
29
|
name: github-pages
|
|
30
30
|
url: ${{ steps.deployment.outputs.page_url }}
|
|
31
31
|
runs-on: ubuntu-latest
|
|
32
|
+
container:
|
|
33
|
+
image: rockylinux/rockylinux:9
|
|
32
34
|
steps:
|
|
33
35
|
- name: Checkout
|
|
34
36
|
uses: actions/checkout@v4
|
|
@@ -36,9 +38,16 @@ jobs:
|
|
|
36
38
|
# lfs: true
|
|
37
39
|
# - name: Checkout LFS objects
|
|
38
40
|
# run: git lfs checkout
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
41
|
+
|
|
42
|
+
- name: Install required packages
|
|
43
|
+
run: |
|
|
44
|
+
dnf install -y sudo tar gzip bzip2 git
|
|
45
|
+
dnf install -y curl --allowerasing
|
|
46
|
+
|
|
47
|
+
- name: Install Node.js
|
|
48
|
+
run: |
|
|
49
|
+
curl -fsSL https://rpm.nodesource.com/setup_23.x | bash -
|
|
50
|
+
dnf install nodejs -y
|
|
42
51
|
|
|
43
52
|
- name: Build the site
|
|
44
53
|
run: |
|
|
@@ -1,30 +1,33 @@
|
|
|
1
1
|
name: Test
|
|
2
|
+
|
|
2
3
|
on: [push]
|
|
4
|
+
|
|
3
5
|
jobs:
|
|
4
6
|
test:
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
node-version: [23.x]
|
|
11
|
-
os: [ubuntu-latest]
|
|
12
|
-
# os: [ubuntu-latest, windows-latest]
|
|
13
|
-
|
|
7
|
+
name: Template Test
|
|
8
|
+
runs-on: ubuntu-latest
|
|
9
|
+
container:
|
|
10
|
+
image: rockylinux/rockylinux:9
|
|
11
|
+
options: --entrypoint /bin/bash
|
|
14
12
|
steps:
|
|
15
13
|
- name: Clone repository
|
|
16
14
|
uses: actions/checkout@v3
|
|
17
15
|
|
|
18
|
-
- name:
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
16
|
+
- name: Install required packages
|
|
17
|
+
run: |
|
|
18
|
+
dnf install -y sudo tar gzip bzip2 git
|
|
19
|
+
dnf install -y curl --allowerasing
|
|
20
|
+
|
|
21
|
+
- name: Install Node.js
|
|
22
|
+
run: |
|
|
23
|
+
curl -fsSL https://rpm.nodesource.com/setup_23.x | bash -
|
|
24
|
+
dnf install nodejs -y
|
|
22
25
|
|
|
23
26
|
- name: Get npm root
|
|
24
|
-
run:
|
|
27
|
+
run: npm root -g
|
|
25
28
|
|
|
26
|
-
- name: Install underpost
|
|
27
|
-
run:
|
|
29
|
+
- name: Install underpost CLI
|
|
30
|
+
run: npm install -g underpost
|
|
28
31
|
|
|
29
32
|
- name: Run test
|
|
30
|
-
run:
|
|
33
|
+
run: underpost test
|
package/.vscode/extensions.json
CHANGED
|
@@ -10,11 +10,9 @@
|
|
|
10
10
|
"github.codespaces",
|
|
11
11
|
"github.vscode-github-actions",
|
|
12
12
|
"golang.go",
|
|
13
|
-
"google.geminicodeassist",
|
|
14
13
|
"gruntfuggly.todo-tree",
|
|
15
14
|
"mechatroner.rainbow-csv",
|
|
16
15
|
"mindaro-dev.file-downloader",
|
|
17
|
-
"mindaro.mindaro",
|
|
18
16
|
"ms-azuretools.vscode-containers",
|
|
19
17
|
"ms-azuretools.vscode-docker",
|
|
20
18
|
"ms-kubernetes-tools.vscode-kubernetes-tools",
|
|
@@ -22,6 +20,7 @@
|
|
|
22
20
|
"ms-python.debugpy",
|
|
23
21
|
"ms-python.python",
|
|
24
22
|
"ms-python.vscode-pylance",
|
|
23
|
+
"ms-vscode-remote.remote-containers",
|
|
25
24
|
"oderwat.indent-rainbow",
|
|
26
25
|
"pleiades.java-extension-pack-jdk",
|
|
27
26
|
"ravioshankar.scala-gurus",
|
package/.vscode/settings.json
CHANGED
package/Dockerfile
CHANGED
|
@@ -1,47 +1,28 @@
|
|
|
1
|
-
|
|
1
|
+
FROM rockylinux:9
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
RUN dnf install -y --allowerasing bzip2
|
|
4
|
+
RUN dnf clean all
|
|
4
5
|
|
|
5
|
-
FROM debian:${BASE_DEBIAN}
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
# Install Node.js
|
|
8
|
+
RUN curl -fsSL https://rpm.nodesource.com/setup_23.x | bash -
|
|
9
|
+
RUN dnf install nodejs -y
|
|
10
|
+
RUN dnf clean all
|
|
8
11
|
|
|
9
|
-
#
|
|
10
|
-
RUN echo 'root:root' | chpasswd
|
|
11
|
-
|
|
12
|
-
RUN apt-get update --fix-missing
|
|
13
|
-
RUN apt-get upgrade -y
|
|
14
|
-
# install sudo
|
|
15
|
-
RUN apt-get -y install sudo
|
|
16
|
-
# net-tools provides netstat commands
|
|
17
|
-
RUN apt-get -y install curl net-tools
|
|
18
|
-
RUN apt-get -yq install openssh-server supervisor
|
|
19
|
-
# Few handy utilities which are nice to have
|
|
20
|
-
RUN apt-get -y install nano vim less --no-install-recommends
|
|
21
|
-
RUN apt-get clean
|
|
22
|
-
|
|
23
|
-
# install ssh
|
|
24
|
-
RUN mkdir -p /var/run/sshd
|
|
25
|
-
# Allow root login via password
|
|
26
|
-
RUN sed -ri 's/#PermitRootLogin prohibit-password/PermitRootLogin yes/g' /etc/ssh/sshd_config
|
|
27
|
-
|
|
28
|
-
# install open ssl git and others tools
|
|
29
|
-
RUN apt-get install -yq --no-install-recommends libssl-dev curl wget git gnupg
|
|
30
|
-
|
|
31
|
-
# install nodejs https://github.com/nodesource/distributions/blob/master/README.md#deb
|
|
32
|
-
RUN curl -fsSL https://deb.nodesource.com/setup_23.x | bash -
|
|
33
|
-
RUN apt-get install -y nodejs build-essential
|
|
12
|
+
# Verify Node.js and npm versions
|
|
34
13
|
RUN node --version
|
|
35
14
|
RUN npm --version
|
|
36
15
|
|
|
16
|
+
# Install underpost ci/cd cli
|
|
17
|
+
RUN npm install -g underpost
|
|
18
|
+
RUN underpost --version
|
|
19
|
+
|
|
20
|
+
# Set working directory
|
|
37
21
|
WORKDIR /home/dd
|
|
38
22
|
|
|
23
|
+
# Expose necessary ports
|
|
39
24
|
EXPOSE 22
|
|
40
|
-
|
|
41
25
|
EXPOSE 80
|
|
42
|
-
|
|
43
26
|
EXPOSE 443
|
|
44
|
-
|
|
45
27
|
EXPOSE 3000-3100
|
|
46
|
-
|
|
47
28
|
EXPOSE 4000-4100
|
package/README.md
CHANGED
|
@@ -16,7 +16,7 @@ template
|
|
|
16
16
|
|
|
17
17
|
<div align="center">
|
|
18
18
|
|
|
19
|
-
<a target="_top" href='https://www.npmjs.com/package/npm/v/11.1.0' ><img alt='npm' src='https://img.shields.io/badge/npm v11.1.0-100000?style=flat&logo=npm&logoColor=white&labelColor=CB3837&color=727273'/></a> <a target="_top" href='https://nodejs.org/download/release/v22.9.0/' ><img alt='nodedotjs' src='https://img.shields.io/badge/node v23.8.0-100000?style=flat&logo=nodedotjs&logoColor=white&labelColor=5FA04E&color=727273'/></a> <a target="_top" href='https://pgp.mongodb.com/' ><img alt='mongodb' src='https://img.shields.io/badge/mongodb_server v7.0-100000?style=flat&logo=mongodb&logoColor=white&labelColor=47A248&color=727273'/></a>
|
|
19
|
+
<a target="_top" href='https://rockylinux.org/download'><img alt='rockylinux' src='https://img.shields.io/badge/Rocky Linux v9.6-100000?style=flat&logo=rockylinux&logoColor=white&labelColor=10b981&color=727273'/></a> <a target="_top" href='https://www.npmjs.com/package/npm/v/11.1.0' ><img alt='npm' src='https://img.shields.io/badge/npm v11.1.0-100000?style=flat&logo=npm&logoColor=white&labelColor=CB3837&color=727273'/></a> <a target="_top" href='https://nodejs.org/download/release/v22.9.0/' ><img alt='nodedotjs' src='https://img.shields.io/badge/node v23.8.0-100000?style=flat&logo=nodedotjs&logoColor=white&labelColor=5FA04E&color=727273'/></a> <a target="_top" href='https://pgp.mongodb.com/' ><img alt='mongodb' src='https://img.shields.io/badge/mongodb_server v7.0-100000?style=flat&logo=mongodb&logoColor=white&labelColor=47A248&color=727273'/></a>
|
|
20
20
|
|
|
21
21
|
</div>
|
|
22
22
|
|
|
@@ -68,7 +68,7 @@ Run dev client server
|
|
|
68
68
|
npm run dev
|
|
69
69
|
```
|
|
70
70
|
<!-- -->
|
|
71
|
-
## underpost ci/cd cli v2.8.
|
|
71
|
+
## underpost ci/cd cli v2.8.812
|
|
72
72
|
|
|
73
73
|
### Usage: `underpost [options] [command]`
|
|
74
74
|
```
|
|
@@ -77,28 +77,29 @@ npm run dev
|
|
|
77
77
|
-h, --help display help for command
|
|
78
78
|
|
|
79
79
|
Commands:
|
|
80
|
-
new <app-name>
|
|
81
|
-
start [options] <deploy-id> [env]
|
|
82
|
-
clone [options] <uri>
|
|
83
|
-
pull [options] <path> <uri>
|
|
84
|
-
cmt [options] <path> <commit-type> [module-tag] [message]
|
|
85
|
-
push [options] <path> <uri>
|
|
86
|
-
env <deploy-id> [env]
|
|
87
|
-
config <operator> [key] [value]
|
|
88
|
-
root
|
|
89
|
-
cluster [options] [pod-name]
|
|
90
|
-
deploy [options] [deploy-list] [env]
|
|
91
|
-
secret [options] <platform>
|
|
92
|
-
dockerfile-image-build [options]
|
|
93
|
-
dockerfile-pull-base-images [options]
|
|
94
|
-
install
|
|
95
|
-
db [options] <deploy-list>
|
|
96
|
-
script [options] <operator> <script-name> [script-value] Supports a
|
|
97
|
-
cron [options] [deploy-list] [job-list]
|
|
98
|
-
fs [options] [path]
|
|
99
|
-
test [options] [deploy-list]
|
|
100
|
-
monitor [options] <deploy-id> [env]
|
|
101
|
-
lxd [options]
|
|
80
|
+
new <app-name> Initializes a new Underpost project with a predefined structure.
|
|
81
|
+
start [options] <deploy-id> [env] Initiates application servers, build pipelines, or other defined services based on the deployment ID.
|
|
82
|
+
clone [options] <uri> Clones a specified GitHub repository into the current directory.
|
|
83
|
+
pull [options] <path> <uri> Pulls the latest changes from a specified GitHub repository.
|
|
84
|
+
cmt [options] <path> <commit-type> [module-tag] [message] Manages commits to a GitHub repository, supporting various commit types and options.
|
|
85
|
+
push [options] <path> <uri> Pushes committed changes from a local repository to a remote GitHub repository.
|
|
86
|
+
env <deploy-id> [env] Sets environment variables and configurations related to a specific deployment ID.
|
|
87
|
+
config [options] <operator> [key] [value] Manages Underpost configurations using various operators.
|
|
88
|
+
root Displays the root path of the npm installation.
|
|
89
|
+
cluster [options] [pod-name] Manages Kubernetes clusters, defaulting to Kind cluster initialization.
|
|
90
|
+
deploy [options] [deploy-list] [env] Manages application deployments, defaulting to deploying development pods.
|
|
91
|
+
secret [options] <platform> Manages secrets for various platforms.
|
|
92
|
+
dockerfile-image-build [options] Builds a Docker image from a specified Dockerfile with various options for naming, saving, and loading.
|
|
93
|
+
dockerfile-pull-base-images [options] Pulls required Underpost Dockerfile base images and optionally loads them into clusters.
|
|
94
|
+
install Quickly imports Underpost npm dependencies by copying them.
|
|
95
|
+
db [options] <deploy-list> Manages database operations, including import, export, and collection management.
|
|
96
|
+
script [options] <operator> <script-name> [script-value] Supports a variety of built-in Underpost global scripts, their preset lifecycle events, and arbitrary custom scripts.
|
|
97
|
+
cron [options] [deploy-list] [job-list] Manages cron jobs, including initialization, execution, and configuration updates.
|
|
98
|
+
fs [options] [path] Manages file storage, defaulting to file upload operations.
|
|
99
|
+
test [options] [deploy-list] Manages and runs tests, defaulting to the current Underpost default test suite.
|
|
100
|
+
monitor [options] <deploy-id> [env] Manages health server monitoring for specified deployments.
|
|
101
|
+
lxd [options] Manages LXD containers and virtual machines.
|
|
102
|
+
baremetal [options] Manages baremetal server operations, including installation, database setup, and user management.
|
|
102
103
|
help [command] display help for command
|
|
103
104
|
|
|
104
105
|
```
|