{"id":19107759,"url":"https://github.com/alleyinteractive/action-deploy-to-remote-repository","last_synced_at":"2025-04-30T18:49:21.171Z","repository":{"id":179486380,"uuid":"663569805","full_name":"alleyinteractive/action-deploy-to-remote-repository","owner":"alleyinteractive","description":"Sync to remote repository via GitHub actions","archived":false,"fork":false,"pushed_at":"2025-04-10T18:54:48.000Z","size":62,"stargazers_count":3,"open_issues_count":1,"forks_count":1,"subscribers_count":21,"default_branch":"develop","last_synced_at":"2025-04-30T18:49:08.618Z","etag":null,"topics":["action","deployment","github-action"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/alleyinteractive.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","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":"2023-07-07T15:47:22.000Z","updated_at":"2025-04-10T13:22:13.000Z","dependencies_parsed_at":null,"dependency_job_id":"b5ea5b81-b07e-4c98-a110-c150e0079eb8","html_url":"https://github.com/alleyinteractive/action-deploy-to-remote-repository","commit_stats":null,"previous_names":["alleyinteractive/action-deploy-to-remote-repository"],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alleyinteractive%2Faction-deploy-to-remote-repository","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alleyinteractive%2Faction-deploy-to-remote-repository/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alleyinteractive%2Faction-deploy-to-remote-repository/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alleyinteractive%2Faction-deploy-to-remote-repository/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/alleyinteractive","download_url":"https://codeload.github.com/alleyinteractive/action-deploy-to-remote-repository/tar.gz/refs/heads/develop","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251765591,"owners_count":21640209,"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":["action","deployment","github-action"],"created_at":"2024-11-09T04:13:52.119Z","updated_at":"2025-04-30T18:49:21.123Z","avatar_url":"https://github.com/alleyinteractive.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Deploy to Remote Repository Action\n\nUses rsync and git to deploy files/folders from a local GitHub action repository\nto a remote repository.\n\n_Notes_:\n\n- We do not leverage external actions to manage the SSH agent as we want to keep\n  the code as simple/single-sourced as possible.\n- We must manually manage the SSH keys for the remote repository. This is\n  typically done by adding the private key to the GitHub action secrets and then\n  adding the public key to the remote repository (e.g., as a write deploy key).\n\n## Usage\n\nExample deploy to a remote repository:\n\n```yml\nname: Deploy to Pantheon Live\n\non:\n  push:\n    branches:\n      - production\n\njobs:\n  build-and-sync:\n    runs-on: ubuntu-latest\n    steps:\n    - name: Checkout code\n      uses: actions/checkout@v3\n\n    - name: Sync to Remote Repository\n      uses: alleyinteractive/action-deploy-to-remote-repository@v1\n      with:\n        remote_repo: 'ssh://user@server/example.git'\n        remote_branch: 'master' # Notable that this differs from 'production'\n        destination_directory: 'wp-content/'\n        exclude_list: '.git, .github, .gitmodules, node_modules'\n        pantheon: 'true'\n        ssh-key: ${{ secrets.REMOTE_REPO_SSH_KEY }}\n```\n\n### `.deployignore`\n\nThe action supports recursively replacing all `.gitignore` files in your project\nwith a root-level `.deployignore` file if one is found. This is useful for\nexcluding files from the deployment that would have previously been ignored by\nversion control (such as built assets and Composer dependencies). The\n`.deployignore` syntax is the same as a normal `.gitignore` file. To skip invoking\nthis behavior, use the `deployignore: 'false'` input.\n\n### Pantheon Mode\n\nPassing `pantheon: 'true'` to the action will enable \"Pantheon\" mode. This mode\nprovides the following features:\n\n- Copies the `.pantheon/pantheon.yml` file (if it exists) to the root of the\n  repository as `pantheon.yml`. This is useful for projects that are rooted at\n  `wp-content` but still want to version control their Pantheon configuration.\n- Copies the `.pantheon/private` directory (if it exists) to the root of the\n  repository as `private`.\n- Automatically adds `.pantheon` and `mu-plugins/pantheon-mu-plugin` to the [exclude list](#exclude_list) to prevent common deployment errors related to these directories.\n\n## Inputs\n\n\u003e Specify using `with` keyword.\n\n### `os`\n\n- Specify the operation system to use.\n- Accepts a string.\n- Defaults to `ubuntu-latest`.\n\n### `remote_repo`\n\n- Specify the remote repository to deploy to.\n- Accepts a string.\n- Required.\n\n### `remote_branch`\n\n- Specify the remote branch to deploy to.\n- Accepts a string.\n- Defaults to the same branch name in the remote repo as the current running\n  action.\n\n### `remote_branch_is_orphan`\n\n- Whether to use the `--orphan` flag when creating the remote branch.\n- Accepts a string. (e.g. `true` or `false`)\n- Defaults to `false`.\n\n### `base_directory`\n\n- Specify the base directory to sync from.\n- Accepts a string.\n- Defaults to the root of the repository (`.`). **NOTE** You likely want a\n  trailing slash if you're syncing a subdirectory. (eg. `wp-content/`)\n\n### `destination_directory`\n\n- Specify the destination directory to sync to.\n- Accepts a string.\n- Defaults to the root of the remote repository (`.`).\n\n### `exclude_list`\n\n- Specify a comma-separated list of files and directories to exclude from sync.\n- Accepts a string. (e.g. `.git, .gitmodules, .github`)\n- Defaults to `.git, .gitmodules, .github`.\n\n### `deployignore`\n\n- Whether to replace `.gitignore` with `.deployignore` if the files exist.\n- Accepts a string. (e.g. `true` or `false`)\n- Defaults to `true`.\n\n### `ssh-key`\n\n- Specify the SSH private key to use for the remote repository.\n- A corresponding public key must be added as a deploy key to the remote repository with write access.\n- Should reference a GitHub secret. See above for an example. The actual private key should be stored in secrets, and never committed to the repository.\n- Required.\n\n### `pantheon`\n\n- Determine if this is a deployment for a Pantheon repository. See [Pantheon Mode](#pantheon-mode) for more details.\n- Accepts a string. (e.g. `true` or `false`)\n- Defaults to `false`.\n\n## Changelog\n\nPlease see [CHANGELOG](CHANGELOG.md) for more information on what has changed\nrecently.\n\n## Credits\n\nThis project is actively maintained by [Alley\nInteractive](https://github.com/alleyinteractive).\n\n- [Ben Bolton](https://github.com/benpbolton)\n- [All Contributors](../../contributors)\n\n## License\n\nThe GNU General Public License (GPL) license. Please see [License File](LICENSE)\nfor more information.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falleyinteractive%2Faction-deploy-to-remote-repository","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falleyinteractive%2Faction-deploy-to-remote-repository","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falleyinteractive%2Faction-deploy-to-remote-repository/lists"}