Skip to content

Commit

Permalink
Merge pull request #705 from OpenCSGs/fix-startup
Browse files Browse the repository at this point in the history
adjust startup dependency
  • Loading branch information
MasonXon authored Oct 10, 2024
2 parents 8d44282 + d2f60ad commit 2589077
Showing 1 changed file with 14 additions and 17 deletions.
31 changes: 14 additions & 17 deletions deploy/all_in_one/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@ version: '2.4'
services:
nginx:
image: opencsg-registry.cn-beijing.cr.aliyuncs.com/public/nginx:latest
depends_on:
- csghub_server
- csghub_server_proxy
- casdoor
- csghub_portal
ports:
- ${SERVER_PORT}:${SERVER_PORT}
- ${SERVER_CASDOOR_PORT}:${SERVER_CASDOOR_PORT}
Expand Down Expand Up @@ -53,7 +58,7 @@ services:
- ./auth:/auth
networks:
opencsg:
ipv4_address: 192.168.100.247
ipv4_address: 192.168.100.247
environment:
REGISTRY_AUTH: "htpasswd"
REGISTRY_AUTH_HTPASSWD_REALM: "Registry Realm"
Expand Down Expand Up @@ -81,8 +86,7 @@ services:
restart: always
depends_on:
- postgres
command:
["bash", "-c", "./csghub-portal migration init && ./csghub-portal migration migrate && ./csghub-portal start server "]
command: [ "bash", "-c", "./csghub-portal migration init && ./csghub-portal migration migrate && ./csghub-portal start server " ]
environment:
CSGHUB_PORTAL_ON_PREMISE: true
CSGHUB_PORTAL_SENSITIVE_CHECK: false
Expand Down Expand Up @@ -111,7 +115,7 @@ services:
- postgres
- redis
- gitaly
- gitlab-shell
- gitlab-shell
- natsmaster
environment:
STARHUB_DATABASE_DSN: postgresql://postgres:sdfa23Sh!322@postgres:5432/starhub_server?sslmode=disable
Expand Down Expand Up @@ -161,7 +165,6 @@ services:
opencsg:
ipv4_address: 192.168.100.244


csghub_server_runner:
image: opencsg-registry.cn-beijing.cr.aliyuncs.com/opencsg_public/csghub_server:latest
entrypoint:
Expand Down Expand Up @@ -194,14 +197,15 @@ services:
PGPASSWORD: "sdfa23Sh!322"
volumes:
- ./init-scripts:/scripts
entrypoint: ["sh", "-c", "until nc -zv csghub_server 8080 ; do echo 'sleep 10s...'; sleep 10; done; echo 'begin to do db init scripts'; until pg_isready -h postgres -p 5432; do sleep 5; done; psql -h postgres -U postgres -d starhub_server -f /scripts/init.sql"]
entrypoint: [ "sh", "-c", "until nc -zv csghub_server 8080 ; do echo 'sleep 10s...'; sleep 10; done; echo 'begin to do db init scripts'; until pg_isready -h postgres -p 5432; do sleep 5; done; psql -h postgres -U postgres -d starhub_server -f /scripts/init.sql" ]
networks:
opencsg:
ipv4_address: 192.168.100.232


csghub_server_proxy:
image: opencsg-registry.cn-beijing.cr.aliyuncs.com/opencsg_public/csghub_server:latest
depends_on:
- csghub_server
entrypoint:
- /starhub-bin/starhub
- start
Expand Down Expand Up @@ -247,11 +251,9 @@ services:
volumes:
- ./space_data:/opt/data:rw


gitlab-shell:
image: opencsg-registry.cn-beijing.cr.aliyuncs.com/opencsg_public/gitlab-shell:v16.4.6
command:
["bash", "-c", "exec /usr/bin/env SSH_DAEMON=gitlab-sshd /scripts/process-wrapper"]
command: [ "bash", "-c", "exec /usr/bin/env SSH_DAEMON=gitlab-sshd /scripts/process-wrapper" ]
environment:
- SSH_DAEMON=gitlab-sshd
ports:
Expand All @@ -269,8 +271,7 @@ services:

gitaly:
image: opencsg-registry.cn-beijing.cr.aliyuncs.com/opencsg_public/gitaly:v16.4.6
command:
["bash", "-c", "mkdir -p /home/git/repositories && rm -rf /srv/gitlab-shell/hooks/* && touch /srv/gitlab-shell/.gitlab_shell_secret && exec /usr/bin/env GITALY_CONFIG_FILE=/home/gitaly.config.toml /scripts/process-wrapper"]
command: [ "bash", "-c", "mkdir -p /home/git/repositories && rm -rf /srv/gitlab-shell/hooks/* && touch /srv/gitlab-shell/.gitlab_shell_secret && exec /usr/bin/env GITALY_CONFIG_FILE=/home/gitaly.config.toml /scripts/process-wrapper" ]
environment:
- GITALY_CONFIG_FILE=/home/gitaly.config.toml
ports:
Expand All @@ -285,7 +286,6 @@ services:
- ./data/gitaly/gitaly.config.toml:/home/gitaly.config.toml
- ./data/gitaly/logs:/var/log/gitaly


minio:
image: opencsg-registry.cn-beijing.cr.aliyuncs.com/opencsg_public/bitnami/minio:2023
ports:
Expand Down Expand Up @@ -392,8 +392,7 @@ services:
- ./casdoor/conf:/conf/
networks:
opencsg:
ipv4_address: 192.168.100.234

ipv4_address: 192.168.100.234

server_proxy_nginx:
image: opencsg-registry.cn-beijing.cr.aliyuncs.com/public/nginx:latest
Expand All @@ -408,7 +407,6 @@ services:
ipv4_address: 192.168.100.233
restart: always


mirror-repo-sync:
image: opencsg-registry.cn-beijing.cr.aliyuncs.com/opencsg_public/csghub_server:latest
entrypoint:
Expand Down Expand Up @@ -456,7 +454,6 @@ services:
networks:
opencsg:
ipv4_address: 192.168.100.230


networks:
opencsg:
Expand Down

0 comments on commit 2589077

Please sign in to comment.