{"id":17139129,"url":"https://github.com/virb3/http-ci-deployer","last_synced_at":"2025-02-23T05:31:36.466Z","repository":{"id":38345189,"uuid":"180642517","full_name":"ViRb3/http-ci-deployer","owner":"ViRb3","description":"An extremely simple HTTP-based deployment solution for Continuous Integration services","archived":true,"fork":false,"pushed_at":"2024-07-04T16:46:54.000Z","size":235,"stargazers_count":6,"open_issues_count":8,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-02-12T09:32:29.803Z","etag":null,"topics":["ci","continuous-deployment","continuous-integration","deploy","gitlab","golang","http"],"latest_commit_sha":null,"homepage":null,"language":"Go","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/ViRb3.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}},"created_at":"2019-04-10T18:38:58.000Z","updated_at":"2024-08-06T20:49:02.000Z","dependencies_parsed_at":"2024-04-19T17:26:57.103Z","dependency_job_id":null,"html_url":"https://github.com/ViRb3/http-ci-deployer","commit_stats":null,"previous_names":[],"tags_count":34,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ViRb3%2Fhttp-ci-deployer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ViRb3%2Fhttp-ci-deployer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ViRb3%2Fhttp-ci-deployer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ViRb3%2Fhttp-ci-deployer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ViRb3","download_url":"https://codeload.github.com/ViRb3/http-ci-deployer/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240275853,"owners_count":19775612,"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":["ci","continuous-deployment","continuous-integration","deploy","gitlab","golang","http"],"created_at":"2024-10-14T20:11:28.157Z","updated_at":"2025-02-23T05:31:36.172Z","avatar_url":"https://github.com/ViRb3.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# HTTP CI Deployer\nAn extremely simple HTTP-based deployment solution for Continuous Integration services. Originally designed as a safer, simpler alternative to SSH and SCP for GitLab's CI/CD.\n\n## Usage\n### General\nA single wildcard endpoint is exposed:\n```\n/deploy/*\n```\nIf you want to deploy `localfile.zip` to `archive/localfile.zip`, you would submit a `POST` request to: `/deploy/archive/localfile.zip`, with the file content as form data and the deployment key as a `KEY` header.\n\nNote that all deployment paths are relative to the working directory of the deployer binary!\n\n### Curl command\n```bash\ncurl -F file=@localfile.zip -H \"KEY: 123\" \"https://website.com/deploy/archive/localfile.zip\"\n```\n\n### CI/CD\nExample variables:\n* DEPLOY_FILE: `localfile.zip`\n\nExample secrets:\n* DEPLOY_KEY: `123`\n* DEPLOY_URL: `https://website.com/deploy/archive`\n\n#### Drone CI\n```yml\nsteps:\n- name: deploy\n  image: alpine\n  environment:\n    DEPLOY_KEY:\n      from_secret: DEPLOY_KEY\n    DEPLOY_URL:\n      from_secret: DEPLOY_URL\n  commands:\n  - apk add --no-cache curl\n  - \u003e\n    STATUS=$(curl --write-out %{http_code} --silent --output /dev/null\n    -F file=@$DEPLOY_FILE -H \"KEY: $DEPLOY_KEY\" \"$DEPLOY_URL/$DEPLOY_FILE\")\n  - \u003e\n    echo \"Result: $STATUS\"\n  - \u003e\n    [ \"$STATUS\" = \"200\" ] || exit 1\n```\n\n#### GitLab\n```yml\ndeploy:\n  image: ubuntu\n  stage: alpine\n  before_script:\n    - apk add --no-cache curl\n  script:\n    - \u003e\n      STATUS=$(curl --write-out %{http_code} --silent --output /dev/null\n      -F file=@$DEPLOY_FILE -H \"KEY: $DEPLOY_KEY\" \"$DEPLOY_URL/$DEPLOY_FILE\")\n    - \u003e\n      echo \"Result: $STATUS\"\n    - \u003e\n      [ \"$STATUS\" == \"200\" ] || exit 1\n```\n\n## Installation\n1. Set a deployment key in `key.txt` in the deployer's working directory. It must be longer than **10 characters** or you will get a `bad key` error.\n```bash\necho \"SUPER_LONG_AND_SECRET_KEY\" \u003e key.txt\n```\n\n2. Run the webserver\n```bash\n/home/deploy/deployer-amd64 --port 5000\n```\n\n3. *(optional)* Install the systemd unit [deployer.service](deployer.service). Make sure you tweak or satisfy the configuration inside it.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvirb3%2Fhttp-ci-deployer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvirb3%2Fhttp-ci-deployer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvirb3%2Fhttp-ci-deployer/lists"}