Skip to content

Commit

Permalink
docs: correction of README errors thanks to user feedback (fix #4)
Browse files Browse the repository at this point in the history
  • Loading branch information
josephpage committed Aug 21, 2023
1 parent 87fe86e commit 8d56a62
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 13 deletions.
1 change: 1 addition & 0 deletions .github/workflows/release-please.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ jobs:
with:
release-type: simple
package-name: ${{ env.ACTION_NAME }}
extra-files: README.md
token: ${{ secrets.GITHUB_TOKEN }}
- uses: actions/checkout@v2
if: ${{ steps.release.outputs.release_created }}
Expand Down
34 changes: 21 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,30 +7,34 @@ The `scalingo-community/setup-scalingo` action is a composite action that sets u

After you've used the action, subsequent steps in the same job can run arbitrary Scalingo commands using the GitHub Actions `run:` syntax. This allows most Scalingo commands to work exactly like they do on your local command line


## Usage

This action can be run on `ubuntu-latest` and `macos-latest` GitHub Actions runners. Note that the `region` input is always required.

The default configuration installs the latest version of Scalingo CLI:
```
<!-- x-release-please-start-version -->
```yaml
steps:
- uses: scalingo-community/setup-scalingo@v1
- uses: scalingo-community/setup-scalingo@v0.1.1
with:
region: 'osc-fr1'
```
<!-- x-release-please-end -->
Subsequent steps can launch command with the configured and authenticated CLI (you can create API Token [in the Scalingo dashboard](https://dashboard.scalingo.com/account/tokens)):
```
<!-- x-release-please-start-version -->
```yaml
steps:
- uses: scalingo-community/setup-scalingo@v1
- uses: scalingo-community/setup-scalingo@v0.1.1
with:
region: 'osc-fr1'
api_token: '${{ secrets.scalingo_api_token }}
api_token: ${{ secrets.scalingo_api_token }}
app_name: 'my_app'

- run: scalingo restart # will restart all the processes of the app "my_app" in region "osc-fr1"
```

<!-- x-release-please-end -->
## Inputs
Expand All @@ -54,33 +58,37 @@ For testing or debugging purpose, the following inputs can also be used:
- `scalingo_db_url` - The Scalingo DB URL to use. If not provided, the action will use the default DB URL for the given region.
- `scalingo_ssh_host` - The Scalingo SSH Host to use. If not provided, the action will use the default SSH Host for the given region.


## Features

### Git remote auto-configuration

If the code you provide the `region` and `app_name` inputs, the action will automatically configure a Git remote named `scalingo` to allow git operations on your app. This is useful if you want to run `git push scalingo master` in your workflow.

```
<!-- x-release-please-start-version -->
```yaml
steps:
- name: Checkout code
uses: actions/checkout@v3
- Configure Scalingo CLI
uses: scalingo-community/setup-scalingo@v1
- name: Configure Scalingo CLI
uses: scalingo-community/setup-scalingo@v0.1.1
with:
region: 'osc-fr1'
app_name: 'my_app'
- name: Deploy to Scalingo with Git
run: git push scalingo main
```
<!-- x-release-please-end -->


### Custom version of Scalingo CLI

You can install a specific version of Scalingo CLI:
```
<!-- x-release-please-start-version -->
```yaml
steps:
- uses: scalingo-community/setup-scalingo@v1
- uses: scalingo-community/setup-scalingo@v0.1.1
with:
region: 'osc-fr1'
version: 1.28.2
```

<!-- x-release-please-end -->

0 comments on commit 8d56a62

Please sign in to comment.