Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cac-cli

This name comes from: Configuration as Code.

Configuration as code (CAC) is managing configuration resources in your source repository. You treat your application config resources as versioned artifacts. By managing your application environment in tandem with your application code, you gain the same benefits you get with your code. CAC is a set of processes and practices that will save you time, increase your flexibility, and improve your system uptime.

  • Simplify Configuration Data
  • Take Advantage of Version Control
  • IAC and CAC both together

cac-cli will help you appling CAC.

You can read more about it in the wiki page.

You can check latests releases in the releases page.

Hello world

Install latest version using dotnet client: (recomended)

dotnet tool install --global cac-cli --version 0.0.1-beta

or using npm:

npm install -g cac-cli@0.0.1-beta

Create a new file called file.yml with the content bellow:

parameters:
  environment:

packages:
- name: Cac.Sample
  version: 0.0.1-beta

providers:
- sample: sample
  var1: ${{parameters.environment}}1
  var2: ${{parameters.environment}}2
  var3: ${{parameters.environment}}3

variables:
  list:
  - name: ${{ providers.sample.var1 }}
  - name: ${{ providers.sample.var2 }}
  - name: ${{ providers.sample.var3 }}

activities:
- for_each: ${{ variables.list }}
  as: item
  activities:
  - sample: ${{ item.name }}

Execute plan CAC:

cac plan file.yml -p environment=dev

You should find the output bellow in your terminal:

packages
  Downloading: cac.sample v0.0.1-beta
plan
  Name to write: dev1
  Name to write: dev2
  Name to write: dev3

License

The source code we develop at cac-cli is default being licensed as CC-BY-SA-4.0. You can read more about here.

About

cac-cli is a tool helps you managing configuration of your resources in your code repository

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages