All Projects → centerorbit → depcharge

centerorbit / depcharge

Licence: MIT license
DepCharge is a tool designed to help orchestrate the execution of commands across many directories at once.

Programming Languages

go
31211 projects - #10 most used programming language
Dockerfile
14818 projects
shell
77523 projects

Projects that are alternatives of or similar to depcharge

mcollective-choria
Distribution of plugins for MCollective as found in Puppet 6
Stars: ✭ 58 (+152.17%)
Mutual labels:  orchestration, mcollective
stackbuilder
Stackbuilder builds stacks of virtual machines
Stars: ✭ 21 (-8.7%)
Mutual labels:  orchestration, mcollective
esdc-ce
Danube Cloud :: Community Edition
Stars: ✭ 101 (+339.13%)
Mutual labels:  orchestration
manager
The API endpoint that manages nebula orchestrator clusters
Stars: ✭ 28 (+21.74%)
Mutual labels:  orchestration
poetry.el
Python dependency management and packaging in Emacs
Stars: ✭ 110 (+378.26%)
Mutual labels:  dependency-manager
orkestra
The elegance of Airflow + the power of AWS
Stars: ✭ 42 (+82.61%)
Mutual labels:  orchestration
kebechet
I'm Kebechet bot, goddess of freshness - I will keep your source code fresh and up-to-date
Stars: ✭ 23 (+0%)
Mutual labels:  dependency-manager
FactoryOrchestrator
A cross-platform system service which provides a simple way to run and manage factory line validation, developer inner-loop, diagnostics, and fault analysis workflows.
Stars: ✭ 36 (+56.52%)
Mutual labels:  orchestration
qompoter
Dependency manager for Qt / C++.
Stars: ✭ 19 (-17.39%)
Mutual labels:  dependency-manager
bascomtask
Lightweight parallel Java tasks
Stars: ✭ 49 (+113.04%)
Mutual labels:  orchestration
BinaryProvider.jl
A reliable binary provider for Julia
Stars: ✭ 42 (+82.61%)
Mutual labels:  dependency-manager
vanat
🔨 Dependency Manager for Vala 🚧 App under development!
Stars: ✭ 14 (-39.13%)
Mutual labels:  dependency-manager
akk-stack
Containerized EverQuest Emulator Server Environment
Stars: ✭ 36 (+56.52%)
Mutual labels:  orchestration
verchew
System dependency version checker.
Stars: ✭ 24 (+4.35%)
Mutual labels:  dependency-manager
py-dependency-install
A GitHub Action that installs Python package dependencies from a user-defined requirements.txt file path with optional pip, setuptools, and wheel installs/updates
Stars: ✭ 23 (+0%)
Mutual labels:  dependency-manager
rubigo
[DEPRECATED] Golang vendor utility and package manager
Stars: ✭ 44 (+91.3%)
Mutual labels:  dependency-manager
fuseml
FuseML aims to provide an MLOps framework as the medium dynamically integrating together the AI/ML tools of your choice. It's an extensible tool built through collaboration, where Data Engineers and DevOps Engineers can come together and contribute with reusable integration code.
Stars: ✭ 73 (+217.39%)
Mutual labels:  orchestration
firewall-orchestrator
Network Security data repository for automation, reporting and compliance of firewall rules
Stars: ✭ 14 (-39.13%)
Mutual labels:  orchestration
PainlessDocker
Painless Docker book git repository.
Stars: ✭ 17 (-26.09%)
Mutual labels:  orchestration
nsolid-kubernetes
Using N|Solid, the Enterprise Node Platform from NodeSource with Kubernetes
Stars: ✭ 82 (+256.52%)
Mutual labels:  orchestration

DepCharge

Go Report Card Build Status coverage report GitHub license GitHub release Maintainability

DepCharge is a tool that helps orchestrate the execution of commands across the many dependencies and directories in larger projects. It also provides an excellent mechanism for self-documenting a project's vast (and often disparate) dependencies.

Sneak peek:

depcharge --labels=api -- git clone {{repo}} {{location}}

Will run git clone across all listed git dependencies with the label of "api" in your project (where submodules use to rule the land)

Introduction

By creating a YAML file that describes all of your project(s) dependencies, you can then execute commands across all of them simultaneously.

