Skip to content

Commit

Permalink
Merge pull request #461 from jumpserver/dev
Browse files Browse the repository at this point in the history
v4.0.0
  • Loading branch information
BaiJiangJie authored Jul 3, 2024
2 parents c322039 + 9198e33 commit e8a9d3d
Show file tree
Hide file tree
Showing 55 changed files with 1,754 additions and 1,385 deletions.
2 changes: 2 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Auto detect text files and perform LF normalization
* text=lf
12 changes: 6 additions & 6 deletions cn-quick_start.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,17 @@ VERSION=dev
DOWNLOAD_URL=https://resource.fit2cloud.com

function install_soft() {
if command -v dnf > /dev/null; then
if command -v dnf &>/dev/null; then
dnf -q -y install "$1"
elif command -v yum > /dev/null; then
elif command -v yum &>/dev/null; then
yum -q -y install "$1"
elif command -v apt > /dev/null; then
elif command -v apt &>/dev/null; then
apt-get -qqy install "$1"
elif command -v zypper > /dev/null; then
elif command -v zypper &>/dev/null; then
zypper -q -n install "$1"
elif command -v apk > /dev/null; then
elif command -v apk &>/dev/null; then
apk add -q "$1"
command -v gettext >/dev/null || {
command -v gettext &>/dev/null || {
apk add -q gettext-dev python3
}
else
Expand Down
4 changes: 2 additions & 2 deletions compose/docker-compose-celery.yml → compose/celery.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
services:
celery:
image: ${REGISTRY:-docker.io}/jumpserver/core-ce:${VERSION}
image: ${REGISTRY:-docker.io}/jumpserver/core:${VERSION}
container_name: jms_celery
hostname: jms_celery
ulimits:
core: 0
restart: always
tty: true
privileged: true
command: start task
env_file:
- ${CONFIG_FILE}
Expand Down
3 changes: 1 addition & 2 deletions compose/docker-compose-chen.yml → compose/chen.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,13 @@ services:
ulimits:
core: 0
restart: always
tty: true
env_file:
- ${CONFIG_FILE}
volumes:
- ${VOLUME_DIR}/chen/data:/opt/chen/data
- ${CONFIG_DIR}/certs:/opt/chen/data/certs
healthcheck:
test: "curl -f 127.0.0.1:8082/chen"
test: "check http://localhost:8082/chen/"
interval: 10s
timeout: 5s
retries: 3
Expand Down
5 changes: 2 additions & 3 deletions compose/docker-compose-core.yml → compose/core.yml
Original file line number Diff line number Diff line change
@@ -1,20 +1,19 @@
services:
core:
image: ${REGISTRY:-docker.io}/jumpserver/core-ce:${VERSION}
image: ${REGISTRY:-docker.io}/jumpserver/core:${VERSION}
container_name: jms_core
hostname: jms_core
ulimits:
core: 0
restart: always
tty: true
command: start web
env_file:
- ${CONFIG_FILE}
volumes:
- ${CONFIG_DIR}/certs:/opt/jumpserver/data/certs
- ${VOLUME_DIR}/core/data:/opt/jumpserver/data
healthcheck:
test: "curl -fsL http://localhost:8080/api/health/ > /dev/null"
test: "check http://localhost:8080/api/health/"
interval: 10s
timeout: 5s
retries: 3
Expand Down
3 changes: 0 additions & 3 deletions compose/docker-compose-celery-xpack.yml

This file was deleted.

3 changes: 0 additions & 3 deletions compose/docker-compose-core-xpack.yml

This file was deleted.

3 changes: 0 additions & 3 deletions compose/docker-compose-init-db-xpack.yml

This file was deleted.

22 changes: 0 additions & 22 deletions compose/docker-compose-kael.yml

This file was deleted.

6 changes: 0 additions & 6 deletions compose/docker-compose-magnus-xpack.yml

This file was deleted.

3 changes: 0 additions & 3 deletions compose/docker-compose-receptor-xpack.yml

This file was deleted.

5 changes: 0 additions & 5 deletions compose/docker-compose-web-xpack.yml

This file was deleted.

1 change: 1 addition & 0 deletions compose/docker-compose-es.yml → compose/es.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ services:
- ${VOLUME_DIR}/elasticsearch/data:/usr/share/elasticsearch/data
- ${VOLUME_DIR}/elasticsearch/logs:/usr/share/elasticsearch/logs
environment:
TZ: ${TZ:-Asia/Shanghai}
cluster.name: docker-cluster
discovery.type: single-node
network.host: 0.0.0.0
Expand Down
5 changes: 2 additions & 3 deletions compose/docker-compose-init-db.yml → compose/init-db.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
services:
core:
image: ${REGISTRY:-docker.io}/jumpserver/core-ce:${VERSION}
image: ${REGISTRY:-docker.io}/jumpserver/core:${VERSION}
container_name: jms_core
hostname: jms_core
tty: true
command: sleep
command: "tail -f /dev/null"
env_file:
- ${CONFIG_FILE}
volumes:
Expand Down
5 changes: 2 additions & 3 deletions compose/docker-compose-koko.yml → compose/koko.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ services:
ulimits:
core: 0
restart: always
tty: true
privileged: true
env_file:
- ${CONFIG_FILE}
environment:
Expand All @@ -16,9 +16,8 @@ services:
volumes:
- ${CONFIG_DIR}/certs:/opt/koko/data/certs
- ${VOLUME_DIR}/koko/data:/opt/koko/data
privileged: true
healthcheck:
test: "curl -fsL http://localhost:5000/koko/health/ > /dev/null"
test: "check http://localhost:5000/koko/health/"
interval: 10s
timeout: 5s
retries: 3
Expand Down
File renamed without changes.
3 changes: 1 addition & 2 deletions compose/docker-compose-lion.yml → compose/lion.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,13 @@ services:
ulimits:
core: 0
restart: always
tty: true
env_file:
- ${CONFIG_FILE}
volumes:
- ${CONFIG_DIR}/certs:/opt/lion/data/certs
- ${VOLUME_DIR}/lion/data:/opt/lion/data
healthcheck:
test: "curl -fsL http://localhost:8081/lion/health/ > /dev/null"
test: "check http://localhost:8081/lion/health/"
interval: 10s
timeout: 5s
retries: 3
Expand Down
29 changes: 29 additions & 0 deletions compose/loki.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
services:
loki:
image: grafana/loki:3.0.0
container_name: jms_loki
hostname: jms_loki
user: "0"
command: -config.file=/etc/loki/local-config.yaml
volumes:
- ${CONFIG_DIR}/loki/loki.yaml:/etc/loki/local-config.yaml
- ${VOLUME_DIR}/loki/loki:/loki
networks:
- net

promtail:
image: grafana/promtail:3.0.0
container_name: jms_promtail
hostname: jms_promtail
env_file:
- ${CONFIG_FILE}
volumes:
- ${CONFIG_DIR}/loki/promtail.yml:/etc/promtail/config.yml
- ${VOLUME_DIR}/loki/promtail/:/data/jumpserver/loki/promtail/
- ${VOLUME_DIR}:/data/jumpserver/
- /var/run/docker.sock:/var/run/docker.sock
command: -config.file=/etc/promtail/config.yml -config.expand-env=true
networks:
- net
depends_on:
- loki
6 changes: 4 additions & 2 deletions compose/docker-compose-magnus.yml → compose/magnus.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,20 @@
services:
magnus:
image: ${REGISTRY:-docker.io}/jumpserver/magnus:${VERSION}
image: ${REGISTRY:-registry.fit2cloud.com}/jumpserver/magnus:${VERSION}
container_name: jms_magnus
hostname: jms_magnus
ulimits:
core: 0
restart: always
tty: true
env_file:
- ${CONFIG_FILE}
ports:
- ${MAGNUS_MYSQL_PORT:-33061}:33061
- ${MAGNUS_MARIADB_PORT:-33062}:33062
- ${MAGNUS_REDIS_PORT:-63790}:63790
- ${MAGNUS_POSTGRESQL_PORT:-54320}:54320
- ${MAGNUS_SQLSERVER_PORT:-14330}:14330
- ${MAGNUS_ORACLE_PORTS:-30000-30030}:${MAGNUS_ORACLE_PORTS:-30000-30030}
volumes:
- ${CONFIG_DIR}/certs:/opt/magnus/data/certs
- ${VOLUME_DIR}/magnus/data:/opt/magnus/data
Expand Down
4 changes: 2 additions & 2 deletions compose/docker-compose-mariadb.yml → compose/mariadb.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
services:
mysql:
image: jumpserver/mariadb:10.6
image: mariadb:10.6
container_name: jms_mysql
hostname: jms_mysql
restart: always
command: --character-set-server=utf8 --collation-server=utf8_general_ci
environment:
TZ: ${TZ:-Asia/Shanghai}
DB_PORT: $DB_PORT
MARIADB_ROOT_PASSWORD: $DB_PASSWORD
MARIADB_DATABASE: $DB_NAME
Expand Down
7 changes: 4 additions & 3 deletions compose/docker-compose-minio.yml → compose/minio.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,16 @@ services:
hostname: jms_minio
restart: always
command: "server /data --console-address :9001"
environment:
TZ: ${TZ:-Asia/Shanghai}
MINIO_ROOT_USER: minio
MINIO_ROOT_PASSWORD: $BOOTSTRAP_TOKEN
ports:
- 9000:9000
- 9001:9001
volumes:
- ${VOLUME_DIR}/minio/data:/data
- ${CONFIG_DIR}/minio/config:/root/.minio
environment:
MINIO_ROOT_USER: minio
MINIO_ROOT_PASSWORD: $BOOTSTRAP_TOKEN
healthcheck:
test: "mc ready local"
interval: 10s
Expand Down
4 changes: 2 additions & 2 deletions compose/docker-compose-mysql.yml → compose/mysql.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
services:
mysql:
image: jumpserver/mysql:5.7
image: mysql:5.7-debian
container_name: jms_mysql
hostname: jms_mysql
restart: always
command: --character-set-server=utf8
environment:
TZ: ${TZ:-Asia/Shanghai}
DB_PORT: $DB_PORT
MYSQL_ROOT_PASSWORD: $DB_PASSWORD
MYSQL_DATABASE: $DB_NAME
Expand Down
File renamed without changes.
File renamed without changes.
1 change: 0 additions & 1 deletion compose/docker-compose-panda.yml → compose/panda.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ services:
ulimits:
core: 0
restart: always
tty: true
env_file:
- ${CONFIG_FILE}
volumes:
Expand Down
20 changes: 20 additions & 0 deletions compose/postgres.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
services:
postgresql:
image: postgres:16.3-bullseye
container_name: jms_postgresql
restart: always
environment:
TZ: ${TZ:-Asia/Shanghai}
POSTGRES_DB: $DB_NAME
POSTGRES_USER: $DB_USER
POSTGRES_PASSWORD: $DB_PASSWORD
volumes:
- ${VOLUME_DIR}/postgresql/data:/var/lib/postgresql/data
healthcheck:
test: "pg_isready"
interval: 10s
timeout: 5s
retries: 3
start_period: 30s
networks:
- net
1 change: 0 additions & 1 deletion compose/docker-compose-razor.yml → compose/razor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ services:
ulimits:
core: 0
restart: always
tty: true
env_file:
- ${CONFIG_FILE}
ports:
Expand Down
3 changes: 1 addition & 2 deletions compose/docker-compose-receptor.yml → compose/receptor.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
services:
receptor:
image: ${REGISTRY:-docker.io}/jumpserver/core-ce:${VERSION}
image: ${REGISTRY:-docker.io}/jumpserver/core:${VERSION}
container_name: jms_receptor
hostname: jms_receptor
ulimits:
core: 0
restart: always
tty: true
command: start receptor
environment:
LOG_LEVEL: ${LOG_LEVEL}
Expand Down
3 changes: 2 additions & 1 deletion compose/docker-compose-redis.yml → compose/redis.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
services:
redis:
image: jumpserver/redis:6.2
image: redis:7.0-bullseye
container_name: jms_redis
hostname: jms_redis
restart: always
command: ["redis-server", "/etc/redis.conf", "--requirepass", "$REDIS_PASSWORD"]
environment:
TZ: ${TZ:-Asia/Shanghai}
REDIS_PORT: $REDIS_PORT
REDIS_PASSWORD: $REDIS_PASSWORD
volumes:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ services:
ulimits:
core: 0
restart: always
tty: true
env_file:
- ${CONFIG_FILE}
ports:
Expand Down
1 change: 0 additions & 1 deletion compose/docker-compose-video.yml → compose/video.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ services:
ulimits:
core: 0
restart: always
tty: true
env_file:
- ${CONFIG_FILE}
volumes:
Expand Down
Loading

0 comments on commit e8a9d3d

Please sign in to comment.