Skip to content

Commit 594d3f9

Browse files
committedMar 5, 2025
License Checker for local WG
1 parent d64b930 commit 594d3f9

File tree

8 files changed

+269
-2
lines changed

8 files changed

+269
-2
lines changed
 

‎.env

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# os.getenv('APILOGICSERVER_DEBUG')
2+
# open created projects with this (e,g, code, charm)
3+
# Important - this does not override env variables, so you may need to set them too
4+
APILOGICSERVER_AUTO_OPEN=code
5+
6+
# lots of debug info (for runtime problem diagnosis)
7+
APILOGICSERVER_VERBOSE=false
8+
9+
# lots of debug info (for project creation diagnosis)
10+
APILOGICSERVER_DEBUG=false
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
# Include any files or directories that you don't want to be copied to your
2+
# container here (e.g., local build artifacts, temporary files, etc.).
3+
#
4+
# For more help, visit the .dockerignore file reference guide at
5+
# https://docs.docker.com/engine/reference/builder/#dockerignore-file
6+
7+
**/.DS_Store
8+
**/__pycache__
9+
**/.venv
10+
**/.classpath
11+
**/.dockerignore
12+
**/.env
13+
**/.git
14+
**/.gitignore
15+
**/.project
16+
**/.settings
17+
**/.toolstarget
18+
**/.vs
19+
**/.vscode
20+
**/*.*proj.user
21+
**/*.dbmdl
22+
**/*.jfm
23+
**/bin
24+
**/charts
25+
**/docker-compose*
26+
**/compose*
27+
**/Dockerfile*
28+
**/node_modules
29+
**/npm-debug.log
30+
**/obj
31+
**/secrets.dev.yaml
32+
**/values.dev.yaml
33+
LICENSE
34+
README.md
35+
# Compiled output
36+
/dist
37+
**/dist
38+
/tmp
39+
/out-tsc
40+
/bazel-out
41+
42+
# Node
43+
/node_modules
44+
**/node_modules/
45+
npm-debug.log
46+
yarn-error.log
47+
48+
# IDEs and editors
49+
.idea/
50+
.project
51+
.classpath
52+
.c9/
53+
*.launch
54+
.settings/
55+
*.sublime-workspace
56+
57+
# Visual Studio Code
58+
.vscode/*
59+
!.vscode/settings.json
60+
!.vscode/tasks.json
61+
!.vscode/launch.json
62+
!.vscode/extensions.json
63+
.history/*
64+
65+
# Miscellaneous
66+
/.angular/cache
67+
.sass-cache/
68+
/connect.lock
69+
/coverage
70+
/libpeerconnection.log
71+
testem.log
72+
/typings
73+
.git
74+
npm-debug.log
75+
.coverage
76+
.coverage.*
77+
.env
78+
79+
# System files
80+
.DS_Store
81+
Thumbs.db
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
# Include any files or directories that you don't want to be copied to your
2+
# container here (e.g., local build artifacts, temporary files, etc.).
3+
#
4+
# For more help, visit the .dockerignore file reference guide at
5+
# https://docs.docker.com/engine/reference/builder/#dockerignore-file
6+
7+
**/.DS_Store
8+
**/__pycache__
9+
**/.venv
10+
**/.classpath
11+
**/.dockerignore
12+
**/.env
13+
**/.git
14+
**/.gitignore
15+
**/.project
16+
**/.settings
17+
**/.toolstarget
18+
**/.vs
19+
**/.vscode
20+
**/*.*proj.user
21+
**/*.dbmdl
22+
**/*.jfm
23+
**/bin
24+
**/charts
25+
**/docker-compose*
26+
**/compose*
27+
**/Dockerfile*
28+
**/node_modules
29+
**/npm-debug.log
30+
**/obj
31+
**/secrets.dev.yaml
32+
**/values.dev.yaml
33+
LICENSE
34+
README.md
35+
# Compiled output
36+
/dist
37+
**/dist
38+
/tmp
39+
/out-tsc
40+
/bazel-out
41+
42+
# Node
43+
/node_modules
44+
**/node_modules/
45+
npm-debug.log
46+
yarn-error.log
47+
48+
# IDEs and editors
49+
.idea/
50+
.project
51+
.classpath
52+
.c9/
53+
*.launch
54+
.settings/
55+
*.sublime-workspace
56+
57+
# Visual Studio Code
58+
.vscode/*
59+
!.vscode/settings.json
60+
!.vscode/tasks.json
61+
!.vscode/launch.json
62+
!.vscode/extensions.json
63+
.history/*
64+
65+
# Miscellaneous
66+
/.angular/cache
67+
.sass-cache/
68+
/connect.lock
69+
/coverage
70+
/libpeerconnection.log
71+
testem.log
72+
/typings
73+
.git
74+
npm-debug.log
75+
.coverage
76+
.coverage.*
77+
.env
78+
79+
# System files
80+
.DS_Store
81+
Thumbs.db
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
# Include any files or directories that you don't want to be copied to your
2+
# container here (e.g., local build artifacts, temporary files, etc.).
3+
#
4+
# For more help, visit the .dockerignore file reference guide at
5+
# https://docs.docker.com/engine/reference/builder/#dockerignore-file
6+
7+
**/.DS_Store
8+
**/__pycache__
9+
**/.venv
10+
**/.classpath
11+
**/.dockerignore
12+
**/.env
13+
**/.git
14+
**/.gitignore
15+
**/.project
16+
**/.settings
17+
**/.toolstarget
18+
**/.vs
19+
**/.vscode
20+
**/*.*proj.user
21+
**/*.dbmdl
22+
**/*.jfm
23+
**/bin
24+
**/charts
25+
**/docker-compose*
26+
**/compose*
27+
**/Dockerfile*
28+
**/node_modules
29+
**/npm-debug.log
30+
**/obj
31+
**/secrets.dev.yaml
32+
**/values.dev.yaml
33+
LICENSE
34+
README.md
35+
# Compiled output
36+
/dist
37+
**/dist
38+
/tmp
39+
/out-tsc
40+
/bazel-out
41+
42+
# Node
43+
/node_modules
44+
**/node_modules/
45+
npm-debug.log
46+
yarn-error.log
47+
48+
# IDEs and editors
49+
.idea/
50+
.project
51+
.classpath
52+
.c9/
53+
*.launch
54+
.settings/
55+
*.sublime-workspace
56+
57+
# Visual Studio Code
58+
.vscode/*
59+
!.vscode/settings.json
60+
!.vscode/tasks.json
61+
!.vscode/launch.json
62+
!.vscode/extensions.json
63+
.history/*
64+
65+
# Miscellaneous
66+
/.angular/cache
67+
.sass-cache/
68+
/connect.lock
69+
/coverage
70+
/libpeerconnection.log
71+
testem.log
72+
/typings
73+
.git
74+
npm-debug.log
75+
.coverage
76+
.coverage.*
77+
.env
78+
79+
# System files
80+
.DS_Store
81+
Thumbs.db

‎docker/webgenie_docker/build_web_genie_local_license.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ if [ $# -eq 0 ]
3232
echo " Note: creates a folder at pwd: $webgen_ai_docker"
3333
echo " "
3434
echo " > cd ~/dev/ApiLogicServer/ApiLogicServer-dev/org_git/ApiLogicServer-src"
35-
echo " > sh docker/webgenie_docker/build_web_genie_local.sh local "
35+
echo " > sh docker/webgenie_docker/build_web_genie_local_license.sh local "
3636
echo " "
3737
exit 0
3838
fi

‎docker/webgenie_docker/webgen_ai_docker/arun.sh

+13
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,18 @@
33
# Start the webgenie admin interface
44
#
55

6+
function license_checker() {
7+
[[ -z ${LICENSE_CHECKER} ]] && return
8+
echo -e "${GREEN}License check enabled ${NC}"
9+
# Run the license checker script
10+
python ~/../license/license_checker.py -l
11+
if [[ $? -eq 1 ]]; then
12+
echo "License check failed, exiting..."
13+
pkill -P $$
14+
exit 1
15+
fi
16+
}
17+
618
function monitor() {
719
[[ -z ${MONITOR} ]] && return
820
# Run the monitor script to check project health
@@ -71,6 +83,7 @@ NC='\033[0m' # No Color
7183

7284
start_nginx
7385

86+
license_checker &
7487

7588
start_dev &
7689

‎docker/webgenie_docker/webgen_ai_docker/license/license.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@
22
"license_key": "ABCD-1234-EFGH-5678",
33
"license_type": "PRO",
44
"expiry": "2025-12-31",
5-
"signature": "ExPd5FL9VI6jOpDruwgBUF3knikbD9xAxNgq0Yneah0"
5+
"signature": "ExPd5FL9VI6jOpDruwgBUF3knikbD9xAxNgq0Yneah0="
66
}

‎docker/webgenie_docker/webgen_ai_docker/webgenie_local_license.Dockerfile

+1
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ RUN chmod 777 /run # TODO!! security issue?
3333

3434
RUN mkdir -p /opt/projects
3535
COPY webgenai/webgenai /opt/webgenai
36+
COPY arun.sh /opt/webgenai/arun.sh
3637
RUN cd /opt/webgenai/simple-spa && npm install
3738
RUN rm -fr /home/api_logic_server/api_logic_server_cli/create_from_model/safrs-react-admin-npm-build
3839
COPY sra/build /home/api_logic_server/api_logic_server_cli/create_from_model/safrs-react-admin-npm-build

0 commit comments

Comments
 (0)