zoukankan      html  css  js  c++  java
  • 【Apollo】Apollo 分布式部署

    Apollo 分布式部署

      官网文档:https://www.apolloconfig.com/#/zh/deployment/distributed-deployment-guide

      部署说明

      - 部署DEV 和 UAT 环境

      - DEV 和 UAT 环境中 分别使用独立的 Apollo Admin Service  、 Apollo Config Service 以及 Mysql 的配置库(ApolloConfigDB)

      - DEV 和 UAT 环境中 公用 Apollo Protal 服务

      

      1、下载Apollo包,地址:https://github.com/apolloconfig/apollo/releases

        

      2、安装数据库,其中 Portal库一个  Config配置库2个,

        

       3、解压三个压缩包,并修改数据库配置文件,  

    [root@H__D apollo-configservice-1.9.0]# cd config/
    [root@H__D config]# ls
    application-github.properties  app.properties
    [root@H__D config]# cat application-github.properties 
    #
    # Copyright 2021 Apollo Authors
    #
    # Licensed under the Apache License, Version 2.0 (the "License");
    # you may not use this file except in compliance with the License.
    # You may obtain a copy of the License at
    #
    # http://www.apache.org/licenses/LICENSE-2.0
    #
    # Unless required by applicable law or agreed to in writing, software
    # distributed under the License is distributed on an "AS IS" BASIS,
    # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    # See the License for the specific language governing permissions and
    # limitations under the License.
    #
    # DataSource
    spring.datasource.url = jdbc:mysql://196.168.0.1:3306/ApolloConfigDB?characterEncoding=utf8
    spring.datasource.username = root
    spring.datasource.password = 123456
    
    
    # Eureka ,可以修改Eureka配置
    # eureka.instance.ip-address=196.168.0.1

       4、修改protal服务环境信息配置文件 config/apollo-env.properties

    [root@H__D apollo-portal-1.9.0]# ls
    apollo-portal-1.9.0-github.zip  apollo-portal-1.9.0.jar  apollo-portal-1.9.0-sources.jar  apollo-portal.conf  config  scripts
    [root@H__D apollo-portal-1.9.0]# cd config/
    [root@H__D config]# ls
    apollo-env.properties  application-github.properties  app.properties
    [root@H__D config]# cat apollo-env.properties 
    #
    # Copyright 2021 Apollo Authors
    #
    # Licensed under the Apache License, Version 2.0 (the "License");
    # you may not use this file except in compliance with the License.
    # You may obtain a copy of the License at
    #
    # http://www.apache.org/licenses/LICENSE-2.0
    #
    # Unless required by applicable law or agreed to in writing, software
    # distributed under the License is distributed on an "AS IS" BASIS,
    # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    # See the License for the specific language governing permissions and
    # limitations under the License.
    #
    local.meta=http://localhost:8080
    dev.meta=http://fill-in-dev-meta-server:8080
    fat.meta=http://fill-in-fat-meta-server:8080
    uat.meta=http://fill-in-uat-meta-server:8080
    lpt.meta=${lpt_meta}
    pro.meta=http://fill-in-pro-meta-server:8080
    [root@H__D config]# 

      5、如果要修改端口,可以修改scripts/startup.sh文件中的端口

      

      6、如果要修改参数,可以

       7、启动和关闭服务

      启动:./scripts/startup.sh

      关闭:./scripts/shutdown.sh

      8、浏览器访问 Apollo Protal 服务

  • 相关阅读:
    [LeetCode] 304. Range Sum Query 2D
    [LeetCode] 303. Range Sum Query
    [Google] Help employee find the nearest gbike
    Difference between Process and thread?
    Given a family tree, find out if two people are blood related
    [LeetCode] 676. Implement Magic Dictionary 实现神奇字典
    [LeetCode] 659. Split Array into Consecutive Subsequences 将数组分割成连续子序列
    [LeetCode] 815. Bus Routes 公交路线
    [LeetCode] 129. Sum Root to Leaf Numbers 求根到叶节点数字之和
    mybatis example 使用AND 和OR 联合查询
  • 原文地址:https://www.cnblogs.com/h--d/p/15545793.html
Copyright © 2011-2022 走看看