{"id":21589724,"url":"https://github.com/typecode/sykle","last_synced_at":"2026-04-02T01:57:27.184Z","repository":{"id":42686570,"uuid":"147723945","full_name":"typecode/sykle","owner":"typecode","description":"Rake like tool for coordinating docker-compose projects","archived":false,"fork":false,"pushed_at":"2025-06-24T20:35:16.000Z","size":181,"stargazers_count":0,"open_issues_count":9,"forks_count":1,"subscribers_count":8,"default_branch":"develop","last_synced_at":"2025-06-24T21:38:36.912Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/typecode.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2018-09-06T19:35:19.000Z","updated_at":"2025-06-24T20:35:19.000Z","dependencies_parsed_at":"2025-03-18T09:44:17.197Z","dependency_job_id":"87c31b44-acca-4a1e-bc4c-bfd5091b73cb","html_url":"https://github.com/typecode/sykle","commit_stats":null,"previous_names":[],"tags_count":24,"template":false,"template_full_name":null,"purl":"pkg:github/typecode/sykle","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/typecode%2Fsykle","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/typecode%2Fsykle/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/typecode%2Fsykle/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/typecode%2Fsykle/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/typecode","download_url":"https://codeload.github.com/typecode/sykle/tar.gz/refs/heads/develop","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/typecode%2Fsykle/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265738510,"owners_count":23820165,"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":[],"created_at":"2024-11-24T16:15:35.215Z","updated_at":"2026-04-02T01:57:27.096Z","avatar_url":"https://github.com/typecode.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# sykle\n\nSykle is a cli tool for calling commonly used commands in Docker Compose projects.\n\n#### What sykle does\n\n- Enforces 3 Docker Compose environments: `dev`, `test`, and `prod`\n- Provides commands for spinning up dev, running tests, and deploying to prod\n  - (Assumes you are deploying to a single remote instance running Docker Compose)\n- Allows you to write aliases for commonly used commands that run on specific Docker Compose services\n- Provides additional commonly used devops commands (which may or may not run through Docker Compose) via plugins\n\n#### What sykle does not do\n\n- Does not spin up remote instances (may add Terraform in the future to do this)\n- Does not generate Dockerfiles, Docker Compose files, etc\n- Does not replace standard devops tools\n  - (plugins should delegate to other tools)\n\n### Requirements\n\n- `python 3.4` (may work on earlier versions of 3, but not tested. Plugins do NOT work in python version 2.7)\n- `docker` (locally and on deployment target)\n- `docker compose` (locally and on deployment target)\n- `ssh`\n- `scp`\n\n### Installation\n\n#### If python3 is your default installation, you can use pip\n\n`pip install git+ssh://git@github.com/typecode/sykle.git --upgrade`\n\n#### If you have a separate `python3` installation, you should use pip3\n\n`pip3 install git+ssh://git@github.com/typecode/sykle.git --upgrade`\n\n### Configuration\n\nBecause sykle tries to make as few assumptions about your project as possible, you'll need to declaratively define how your app should run via static configuration files\n\n#### Docker Compose\n\nSykle uses 4 different Docker Compose configurations:\n\n- `docker-compose.yml` for development\n- `docker-compose.test.yml` for testing\n- `docker-compose.prod-build.yml` for building/deploying production\n- `docker-compose.prod.yml` for running production\n\nThese separate configurations allow you to tweak how your projects run in those 4 standard scenarios, and helps ensure that there no conflicting assumptions between environments.\n\n#### .sykle.json\n\nIn addition to your Docker Compose files, you'll need a `.sykle.json`. An example detailing how to build a config file can be viewed from the cli via `syk config`\n\n### Usage\n\nUsage instructions can be viewed after installation with `syk --help`\n\nThis will not show any info for plugins. In order to view installed plugins, run `syk plugins`. To view help for a specfic plugin, run `syk \u003cplugin_name\u003e --help`.\n\n### Legacy ./run.sh\n\nPrior to sykle, the predominate pattern at typecode was to create a `./run.sh` file with a list of commands. For convenience, if a `./run.sh` file is found, sykle will try to run commands through `./run.sh` before running through sykle.\n\n### Connecting to Deployments\n\nOnce you have configured deployments, you can connect to them using `syk --deployment=\u003cdeployment\u003e ssh`. Sykle does not currently allow you pass any options when sshing into a remove machine and relies on `~/.ssh/config` to pass along the correct credentials. An example config is shown below, and more details on ssh config can be found [here](https://linuxize.com/post/using-the-ssh-config-file/).\n\n```\nHost ec2-3-95-177-93.compute-1.amazonaws.com\n  User ubuntu\n  AddKeysToAgent yes\n  UseKeychain yes\n  IdentityFile ~/.ssh/flir-pb.pem\n```\n\n### Running Tests (for sykle)\n\nUnittests (that test sykle) can be run via `python setup.py test`\n\n### Writing plugins\n\nThere are two types of plugins: **global** plugins and **local** plugins.\n\n#### Local Plugins\n\nLocal plugins allow you to create project specific commands. If you have a command or series of commands that you run frequently for a project that are more complicated than an alias, it might make sense to create a local plugin.\n\nTo create a local plugin:\n\n1. Create a `.sykle-plugins/` directory in the root of your project (`.sykle-plugins/` should be in same directory as `.sykle.json`)\n2. Add an `__init__.py` file to `.sykle-plugins/`\n3. Add a python file for your plugin to `.sykle-plugins/` (EX: `.sykle-plugins/my_plugin.py`)\n4. Define your plugin like in the example below:\n\nExample\n```py\n\"\"\"my_plugin\nUsage:\n  syk my_plugin \u003cstr\u003e\n\nOptions:\n  -h --help                     Show help info\n\nDescription:\n  my_plugin                     prints out the string passed in as an argument\n\"\"\"\nfrom docopt import docopt\nfrom sykle.plugin_utils import IPlugin\n\n\nclass Plugin(IPlugin): # class MUST be named Plugin\n    NAME = 'my_plugin' # this attribue is required\n    REQUIRED_VERSION = '0.3.0' # this attribute is option (specifies lowest version of sykle required)\n\n    # this is what gets invoked when you run `syk my_plugins hi`\n    def run(self):\n        args = docopt(__doc__)\n        str = args.get('\u003cstr\u003e')\n        # self.sykle        \u003c- sykle instance\n        # self.sykle_config \u003c- config used by sykle instance\n        # self.config       \u003c- any config specific to this plugin\n        print(str)\n```\n\nNote that `syk` is present in the docopt usage definition before the plugin command. This is required.\n\nIf you defined your plugin correctly, you should be able to see listed when calling `syk plugins`\n\n#### Global Plugins\n\nGlobal plugins are the same as local plugins, but they are added to the `plugins` folder of this repo and are available to anyone who installs sykle.\n\n### Roadmap\n\n- [x] Move to separate repo\n- [x] Allow user to specify `test` commands\n- [x] Add plugins\n- [x] Add `init` command to create `.sykle.json`\n- [x] ~Scripts section in `.sykle.json`~ Local plugins\n-  ~REAMDE.md generation on commit~ (unecessarily complex)\n- [x] Fallback to `./run.sh` if it exists and `.sykle.json` does not\n- [ ] User aliases/way to share aliases\n- [ ] Terraform support\n- [ ] Revisit whether Docker Compose files can/should be shared\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftypecode%2Fsykle","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftypecode%2Fsykle","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftypecode%2Fsykle/lists"}