{"id":23359779,"url":"https://github.com/firehed/deploy-command","last_synced_at":"2026-03-14T15:34:48.308Z","repository":{"id":62504915,"uuid":"138363263","full_name":"Firehed/deploy-command","owner":"Firehed","description":"Symfony Console Deployment Command","archived":false,"fork":false,"pushed_at":"2024-07-10T01:52:37.000Z","size":23,"stargazers_count":0,"open_issues_count":7,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-18T22:40:11.444Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","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/Firehed.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-06-23T01:55:58.000Z","updated_at":"2020-09-30T01:26:12.000Z","dependencies_parsed_at":"2024-12-21T11:12:08.821Z","dependency_job_id":"b80cf3c3-8735-47cf-8f0c-15aa1e44952c","html_url":"https://github.com/Firehed/deploy-command","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Firehed%2Fdeploy-command","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Firehed%2Fdeploy-command/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Firehed%2Fdeploy-command/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Firehed%2Fdeploy-command/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Firehed","download_url":"https://codeload.github.com/Firehed/deploy-command/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243188235,"owners_count":20250457,"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-12-21T11:11:57.327Z","updated_at":"2025-12-17T23:03:51.615Z","avatar_url":"https://github.com/Firehed.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Symfony Console Deploy Command\n\n[![Latest Stable Version](https://poser.pugx.org/firehed/deploy-command/v)](//packagist.org/packages/firehed/deploy-command)\n[![License](https://poser.pugx.org/firehed/deploy-command/license)](//packagist.org/packages/firehed/deploy-command)\n\n[![Test](https://github.com/Firehed/deploy-command/workflows/Test/badge.svg)](https://github.com/Firehed/deploy-command/actions?query=workflow%3ATest)\n[![Lint](https://github.com/Firehed/deploy-command/workflows/Lint/badge.svg)](https://github.com/Firehed/deploy-command/actions?query=workflow%3ALint)\n[![Static analysis](https://github.com/Firehed/deploy-command/workflows/Static%20analysis/badge.svg)](https://github.com/Firehed/deploy-command/actions?query=workflow%3A%22Static+analysis%22)\n[![codecov](https://codecov.io/gh/Firehed/deploy-command/branch/master/graph/badge.svg)](https://codecov.io/gh/Firehed/deploy-command)\n\nThis is a premade Symfony Console component to manually deploy your application.\nAt this time, it only supports deployment to Kubernetes via `kubectl`.\nDeploying multiple images at once _is_ supported.\n\nUltimately, it's a fancy wrapper around running `kubectl set image deploy ...`.\n\n## Configuration and Usage\n\n`composer require firehed/deploy-command`\n\nSomewhere in your existing Symfony Console setup or config:\n\n```php\n$targets = [\n    [\n        'container' =\u003e 'your-container-name',\n        'deployment' =\u003e 'your-deployment-name',\n        'image' =\u003e 'yourco/yourimage:$IMAGE',\n        'namespace' =\u003e 'your-deployment-namespace',\n    ], [\n        // Another thing to deploy at the same time\n    ]\n];\n$kubectl = new Firehed\\Console\\Deploy\\Kubectl($targets);\n$deploy = new Firehed\\Console\\Deploy($kubectl);\n\n$application = new Symfony\\Component\\Console\\Application();\n// ...\n$application-\u003eadd($deploy);\n$application-\u003erun();\n```\n\nIn your `image`, `$IMAGE` will be substituted with the commit hash of the command argument, or that of `master`.\nIt is NOT a PHP variable in the above example (note single quotes).\n`namespace` is optional, and will default to Kubernetes' `default`.\n\n### Event hooks\n\nThe deploy command will run any event hooks you request before or after the deployment process runs.\nTo register a hook, call `$deploy-\u003ebefore($hook);` or `$deploy-\u003eafter($hook);`\nThe hook must be a callable with the signature `function (string $hash, string $revision, bool $isDryRun)`.\nHooks were designed primarily for sending notifications (e.g. posting to Slack) but can be used for whatever you want.\n\n## Requirements and Limitations\n\nThis only works in git repositories, and expects that your docker image will be tagged with the full 40-character commit hash (e.g. `yourname/yourfancyproject:92dac20583b35ea7167366bbf0b24243016911c0`).\nThis is only a deployment tool, and does not perform the builds.\n\nAll of the images deployed will use the same hash, and all deploy together.\nSelective deployment is not supported at this time.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffirehed%2Fdeploy-command","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffirehed%2Fdeploy-command","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffirehed%2Fdeploy-command/lists"}