{"id":21744060,"url":"https://github.com/telefonica/cerdito","last_synced_at":"2025-10-24T04:43:25.394Z","repository":{"id":235188829,"uuid":"787403081","full_name":"Telefonica/cerdito","owner":"Telefonica","description":"Save a few cents on your cloud infrastructure","archived":false,"fork":false,"pushed_at":"2025-04-08T07:21:13.000Z","size":123,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-13T05:07:16.736Z","etag":null,"topics":["azure","cloud","cost-optimization","infrastructure","org-cdo"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Telefonica.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-04-16T13:06:45.000Z","updated_at":"2025-04-08T07:15:43.000Z","dependencies_parsed_at":"2025-04-08T08:35:13.416Z","dependency_job_id":null,"html_url":"https://github.com/Telefonica/cerdito","commit_stats":null,"previous_names":["telefonica/cerdito"],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Telefonica%2Fcerdito","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Telefonica%2Fcerdito/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Telefonica%2Fcerdito/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Telefonica%2Fcerdito/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Telefonica","download_url":"https://codeload.github.com/Telefonica/cerdito/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248665747,"owners_count":21142123,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["azure","cloud","cost-optimization","infrastructure","org-cdo"],"created_at":"2024-11-26T07:09:52.506Z","updated_at":"2025-10-24T04:43:20.364Z","avatar_url":"https://github.com/Telefonica.png","language":"Rust","readme":"# cerdito\n\n[![Made with Rust](https://forthebadge.com/images/badges/made-with-rust.svg)](https://www.rust-lang.org)\n[![Gluten Free](https://forthebadge.com/images/badges/gluten-free.svg)](https://en.wikipedia.org/wiki/Gluten-free_diet)\n[![It works](https://forthebadge.com/images/badges/it-works-why.svg)](https://youtu.be/dQw4w9WgXcQ)\n\n![Piggy Bank](cerdito.svg)\n\nSave a few cents on your cloud infrastructure.\n\n## What does _cerdito_ do?\n\n_cerdito_ is configured through a _toml_ file in which you can indicate the\nAtlas clusters, AKS or Azure Databricks jobs you want to pause and the\nKubernetes deployments you want to be scaled to zero. Note that each module\ngoes separately so it is possible to use _cerdito_ only to pause Atlas\nclusters, AKS, Azure Databricks or to scale deployments to zero.\n\nTo connect to Atlas you will need a public key and a private API access key,\nfor AKS or Azure Databricks you will need a Service Principal and for\nKubernetes you will need _cubeconfig_ file.\n\n## Installation\n\n### From binary\n\nSimply download latest release from [releases page][releases].\n\n[releases]: https://github.com/Telefonica/cerdito/releases\n\n### From source\n\n#### Installing Rust\n\n_cerdito_ build has been tested with current Rust stable release version.\nYou can install Rust from your distribution package or use\n[`rustup`][rustup].\n```sh\nrustup default stable\n```\n\nIf you prefer, you can use the stable version only for install _cerdito_.\n```sh\nrustup override set stable\n```\n\n[rustup]: https://rustup.rs/\n\n#### Building _cerdito_\n\nTo build _cerdito_ simply execute the following commands.\n```sh\ngit clone git@github.com:Telefonica/cerdito.git\ncd cerdito\ncargo build --release\n```\n\nOnce it finishes building, you will find the binary in the `target/release/`\ndirectory.\n\n### With Docker\n\nBuild docker container.\n```sh\ndocker build -t cerdito .\n```\n\nRun docker container.\n```sh\ndocker run -t -i --rm cerdito\n```\n\nNow you can execute _cerdito_ command. Remember to create a configuration\nfile `cerdito.toml`. If you already have one you can run _cerdito_ directly\nin this way.\n```sh\ndocker run -t -i --rm \\\n  -v $(pwd)/cerdito.toml:/cerdito.toml cerdito \\\n  cerdito -v -c /cerdito.toml SUBCOMMAND\n```\n\n## Run\n\nFirst take a look to `cerdito.toml` file to configure _cerdito_. Is self\nexplanatory.\n\nYou can place `cerdito.toml` in same directory where you run _cerdito_ or\nwhere you want as long as you indicate it from the command line or with the\n`CERDITO_CONFIG` environment variable.\n\nOnce you have configured _cerdito_ you can run `cerdito start` to resume your\ncloud infraestructure or `cerdito stop` to pause it. _cerdito_ has some\ncommand line options to tell it where to read the configuration.\n\n```\nUsage: cerdito [OPTIONS] \u003cCOMMAND\u003e\n\nCommands:\n  start    Start all configured elements\n  stop     Stop all configured elements\n  version  Prints version information\n  help     Print this message or the help of the given subcommand(s)\n\nOptions:\n  -c, --config \u003cconfig\u003e          Custom configuration file path\n  -k, --kubeconfig \u003ckubeconfig\u003e  Custom kubeconfig file path\n  -v, --verbose...               Sets the level of verbosity\n  -h, --help                     Print help\n  -V, --version                  Print version\n```\n\nBy default _cerdito_ does not show anything when it is running, if you want\nto see what it is doing you can launch it with `CERDITO_LOGLEVEL=info`\nenvironment variable or with `-v` option.\n\n_cerdito_ supports the following environment variables.\n\n| Variable | Description |\n| --- | --- |\n| `CERDITO_CONFIG` | Config file location |\n| `CERDITO_LOGLEVEL` | Log level, effective values are `error`, `warn`, `info`, `debug` and `trace` |\n| `MONGODB_ATLAS_PUBLIC_KEY` | Atlas public key, to avoid having to write it in the configuration file |\n| `MONGODB_ATLAS_PRIVATE_KEY` | Atlas private key |\n| `AZURE_TENANT_ID` | Azure tenant ID |\n| `AZURE_CLIENT_ID` | Azure SP client ID |\n| `AZURE_CLIENT_SECRET` | Azure SP client secret |\n| `KUBECONFIG` | Location of kubeconfig file, by default `~/.kube/config` is used (if not specified in the configuration file) |\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftelefonica%2Fcerdito","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftelefonica%2Fcerdito","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftelefonica%2Fcerdito/lists"}