A medium-to-large sized project (especially when using a microservice architecture) will consist of 3 or more separate repositories, and rely on a variety of package managers depending on the various languages chosen for each service. Typically, these repos must be managed, tracked, and released in some semblance of unison so that the dependant service calls can be understood and responded to appropriately.

For small (to single) teams, a single developer will often need to propagating and perform the same commands across all relevant services. This is a tedious, manual, and error-prone process that can occur every release.

DepCharge is designed to help fix that.

How it Works & Usage

DepCharge is a tool designed to help orchestrate the execution of commands across many directories at once. All of the examples here are just that: examples. DepCharge is designed to be as flexible as possible, so if you happen to use tools other than what's listed, they should work as well!

Usage: depcharge [version] [--help|-h] [--dryrun|-d] [--force|-f] [--kind|-k=<kind>] [--instead|-x=<action>] [[--include|-i][-e|--exclude]] [--labels|-l=<comma-separated,inherited>] [--serial|-s] -- COMMAND [ARGS...]

Features:

  • Built-in mustache templating, allows you to parametrize your commands
  • Supports arbitrary params in YAML, whatever 'params: key: value' pairs you want (particularly useful for mustache templating)
  • Supports YAML anchors
    • Even went the extra mile to support anchors + sequence merging via merge-deps: (see: YAML Anchors & Sequences)

Description:

depcharge will read the dep.yml file in the current working directory, and perform all commands relative to that location.

Example dep.yml:

deps:
    - name: frontend
      kind: git
      location: ./app/frontend
      labels:
        - public
      params:
        repo: [email protected]:frontend.git
      deps:
        - name: vue.js
          kind: npm
    - name: backend
      kind: git
      location: ./app/backend
      labels:
        - api
      params:
        repo: [email protected]:backend.git
      deps:
        - name: lumen
          kind: composer

Flags

   --version  Displays the program version string.
-h --help  Displays help with available flag, subcommand, and positional value parameters.
-d --dryrun  Will print out the command to be run, does not make changes to your system.
-e --exclusive  Applies labels in an exclusive way (default).
-f --force  Will force-run a command without confirmations, could be dangerous.
-i --inclusive  Applies labels in an inclusive way.
-k --kind  Targets specific kinds of dependencies (i.e. git, npm, composer)
-l --labels  Filters to specific labels.
-s --serial  Prevents parallel execution, runs commands one at a time.
-x --instead  Instead of 'kind', perform a different command.

Example commands:

Will run git clone <repo> <location> across all git dependencies:

depcharge --kind=git -- clone {{repo}} {{location}}

Or, shorthand:

depcharge -- git clone {{repo}} {{location}}

Will run git status across all git dependencies:

depcharge -- git status

Will run npm install across any npm dependencies that have the label 'public':

depcharge --labels=public -- npm install

Will run composer install across any composer dependencies that have either the label 'api', or 'soap':

depcharge --inclusive --labels=api,soap -- composer install

And much more!

YAML Anchors & Sequences

Due to a limitation in YAML itself, you cannot use anchors to merge sequences (arrays). Therefore this is programatically supported within DepCharge.

Invalid YAML, you cannot mix sequences - with anchors *<name> directly, this doesn't work:

...
    deps:
      - kind: git
      - *composer
      - *vue
...

It's a beautiful concept though, that really helps with reusability and simplifies the overall YAML file, and so merge-deps was introduced to work around this shortcoming.

Working around this with merge-deps:

.vue: &vue
  - name: Vue.js
    kind: npm
.composer: &composer
  - name: lumen
    kind: composer
    
deps:
  - name: ui
    kind: project
    location: ./code/app
    labels:
      - ui
    deps:
      - kind: git
        params:
          repo: [email protected]/ui.git
    merge-deps:
      - *composer
      - *vue

In the above example, merge-deps: supports listing your anchors, and these will then be expanded, then flattened and merged into deps: before final processing begins.

Special Action Handlers

DepCharge has the ability to offer special-case action handlers. Specifically for situations where executing bulk commands cause difficulties and/or there are unexpected rough edges.

  1. git clone This is treated specially, in the sense that a regular clone will not act if parent directories aren't already in place. DepCharge will detect the clone action explicitly and attempt to create any parent directories before passing the command directly onto git

Additional Resources

Contributing

See: CONTRIBUTING.md

License

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].