Skip to content

Commit

Permalink
moss与应用共用一个mysql实例
Browse files Browse the repository at this point in the history
  • Loading branch information
zhoutaoo committed Oct 19, 2019
1 parent 10e24aa commit dd7b9ab
Show file tree
Hide file tree
Showing 5 changed files with 274 additions and 952 deletions.
2 changes: 1 addition & 1 deletion common/web/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<version>[2.9.10,)</version>
<version>2.9.10</version>
</dependency>
<!--mybatis plus依赖包-->
<dependency>
Expand Down
4 changes: 2 additions & 2 deletions docker-compose/.env-moss
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
### MOSS
MOSS_DB_TYPE=mysql
MOSS_PORT=8086
MOSS_SKYWALKING_HOST=localhost
MOSS_SKYWALKING_HOST=skywalking-oap
MOSS_SKYWALKING_PORT=12800

### 数据源mysql实例
DATASOURCE_HOST=moss-db
DATASOURCE_HOST=mysql
DATASOURCE_PORT=3306
DATASOURCE_USERNAME=root
DATASOURCE_PASSWORD=root123
Expand Down
16 changes: 6 additions & 10 deletions docker-compose/docker-compose.moss.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,15 @@
version: '3'
services:
#MOSS Mysql数据库
moss-db:
#MOSS Mysql数据库初使化
moss-db-init:
image: mysql:5.7
container_name: moss-db
restart: always
command: /init-db.sh
networks:
- sc-net
ports:
- 3306:3306
volumes:
- ./moss/mysql:/docker-entrypoint-initdb.d
- ./data/mysql:/var/lib/mysql
- ./moss/mysql:/sql
- ./init-db.sh:/init-db.sh
environment:
TZ: Asia/Shanghai
MYSQL_ROOT_PASSWORD: root123

#Moss管理中心
Expand All @@ -29,4 +25,4 @@ services:
environment:
TZ: Asia/Shanghai
depends_on:
- moss-db
- moss-db-init
Loading

0 comments on commit dd7b9ab

Please sign in to comment.