Skip to content

Commit ec53bef

Browse files
authored
Merge branch 'lowcoder-org:main' into patch-2
2 parents 0c24108 + 081f9f9 commit ec53bef

File tree

25 files changed

+234
-91
lines changed

25 files changed

+234
-91
lines changed

app.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@
2727
"description": "The domains supported for CORS requests. All domains are allowed by default. If there are multiple domains, please separate them with commas.",
2828
"required": false
2929
},
30-
"MONGODB_URI": {
31-
"description": "Your Mongo Database URI.",
30+
"MONGODB_URL": {
31+
"description": "Your Mongo Database URL.",
3232
"required": false
3333
},
3434
"REDIS_URL": {

deploy/docker/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ FROM ubuntu:jammy as build-node-service
6969
RUN apt update && DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -y curl ca-certificates
7070

7171
# Download nodejs and install yarn
72-
RUN curl -sL https://deb.nodesource.com/setup_20.x | bash - \
72+
RUN curl -sL https://deb.nodesource.com/setup_19.x | bash - \
7373
&& apt-get install --no-install-recommends -y nodejs \
7474
&& npm install -g yarn
7575

@@ -94,7 +94,7 @@ FROM ubuntu:jammy as lowcoder-ce-node-service
9494
LABEL maintainer="lowcoder"
9595

9696
RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -y curl ca-certificates \
97-
&& curl -sL https://deb.nodesource.com/setup_20.x | bash - \
97+
&& curl -sL https://deb.nodesource.com/setup_19.x | bash - \
9898
&& apt-get install --no-install-recommends -y nodejs gosu \
9999
&& npm install -g yarn \
100100
&& rm -rf /var/cache/apt/lists \
@@ -166,7 +166,7 @@ RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install --no-instal
166166
&& echo "deb [signed-by=/usr/share/keyrings/redis-archive-keyring.gpg] https://packages.redis.io/deb bullseye main" | tee /etc/apt/sources.list.d/redis.list \
167167
&& curl -fsSL https://www.mongodb.org/static/pgp/server-4.4.asc | gpg --dearmor -o /usr/share/keyrings/mongodb-archive-keyring.gpg \
168168
&& echo "deb [signed-by=/usr/share/keyrings/mongodb-archive-keyring.gpg arch=amd64,arm64] http://repo.mongodb.org/apt/ubuntu focal/mongodb-org/4.4 multiverse" | tee /etc/apt/sources.list.d/mongodb-org-4.4.list \
169-
&& curl -sL https://deb.nodesource.com/setup_20.x | bash - \
169+
&& curl -sL https://deb.nodesource.com/setup_19.x | bash - \
170170
&& apt-get update && DEBIAN_FRONTEND=noninteractive apt-get -y install --no-install-recommends -y \
171171
mongodb-org \
172172
redis \

deploy/docker/README.md

Lines changed: 37 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -21,24 +21,28 @@ DOCKER_BUILDKIT=1 docker build -f deploy/docker/Dockerfile -t lowcoderorg/lowcod
2121

2222
Image can be configured by setting environment variables.
2323

24-
| Environment variable | Description | Value |
25-
| --------------------------------| --------------------------------------------------------------------| ------------------------------------------------------- |
26-
| `REDIS_ENABLED` | If **true** redis server is started in the container | `true` |
27-
| `MONGODB_ENABLED` | If **true** mongo database is started in the container | `true` |
28-
| `API_SERVICE_ENABLED` | If **true** lowcoder api-service is started in the container | `true` |
29-
| `NODE_SERVICE_ENABLED` | If **true** lowcoder node-service is started in the container | `true` |
30-
| `FRONTEND_ENABLED` | If **true** lowcoder web frontend is started in the container | `true` |
31-
| `PUID` | ID of user running services. It will own all created logs and data. | `9001` |
32-
| `PGID` | ID of group of the user running services. | `9001` |
33-
| `MONGODB_URI` | Mongo database connection string | `mongodb://localhost:27017/lowcoder?authSource=admin` |
34-
| `REDIS_URL` | Redis server URL | `redis://localhost:6379` |
35-
| `JS_EXECUTOR_URI` | Node service URL | `http://localhost:6060` |
36-
| `ENABLE_USER_SIGN_UP` | Enable registration of new users | `true` |
24+
| Environment variable | Description | Value |
25+
| --------------------------------| --------------------------------------------------------------------| ----------------------------------------------------- |
26+
| `REDIS_ENABLED` | If **true** redis server is started in the container | `true` |
27+
| `MONGODB_ENABLED` | If **true** mongo database is started in the container | `true` |
28+
| `API_SERVICE_ENABLED` | If **true** lowcoder api-service is started in the container | `true` |
29+
| `NODE_SERVICE_ENABLED` | If **true** lowcoder node-service is started in the container | `true` |
30+
| `FRONTEND_ENABLED` | If **true** lowcoder web frontend is started in the container | `true` |
31+
| `PUID` | ID of user running services. It will own all created logs and data. | `9001` |
32+
| `PGID` | ID of group of the user running services. | `9001` |
33+
| `MONGODB_URL` | Mongo database connection string | `mongodb://localhost:27017/lowcoder?authSource=admin` |
34+
| `REDIS_URL` | Redis server URL | `redis://localhost:6379` |
35+
| `ENABLE_USER_SIGN_UP` | Enable registration of new users | `true` |
3736
| `ENCRYPTION_PASSWORD` | Encryption password | `lowcoder.org` |
3837
| `ENCRYPTION_SALT` | Salt used for encrypting password | `lowcoder.org` |
39-
| `CORS_ALLOWED_DOMAINS` | CORS allowed domains | `*` |
40-
| `LOWCODER_API_SERVICE_URL` | Lowcoder API service URL | `http://localhost:8080` |
41-
| `LOWCODER_NODE_SERVICE_URL` | Lowcoder Node service (js executor) URL | `http://localhost:6060` |
38+
| `CORS_ALLOWED_DOMAINS` | CORS allowed domains | `*` |
39+
| `LOWCODER_API_SERVICE_URL` | Lowcoder API service URL | `http://localhost:8080` |
40+
| `LOWCODER_NODE_SERVICE_URL` | Lowcoder Node service (js executor) URL | `http://localhost:6060` |
41+
| `DEFAULT_ORGS_PER_USER` | Default maximum organizations per user | `100` |
42+
| `DEFAULT_ORG_MEMBER_COUNT` | Default maximum members per organization | `1000` |
43+
| `DEFAULT_ORG_GROUP_COUNT` | Default maximum groups per organization | `100` |
44+
| `DEFAULT_ORG_APP_COUNT` | Default maximum applications per organization | `1000` |
45+
| `DEFAULT_DEVELOPER_COUNT` | Default maximum developers | `100` |
4246

4347

4448
## Building api-service image
@@ -57,17 +61,22 @@ DOCKER_BUILDKIT=1 docker build -f deploy/docker/Dockerfile -t lowcoderorg/lowcod
5761

5862
Image can be configured by setting environment variables.
5963

60-
| Environment variable | Description | Value |
61-
| --------------------------------| --------------------------------------------------------------------| ------------------------------------------------------- |
62-
| `PUID` | ID of user running services. It will own all created logs and data. | `9001` |
63-
| `PGID` | ID of group of the user running services. | `9001` |
64-
| `MONGODB_URI` | Mongo database connection string | `mongodb://localhost:27017/lowcoder?authSource=admin` |
65-
| `REDIS_URL` | Redis server URL | `redis://localhost:6379` |
66-
| `JS_EXECUTOR_URI` | Node service URL | `http://localhost:6060` |
67-
| `ENABLE_USER_SIGN_UP` | Enable registration of new users | `true` |
64+
| Environment variable | Description | Value |
65+
| --------------------------------| --------------------------------------------------------------------| ------------------------------------------------------|
66+
| `PUID` | ID of user running services. It will own all created logs and data. | `9001` |
67+
| `PGID` | ID of group of the user running services. | `9001` |
68+
| `MONGODB_URL` | Mongo database connection string | `mongodb://localhost:27017/lowcoder?authSource=admin` |
69+
| `REDIS_URL` | Redis server URL | `redis://localhost:6379` |
70+
| `ENABLE_USER_SIGN_UP` | Enable registration of new users | `true` |
6871
| `ENCRYPTION_PASSWORD` | Encryption password | `lowcoder.org` |
6972
| `ENCRYPTION_SALT` | Salt used for encrypting password | `lowcoder.org` |
70-
| `CORS_ALLOWED_DOMAINS` | CORS allowed domains | `*` |
73+
| `CORS_ALLOWED_DOMAINS` | CORS allowed domains | `*` |
74+
| `DEFAULT_ORGS_PER_USER` | Default maximum organizations per user | `100` |
75+
| `DEFAULT_ORG_MEMBER_COUNT` | Default maximum members per organization | `1000` |
76+
| `DEFAULT_ORG_GROUP_COUNT` | Default maximum groups per organization | `100` |
77+
| `DEFAULT_ORG_APP_COUNT` | Default maximum applications per organization | `1000` |
78+
| `DEFAULT_DEVELOPER_COUNT` | Default maximum developers | `100` |
79+
7180

7281

7382
## Building node-service image
@@ -90,7 +99,7 @@ Image can be configured by setting environment variables.
9099
| --------------------------------| --------------------------------------------------------------------| ------------------------------------------------------- |
91100
| `PUID` | ID of user running services. It will own all created logs and data. | `9001` |
92101
| `PGID` | ID of group of the user running services. | `9001` |
93-
| `LOWCODER_API_SERVICE_URL` | Lowcoder API service URL | `http://localhost:8080` |
102+
| `LOWCODER_API_SERVICE_URL` | Lowcoder API service URL | `http://localhost:8080` |
94103

95104
## Building web frontend image
96105

@@ -112,7 +121,7 @@ Image can be configured by setting environment variables.
112121
| --------------------------------| --------------------------------------------------------------------| ------------------------------------------------------- |
113122
| `PUID` | ID of user running services. It will own all created logs and data. | `9001` |
114123
| `PGID` | ID of group of the user running services. | `9001` |
115-
| `LOWCODER_API_SERVICE_URL` | Lowcoder API service URL | `http://localhost:8080` |
116-
| `LOWCODER_NODE_SERVICE_URL` | Lowcoder Node service (js executor) URL | `http://localhost:6060` |
124+
| `LOWCODER_API_SERVICE_URL` | Lowcoder API service URL | `http://localhost:8080` |
125+
| `LOWCODER_NODE_SERVICE_URL` | Lowcoder Node service (js executor) URL | `http://localhost:6060` |
117126

118127

deploy/docker/docker-compose-multi.yaml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,13 +33,18 @@ services:
3333
environment:
3434
PUID: "9001"
3535
PGID: "9001"
36-
MONGODB_URI: "mongodb://lowcoder:secret123@mongodb/lowcoder?authSource=admin"
36+
MONGODB_URL: "mongodb://lowcoder:secret123@mongodb/lowcoder?authSource=admin"
3737
REDIS_URL: "redis://redis:6379"
38-
JS_EXECUTOR_URI: "http://lowcoder-node-service:6060"
38+
LOWCODER_NODE_SERVICE_URL: "http://lowcoder-node-service:6060"
3939
ENABLE_USER_SIGN_UP: "true"
4040
ENCRYPTION_PASSWORD: "lowcoder.org"
4141
ENCRYPTION_SALT: "lowcoder.org"
4242
CORS_ALLOWED_DOMAINS: "*"
43+
DEFAULT_ORGS_PER_USER: 100
44+
DEFAULT_ORG_MEMBER_COUNT: 1000
45+
DEFAULT_ORG_GROUP_COUNT: 100
46+
DEFAULT_ORG_APP_COUNT: 1000
47+
DEFAULT_DEVELOPER_COUNT: 50
4348
restart: unless-stopped
4449
depends_on:
4550
- mongodb

deploy/docker/docker-compose.yaml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,14 @@ services:
2020
PUID: "1000"
2121
PGID: "1000"
2222
# api-service parameters
23-
#MONGODB_URI: "mongodb://lowcoder:secret123@mongodb/lowcoder?authSource=admin"
24-
MONGODB_URI: "mongodb://localhost:27017/lowcoder?authSource=admin"
23+
DEFAULT_ORGS_PER_USER: 100
24+
DEFAULT_ORG_MEMBER_COUNT: 1000
25+
DEFAULT_ORG_GROUP_COUNT: 100
26+
DEFAULT_ORG_APP_COUNT: 1000
27+
DEFAULT_DEVELOPER_COUNT: 50
28+
#MONGODB_URL: "mongodb://lowcoder:secret123@mongodb/lowcoder?authSource=admin"
29+
MONGODB_URL: "mongodb://localhost:27017/lowcoder?authSource=admin"
2530
REDIS_URL: "redis://localhost:6379"
26-
JS_EXECUTOR_URI: "http://localhost:6060"
2731
ENABLE_USER_SIGN_UP: "true"
2832
ENCRYPTION_PASSWORD: "lowcoder.org"
2933
ENCRYPTION_SALT: "lowcoder.org"

deploy/helm/templates/api-service/configMap.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,9 @@ data:
1818
REDIS_URL: {{- .Values.redis.externalUrl | quote }}
1919
{{- end }}
2020
{{- if .Values.apiService.nodeServiceUrl }}
21-
JS_EXECUTOR_URI: {{ .Values.apiService.nodeServiceUrl | quote }}
21+
LOWCODER_NODE_SERVICE_URL: {{ .Values.apiService.nodeServiceUrl | quote }}
2222
{{- else }}
23-
JS_EXECUTOR_URI: "http://{{ $name }}-node-service:{{ .Values.nodeService.service.port }}"
23+
LOWCODER_NODE_SERVICE_URL: "http://{{ $name }}-node-service:{{ .Values.nodeService.service.port }}"
2424
{{- end }}
2525
PUID: {{ .Values.apiService.config.userId | default "9001" | quote }}
2626
PGID: {{ .Values.apiService.config.groupId | default "9001" | quote }}

deploy/helm/templates/api-service/secrets.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@ metadata:
1616
{{- end }}
1717
stringData:
1818
{{- if .Values.mongodb.enabled }}
19-
MONGODB_URI: "mongodb://{{ $mongoUser }}:{{ $mongoPassword }}@{{ $mongoServicename }}.{{ $nameSpace }}.svc.cluster.local/{{ $lowcoderDatabase }}?retryWrites=true&ssl=false"
19+
MONGODB_URL: "mongodb://{{ $mongoUser }}:{{ $mongoPassword }}@{{ $mongoServicename }}.{{ $nameSpace }}.svc.cluster.local/{{ $lowcoderDatabase }}?retryWrites=true&ssl=false"
2020
{{- else }}
21-
MONGODB_URI: {{- .Values.mongodb.externalUrl | quote }}
21+
MONGODB_URL: {{- .Values.mongodb.externalUrl | quote }}
2222
{{- end }}
2323
ENCRYPTION_PASSWORD: {{ .Values.apiService.config.encryption.password | default "lowcoder.org" | quote }}
2424
ENCRYPTION_SALT: {{ .Values.apiService.config.encryption.salt | default "lowcoder.org" | quote }}

docs/self-hosting/README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -136,8 +136,8 @@ For developers who require stateless containers in a cluster environment, we off
136136

137137
<figure><img src="../.gitbook/assets/docker-compose-multi.jpeg" alt=""><figcaption></figcaption></figure>
138138

139-
* **mongodb**: Start a new MongoDB instance on your host. You can delete this part and modify the environment variable `MONGODB_URI` of **openblocks-api-service** to use your own MongoDB.
140-
* **redis**: Start a new Redis instance on your host. You can delete this part and modify the environment variable `REDIS_URI` of **openblocks-api-service** to use your own Redis.
139+
* **mongodb**: Start a new MongoDB instance on your host. You can delete this part and modify the environment variable `MONGODB_URL` of **openblocks-api-service** to use your own MongoDB.
140+
* **redis**: Start a new Redis instance on your host. You can delete this part and modify the environment variable `REDIS_URL` of **openblocks-api-service** to use your own Redis.
141141
* **openblocks-api-service**: Required.&#x20;
142142
* **openblocks-node-service**: Required.
143143
* **openblocks-frontend**: Required. Can be optional if you deploy frontend on CDN.
@@ -199,16 +199,16 @@ By default Lowcoder uses the built-in MongoDB and Redis installed inside the con
199199

200200
{% tabs %}
201201
{% tab title="Docker-Compose" %}
202-
Add environment variables `MONGODB_URI` and `REDIS_URI` in `docker-compose.yml` downloaded in your working directory.\
202+
Add environment variables `MONGODB_URL` and `REDIS_URL` in `docker-compose.yml` downloaded in your working directory.\
203203
<img src="../.gitbook/assets/mongodb-redis-uri.png" alt="" data-size="original">
204204
{% endtab %}
205205

206206
{% tab title="Docker" %}
207-
Add environment variables `MONGODB_URI` and `REDIS_URI` to the deployment command, as shown below:
207+
Add environment variables `MONGODB_URL` and `REDIS_URL` to the deployment command, as shown below:
208208

209209
{% code overflow="wrap" %}
210210
```bash
211-
docker run -d --name openblocks -e MONGODB_URI=YOUR_MONGODB_URI REDIS_URI=YOUR_REDIS_URI -p 3000:3000 -v "$PWD/stacks:/openblocks-stacks lowcoderorg/lowcoder-ce
211+
docker run -d --name openblocks -e MONGODB_URL=YOUR_MONGODB_URL REDIS_URL=YOUR_REDIS_URL -p 3000:3000 -v "$PWD/stacks:/openblocks-stacks lowcoderorg/lowcoder-ce
212212
```
213213
{% endcode %}
214214
{% endtab %}

0 commit comments

Comments
 (0)