https://github.com/webfactory/docker-psalm
Docker image to run vimeo/psalm
https://github.com/webfactory/docker-psalm
Last synced: 4 months ago
JSON representation
Docker image to run vimeo/psalm
- Host: GitHub
- URL: https://github.com/webfactory/docker-psalm
- Owner: webfactory
- License: mit
- Created: 2021-09-22T06:43:07.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2024-08-23T15:24:03.000Z (10 months ago)
- Last Synced: 2024-12-29T08:26:06.670Z (6 months ago)
- Language: Dockerfile
- Size: 23.4 KB
- Stars: 0
- Watchers: 5
- Forks: 2
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Docker Image for `vimeo/psalm`
This repository contains everything to build a simple Docker image to run [Psalm](https://github.com/vimeo/psalm/). The image will also include a few Psalm plugins.
The image is built for the `amd64` and `arm64` platforms. A GitHub Actions workflow is used to build the image weekly, so the PHP version used should be up-to-date and new Psalm versions should show up automatically.
## Running the Published Image
The resulting image is published at https://ghcr.io/webfactory/psalm.
To use it: `docker run -it --rm --init -v $(pwd):/app ghcr.io/webfactory/psalm`, possibly followed by `psalm` arguments and options.
If you want to use `psalm-plugin` to list, enable or otherwise deal with plugins, use:
`docker run -it --rm --init -v $(pwd):/app --entrypoint=psalm-plugin ghcr.io/webfactory/psalm`, possibly followed by `psalm-plugin` arguments and options.
### Using a Cache for Psalm
If you want to use Psalm's caching feature to speed up analysis, mount a directory or Docker volume at `/cache`.
For example, run `docker run -it --rm --init -v $(pwd):/app -v $HOME/.cache:/cache ghcr.io/webfactory/psalm ...`
## Building the Image yourself
Review and/or tweak the `Dockerfile` as necessary.
Then, run `docker build -t psalm .`.
To use your own image, use `psalm` instead of `ghcr.io/webfactory/psalm` in the commands from the previous section.