Prospector container image intended for use in both CI pipelines and local environments.
Build the container locally by running $ docker build -t prospector .
To run prospector
against code in the current directory using the image
from Docker Hub:
$ docker run --rm -it -v ${PWD}:/app:ro,Z badpacketsllc/prospector
To run prospector
against code in the current directory using the image
built locally from source:
$ docker run --rm -it -v ${PWD}:/app:ro,Z prospector
To run this image in your GitLab CI pipeline, you can add a .gitlab-ci.yml
file to your repository that looks like:
stages:
- lint
prospector:
stage: lint
image:
name: badpacketsllc/prospector
entrypoint: [""]
script: prospector
In order to keep code quality high, all merges must pass tests and static analysis.
$ pip3 install -r requirements-dev.txt
$ yamllint .
$ prospector ./test/test_build.py
$ pytest
Locally, using act
act
is a library that allows you to test GitHub Actions locally. To get
started, first install act
.
Once you have act
installed, you may run act
to simulate the merge workflow
and use other
helpful commands to perform
any other task defined in te GitHub Actions workflow.
GitHub actions run the test suite whenever you push a commit to make sure everything looks sane, but running the test suite locally before you push saves a lot of time!
Contributions are encouraged! Learn how to contribute by reading CONTRIBUTING.md. Please be nice and follow our Code of Conduct.
Apache License 2.0