Giter VIP home page Giter VIP logo

Comments (5)

nobodyiam avatar nobodyiam commented on May 14, 2024

可以作为system property传进来,比如-Dfat_meta=http://fat.config:8080

from apollo.

nobodyiam avatar nobodyiam commented on May 14, 2024

另外fat_meta不是放在startup.sh脚本的,是maven打包到apollo-core.jar中的apollo-env.properties,所以一次打包就后顾无忧啦

from apollo.

myfreeway avatar myfreeway commented on May 14, 2024

顺序有点小问题。
1、首先mvn clean deploy,打包放进maven仓库。这时apollo-core.jar中的apollo-env.properties是原始的“fat.meta=${fat_meta}”。
2、修改build.sh,设置fat_meta=http://fat.config:8080。执行build.sh,打出部署Apollo的包。
3、开发应用A,集成Apollo client。关键来了。这时从maven仓库拉回来的apollo-core.jar,apollo-env.properties是原始的“fat.meta=${fat_meta}”。
4、发布应用A,这时fat.meta=${fat_meta}。so这时只能修改tomcat的startup.sh,放-Dfat_meta=http://fat.config:8080进去。不然启动失败。

from apollo.

nobodyiam avatar nobodyiam commented on May 14, 2024

倒不是顺序问题,我们的文档没有说过要自己mvn clean deploy吧。。都是通过build.sh打出apollo-core.jar,然后上传到nexus仓库的。

from apollo.

myfreeway avatar myfreeway commented on May 14, 2024

写死到jar包也有好处。减少配置。
不然还得每个服务器,设置环境变量。(如果修改代码,让他支持从环境变量覆盖这些值的话)

from apollo.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.