deployphp/README.md

44 lines
881 B
Markdown
Raw Normal View History

2020-11-11 01:10:29 +00:00
# GitHub Action for Deployer
2020-11-10 22:49:10 +00:00
2020-11-13 20:47:43 +00:00
```yaml
- name: Deploy
2021-10-15 20:41:21 +00:00
uses: deployphp/action@1
2020-11-13 20:47:43 +00:00
with:
private-key: ${{ secrets.PRIVATE_KEY }}
2021-10-15 20:41:21 +00:00
dep: deploy all
2020-11-13 20:47:43 +00:00
```
2020-11-13 20:45:33 +00:00
2020-11-13 20:47:43 +00:00
## Inputs
2020-11-13 20:45:33 +00:00
2021-10-15 20:41:21 +00:00
See [action.yaml](action.yaml).
2020-11-13 20:45:33 +00:00
## Deployer version
2021-10-15 20:41:21 +00:00
First, the action will check for Deployer binary at those paths:
2020-11-13 20:45:33 +00:00
- `vendor/bin/dep`
- `deployer.phar`
2020-11-13 20:46:12 +00:00
2021-10-15 20:41:21 +00:00
If the binary not found, phar version will be downloaded from
[deployer.org](https://deployer.org/download).
2020-11-10 22:49:10 +00:00
## Example
```yaml
deploy:
name: Deploy to prod
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Setup PHP
uses: shivammathur/setup-php@master
with:
php-version: 7.4
- name: Deploy
uses: deployphp/action@master
2020-11-10 22:49:10 +00:00
with:
private-key: ${{ secrets.PRIVATE_KEY }}
known-hosts: ${{ secrets.KNOWN_HOSTS }}
2021-05-01 09:32:31 +00:00
ssh-config: ${{ secrets.SSH_CONFIG }}
2020-11-10 22:49:10 +00:00
dep: deploy prod -v
```