Code Monkey home page Code Monkey logo

cloudnomics's Introduction

Cloudnomics

"#Cloudnomics" is python and bash library to get RateCard and other cloud cost optimization related items from public cloud (Azure for the time-being). The vision of this code base is to be single place to provide VM/Storage level advise for cloud (Azure) optimizations.

Development Machine setup

The base development environment that one needs to install and configure locally for this repository to work:

  1. Clone the Github repository https://github.com/ninadkan/Cloudnomics. whilst setting up, I used PAT authentication to configure bi-directional sync.
  2. My dev machine is a Mac book pro and that is what I do active development on. Meaning tested on bash+python only. Sorry Windows folks
  3. Installed Python3.
  4. Wherever required python environment will be created and called - '.venv'. This is the only name for python environment that'll be used throughout the project. python3 -m venv .venv $ source ./.venv/bin/activate
  5. For unit testing of BASH scripts - downloaded the https://github.com/kward/shunit2. I cloned the git-hub repository and then copied the binary (shutil2) and *.sh files from the root folders on to my /tests folder.
  6. For code coverage, I Installed the 'bashcov' - using the command : sudo gem install bashcov
  7. In order to ensure that spurious files are not added, I added following lines to the .gitignore to the
# Adding following line to ensure that all the environment files are missed.
**/.venv

# ignore anything that is in the output folder
**/output
# for MAC files, ignore the DS_Store
**/.DS_Store

# don't include everything that is part of shunit2 anything that yout don't need to include
**/shunit2-1

# bashcov generates all the code coverage metrics locally under the /coverage folder. Ignore.
**/coverage
  1. The IDE I use is Visual Code. 'shellcheck' extension has been installed to ensure all the bash shell script that I write is linted.

  2. For Python programs, I am using following linter, unit testing and code-coverage tools flake8, pytest, pytest-cov $ pip install flake8 pytest pytest-cov

    Before commit checklist for python programs $ flake8 --statistics output of above should be nothing. The above code should be executed in the folder where python main code resides $ pytest -v --cov run from the tests folder.

Usage

# coming soon ...

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change. Please make sure to update tests as appropriate.

License

MIT

cloudnomics's People

Contributors

ninadkan avatar

Watchers

 avatar  avatar

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.