-
Notifications
You must be signed in to change notification settings - Fork 96
/
docker-compose.yml
181 lines (172 loc) · 5.88 KB
/
docker-compose.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
version: "3.8"
services:
postgres:
image: "gradescope/postgresql-multiple-databases:14.4"
environment:
POSTGRES_USER: "postgres"
POSTGRES_PASSWORD: "postgres"
POSTGRES_MULTIPLE_DATABASES: "starhub_server,gitea,mirror"
ports:
- "5433:5432"
volumes:
- ./pgdata:/var/lib/postgresql/data
networks:
- my_network
minio:
image: "bitnami/minio"
environment:
MINIO_ROOT_USER: "minio-root-user-User-123"
MINIO_ROOT_PASSWORD: "minio-root-password-User-123"
MINIO_SCHEME: "http"
ports:
- "9000:9000"
- "9001:9001"
volumes:
- ./minio_data:/bitnami/minio/data
networks:
- my_network
gitea:
image: "opencsg/csghub-git"
depends_on:
- postgres
environment:
- GITEA_DAEMON_USER=git
- GITEA_ROOT_URL=$GITEA_ROOT_URL
- GITEA_SSH_DOMAIN=$GITEA_SSH_DOMAIN
- GITEA_HTTP_PORT=3001
- GITEA_ADMIN_USER=root
- GITEA_ADMIN_PASSWORD=password123
- GITEA_ADMIN_EMAIL=root@opencsg.com
- GITEA_DATABASE_TYPE=postgres
- GITEA_DATABASE_HOST=postgres
- GITEA_DATABASE_PORT_NUMBER=5432
- GITEA_DATABASE_NAME=gitea
- GITEA_DATABASE_USERNAME=postgres
- GITEA_DATABASE_PASSWORD=postgres
- GITEA_DATABASE_SSL_MODE=disable
- GITEA_APP_NAME=gitea
- GITEA_SMTP_ENABLED=false
- BITNAMI_DEBUG=true
- GITEA_LFS_START_SERVER=true
- GITEA_LFS_ROOT_PATH=/bitnami/gitea/data/lfs
- GITEA_LFS_STORAGE_TYPE=minio
- GITEA_LFS_MINIO_ACCESS_KEY_ID=minio-root-user-User-123
- GITEA_LFS_MINIO_SECRET_ACCESS_KEY=minio-root-password-User-123
- GITEA_LFS_MINIO_ENDPOINT=minio:9000
- GITEA_LFS_MINIO_BUCKET=opencsg-server-lfs
- GITEA_LFS_MINIO_LOCATION=beijing
- GITEA_LFS_MINIO_USE_SSL=false
- GITEA_LFS_SERVE_DIRECT=true
- GITEA_SERVICE_DEFAULT_ALLOW_CREATE_ORGANIZATION=true
ports:
- "3001:3001"
- "2222:2222"
volumes:
- ./gitea:/bitnami/gitea
networks:
- my_network
starhub_server:
image: "opencsg-registry.cn-beijing.cr.aliyuncs.com/opencsg_public/csghub_server:latest"
depends_on:
- postgres
- gitea
environment:
STARHUB_DATABASE_DSN: postgresql://postgres:postgres@postgres:5432/starhub_server?sslmode=disable
STARHUB_DATABASE_TIMEZONE: Asia/Shanghai
STARHUB_SERVER_GITSERVER_HOST: http://gitea:3001
STARHUB_SERVER_GITSERVER_URL: http://gitea:3001
STARHUB_SERVER_GITSERVER_USERNAME: root
STARHUB_SERVER_GITSERVER_PASSWORD: password123
STARHUB_SERVER_GITSERVER_WEBHOOK_URL: http://localhost:8080/api/v1/callback/git
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: starhub_server
GITEA_USERNAME: root
GITEA_PASSWORD: password123
GIN_MODE: release
STARHUB_SERVER_API_TOKEN: $STARHUB_SERVER_API_TOKEN
STARHUB_SERVER_S3_ACCESS_KEY_ID: $STARHUB_SERVER_S3_ACCESS_KEY_ID
STARHUB_SERVER_S3_ACCESS_KEY_SECRET: $STARHUB_SERVER_S3_ACCESS_KEY_SECRET
STARHUB_SERVER_S3_REGION: $STARHUB_SERVER_S3_REGION
STARHUB_SERVER_S3_BUCKET: $STARHUB_SERVER_S3_BUCKET
STARHUB_SERVER_INFERENCE_SERVER_ADDR: $STARHUB_SERVER_INFERENCE_SERVER_ADDR
OPENCSG_ACCOUNTING_NATS_URL: nats://natsadmin:vf3jv9SsJBdv3n02n8Kxbvjf@natsmaster:4222
OPENCSG_ACCOUNTING_SERVER_HOST: http://account_server
OPENCSG_ACCOUNTING_SERVER_PORT: 8086
OPENCSG_USER_SERVER_HOST: http://user_server
OPENCSG_USER_SERVER_PORT: 8088
ports:
- "8080:8080"
networks:
- my_network
natsmaster:
image: "nats:2.10.16"
deploy:
resources:
limits:
cpus: '1'
memory: 1G
reservations:
cpus: '1'
memory: 1G
ports:
- "4222:4222"
- "6222:6222"
- "8222:8222"
volumes:
- ./nats-server.conf:/nats-server.conf
- ./jetstream:/data/jetstream
restart: always
account_server:
image: "opencsg-registry.cn-beijing.cr.aliyuncs.com/opencsg_public/csghub_server:latest"
entrypoint:
- /starhub-bin/starhub
- accounting
- launch
depends_on:
- postgres
- natsmaster
environment:
STARHUB_SERVER_API_TOKEN: $STARHUB_SERVER_API_TOKEN
STARHUB_DATABASE_DSN: postgresql://postgres:postgres@postgres:5432/starhub_server?sslmode=disable
OPENCSG_ACCOUNTING_SERVER_PORT: 8086
OPENCSG_ACCOUNTING_NATS_URL: nats://natsadmin:vf3jv9SsJBdv3n02n8Kxbvjf@natsmaster:4222
OPENCSG_ACCOUNTING_MSG_FETCH_TIMEOUTINSEC: 5
GIN_MODE: release
ports:
- "8086:8086"
restart: always
user_server:
image: "opencsg/csghub-server"
entrypoint:
- /starhub-bin/starhub
- user
- launch
depends_on:
- postgres
- gitea
environment:
STARHUB_SERVER_API_TOKEN: $STARHUB_SERVER_API_TOKEN
STARHUB_DATABASE_DSN: postgresql://postgres:postgres@postgres:5432/starhub_server?sslmode=disable
STARHUB_DATABASE_TIMEZONE: Asia/Shanghai
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: starhub_server
STARHUB_SERVER_GITSERVER_HOST: http://gitea:3001
STARHUB_SERVER_GITSERVER_USERNAME: root
STARHUB_SERVER_GITSERVER_PASSWORD: password123
STARHUB_SERVER_CASDOOR_CLIENT_ID: $STARHUB_SERVER_CASDOOR_CLIENT_ID
STARHUB_SERVER_CASDOOR_CLIENT_SECRET: $STARHUB_SERVER_CASDOOR_CLIENT_SECRET
STARHUB_SERVER_CASDOOR_ENDPOINT: $STARHUB_SERVER_CASDOOR_ENDPOINT
STARHUB_SERVER_CASDOOR_CERTIFICATE: /starhub-bin/casdoor/token_jwt_key.pem
STARHUB_SERVER_CASDOOR_ORGANIZATION_NAME: OpenCSG
STARHUB_SERVER_CASDOOR_APPLICATION_NAME: Portal
OPENCSG_USER_SERVER_PORT: 8088
OPENCSG_USER_SERVER_SIGNIN_SUCCESS_REDIRECT_URL: $OPENCSG_USER_SERVER_SIGNIN_SUCCESS_REDIRECT_URL
ports:
- "8088:8088"
volumes:
- ./casdoor:/starhub-bin/casdoor:r
networks:
my_network:
driver: bridge