cloud-config is a multi-tenant-aware configuaration center based on Zookeeper and tightly integrated with Spring framework which is inspired by Centralized Application Configuration with Spring and Apache ZooKeeper.

How to Start

  1. Run following scripts to build entire project after sync the latest code

    cd cloud-config-ui && npm install && cd .. && mvn clean install
  2. Install & Start Zookeeper server
  3. Start cloud-config-server application

    java -Dnamespace={namespace}{zk.url} -jar cloud-config-server/target/cloud-config-server-1.0.0-SNAPSHOT.jar  
  4. Go to http://localhost:8001/ in browser

How to Use

  1. import cloud-config-client as your project maven dependency, e.g.

  2. simple usage configuration, e.g.

    <?xml version="1.0" encoding="UTF-8"?>
    <beans xmlns=""
        <!-- config zookeeper client -->
        <cc:zk-client connection-string="" credential-string="user:passwd"/>
        <!-- config as property place holder -->
        <cc:zk-property-placeholder path="/mail, /query" location=""/>
        <!-- config as jdbc dataSource -->
        <cc:zk-jdbc-datasource id="dataSource" path="/database/mydb" resource-type="C3P0"/>

Docker Support

  1. Build cloud config docker container

    cd ${cloud-config-prj-folder}
    docker build -t hekailiang/cloud-config .   
  2. Run docker container for cloud config

    docker run -d -p 8001:8001 --name cc -e ZK_URL={zkserver} hekailiang/cloud-config
  3. For MacOS users, use following command to simplify docker machine access

    echo $(docker-machine ip default) dockerhost | sudo tee -a /etc/hosts
  4. Go to http://dockerhost:8001 in browser

Dock Compose Support

   cd ${cloud-config-prj-folder}
   docker-compose up


  1. System properties config and lookup
  2. Single or Multi-tenant-aware DataSource config and lookup
  3. Custom resource object config and lookup

Rencent Goal

  1. Integrate with Docker to provide live demo
  2. Enhance UI and documentation