MicroCommunity icon indicating copy to clipboard operation
MicroCommunity copied to clipboard

how to install ?

Open 928255095 opened this issue 1 year ago • 0 comments

1、download code git clone https://github.com/java110/MicroCommunity.git Execute mvn clean package and mvn clean install

2、Add hosts 127.0.0.1 dev.db.java110.com 127.0.0.1 dev.zk.java110.com 127.0.0.1 dev.kafka.java110.com 127.0.0.1 dev.redis.java110.com 127.0.0.1 api.java110.com 127.0.0.1 dev.java110.com 3、Install mysql and import TT.sql and hc_community.sql (files are under docs/db) 4、Install redis and specify the redis password 5、Modify application-dev.yml and dataSource.yml under the service at the beginning of the module service- Mainly modify the redis password in application-dev.yml

jedis: pool: config: maxTotal: 100 maxIdle: 20 maxWaitMillis: 20000 host: dev.redis.java110.com port: 6379 timeout: 3000 password: hc Change password: hc in hc to the password specified by redis

spring: profiles: active: share http: encoding: charset: UTF-8 enabled: true force: true application: name: community-service redis: database: 0 host: dev.redis.java110.com port: 6379 password: hc pool: max-active: 300 max-wait: 10000 max-idle: 100 min-idle: 0 timeout: 0 Change password: hc in hc to the password specified by redis

dataSources: ds0: !!com.alibaba.druid.pool.DruidDataSource driverClassName: com.mysql.cj.jdbc.Driver url: jdbc:mysql://dev.db.java110.com:3306/hc_community?useUnicode=true&characterEncoding=utf-8&serverTimezone=GMT%2B8 username: hc_community password: hc_community@12345678 minIdle: 5 validationQuery: SELECT 1 FROM DUAL initialSize: 5 maxWait: 60000 filters: stat,wall,log4j poolPreparedStatements: true ds1: !!com.alibaba.druid.pool.DruidDataSource driverClassName: com.mysql.cj.jdbc.Driver url: jdbc:mysql://dev.db.java110.com:3306/TT?useUnicode=true&characterEncoding=utf-8&serverTimezone=GMT%2B8 username: TT password: TT@12345678 minIdle: 5 validationQuery: SELECT 1 FROM DUAL initialSize: 5 maxWait: 60000 filters: stat,wall,log4j poolPreparedStatements: true Modify password in dataSource.yml Note that for example, there is no dataSource.yml file in the service-api service 6、Start the main method in the *ServiceApplicationStart.java file under the service-start service-start module Note that there is no order to start, but we recommend that you start service-eureka first 7、Download the previous code git clone https://github.com/java110/MicroCommunityWeb.git 8、Modify the address in app.js

app.use('/callComponent', proxy('http://192.168.100.108:8008', opts)); app.use('/app', proxy('http://192.168.100.108:8008', opts)); Change 192.168.100.108 to the ip of your backend 9、start and access npm start

PS C:\project\vip\MicroCommunityWeb> npm start

[email protected] start C:\project\vip\MicroCommunityWeb node ./bin/www Indicates that the startup was successful address:http://localhost:3000/

928255095 avatar Jan 09 '23 13:01 928255095