Skip to content

Commit

Permalink
Merge pull request #49 from weirdan/ghcr
Browse files Browse the repository at this point in the history
  • Loading branch information
weirdan authored Mar 4, 2023
2 parents 5dd7096 + 47ad914 commit d0e610e
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 16 deletions.
17 changes: 12 additions & 5 deletions .github/workflows/watch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ jobs:
docker:
name: Push tagged docker image
runs-on: ubuntu-latest
permissions:
contents: read
packages: write

steps:
- name: Checkout code
Expand All @@ -26,14 +29,18 @@ jobs:
sed -i -re "s/require vimeo\/psalm/require vimeo\/psalm:$last/" Dockerfile
cat Dockerfile
- name: Docker login
uses: docker/login-action@v2
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build images
run: docker build -t vimeo/psalm-github-actions:${{ steps.fetch_version.outputs.last }} .
run: docker build -t ghcr.io/psalm/psalm-github-actions:${{ steps.fetch_version.outputs.last }} -t ghcr.io/psalm/psalm-github-actions:latest .

- name: Publish
run: docker push vimeo/psalm-github-actions:${{ steps.fetch_version.outputs.last }}
run: |
docker push ghcr.io/psalm/psalm-github-actions:${{ steps.fetch_version.outputs.last }}
docker push ghcr.io/psalm/psalm-github-actions:latest
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
uses: actions/checkout@v2

- name: Psalm
uses: docker://vimeo/psalm-github-actions
uses: docker://ghcr.io/psalm/psalm-github-actions

```

Expand All @@ -26,8 +26,8 @@ You can also specify a version (after 3.14.2).

```diff
- name: Psalm
- uses: docker://vimeo/psalm-github-actions
+ uses: docker://vimeo/psalm-github-actions:3.14.2
- uses: docker://ghcr.io/psalm/psalm-github-actions
+ uses: docker://ghcr.io/psalm/psalm-github-actions:5.7.7
```

## Use Security Analysis
Expand All @@ -36,7 +36,7 @@ Psalm supports [Security Analysis](https://psalm.dev/docs/security_analysis/). Y

```diff
- name: Psalm
uses: docker://vimeo/psalm-github-actions
uses: docker://ghcr.io/psalm/psalm-github-actions
+ with:
+ security_analysis: true
```
Expand All @@ -49,7 +49,7 @@ Use the following config:

```diff
- name: Psalm
uses: docker://vimeo/psalm-github-actions
uses: docker://ghcr.io/psalm/psalm-github-actions
+ with:
+ security_analysis: true
+ report_file: results.sarif
Expand All @@ -67,7 +67,7 @@ These are both set to false by default.

```diff
- name: Psalm
uses: docker://vimeo/psalm-github-actions
uses: docker://ghcr.io/psalm/psalm-github-actions
+ with:
+ composer_require_dev: true
+ composer_ignore_platform_reqs: true
Expand All @@ -81,7 +81,7 @@ Use the following config:

```diff
- name: Psalm
uses: docker://vimeo/psalm-github-actions
uses: docker://ghcr.io/psalm/psalm-github-actions
+ with:
+ relative_dir: ./subdir
```
Expand All @@ -102,12 +102,12 @@ jobs:
...

- name: Psalm
uses: docker://vimeo/psalm-github-actions
uses: docker://ghcr.io/psalm/psalm-github-actions
with:
ssh_key: ${{ secrets.SOME_PRIVATE_KEY }}
ssh_key_pub: ${{ secrets.SOME_PUBLIC_KEY }}
# Optional:
ssh_domain: my-own-github.com
```
github.com, gitlab.com and bitbucket.org are automatically added to the list of SSH known hosts. You can provide your own domain via `ssh_domain` input.
github.com, gitlab.com and bitbucket.org are automatically added to the list of SSH known hosts. You can provide your own domain via `ssh_domain` input.
3 changes: 1 addition & 2 deletions action.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

# https://help.github.com/en/articles/metadata-syntax-for-github-actions

author: 'muglug'
Expand Down Expand Up @@ -45,4 +44,4 @@ inputs:

runs:
using: 'docker'
image: 'docker://vimeo/psalm-github-actions'
image: 'docker://ghcr.io/psalm/psalm-github-actions'

0 comments on commit d0e610e

Please sign in to comment.