diff --git a/.all-contributorsrc b/.all-contributorsrc new file mode 100644 index 0000000..63c1e2a --- /dev/null +++ b/.all-contributorsrc @@ -0,0 +1,49 @@ +{ + "projectName": "sheriff", + "projectOwner": "elementsinteractive", + "repoType": "github", + "repoHost": "https://github.com", + "files": [ + "README.md" + ], + "imageSize": 50, + "commit": true, + "commitConvention": "angular", + "contributors": [ + { + "login": "sacha-c", + "name": "Sacha Brouté", + "avatar_url": "https://avatars.githubusercontent.com/u/3247529?v=4", + "profile": "https://github.com/sacha-c", + "contributions": [ + "code", + "design", + "ideas", + "maintenance" + ] + }, + { + "login": "scastlara", + "name": "Sergio Castillo", + "avatar_url": "https://avatars.githubusercontent.com/u/7606872?v=4", + "profile": "https://github.com/scastlara", + "contributions": [ + "code", + "ideas", + "maintenance" + ] + }, + { + "login": "jbozanowski", + "name": "Jakub Bożanowski", + "avatar_url": "https://avatars.githubusercontent.com/u/114900?v=4", + "profile": "https://github.com/jbozanowski", + "contributions": [ + "ideas", + "design" + ] + } + ], + "contributorsPerLine": 7, + "linkToUsage": false +} diff --git a/README.md b/README.md new file mode 100644 index 0000000..9263e94 --- /dev/null +++ b/README.md @@ -0,0 +1,160 @@ +
+
+
+
+
+### Report message
+
+Sheriff will post a message to a messaging service with an overview of the analyzed repositories and the vulerabilities detected. This message is intended to provide a generic overview to those in charge of security to oversee the state of a given group of repositories.
+
+
+
+
+### Specific repository message
+
+Project teams can also be informed regularly by Sheriff (if they want to) by configuring a channel to which Sheriff should report its findings of a given repository. The message generated by Sheriff will be slightly different, and will contain only information relevant for the repository maintainers.
+
+
+
+
+## Installation
+
+### Docker
+
+The easiest way to run Sheriff is through docker:
+
+```sh
+docker pull elementsinteractive/sheriff
+docker run elementsinteractive/sheriff --help
+```
+
+### Manual installation
+
+> [!NOTE]
+> If you install Sheriff manually, you will need to ensure that all the scanners used by it are available in your system
+
+You can install Sheriff yourself by installing its dependencies, and then either downloading the binary from the [GitHub Releases page](https://github.com/elementsinteractive/sheriff/releases) or building Sheriff from source.
+
+```sh
+brew install osv-scanner
+git clone git@github.com:elementsinteractive/sheriff.git
+cd sheriff
+go install .
+```
+
+## Configuration
+
+Sheriff can be configured in a few different ways:
+
+### CLI flags
+
+The most complete way is through CLI flags. See `sheriff patrol --help` for the full list of available options.
+
+### Environment variables
+
+For specific sensitive configuration keys such as API tokens, Sheriff can read them from environmental variables.
+Only the **Tokens** section of configuration parameters are supported for this (see `sheriff patrol --help` for the full list).
+
+This is the case for `GITLAB_TOKEN` & `SLACK_TOKEN` for example.
+
+### Configuration file
+
+Sheriff also supports configuration through a TOML config file.
+Only the **Reporting** and **Scanning** sections of configuration parameters are supported for this (see `sheriff patrol --help` for the full list).
+
+In this case you may choose to create a config file such as the following:
+
+```toml
+gitlab-groups = ["namespace/group", "namespace/group/cool-repo"]
+gitlab-projects = ["namespace/group/cool-repo"]
+report-slack-channel = "sheriff-report-test"
+report-gitlab-issue = true
+```
+
+And if you wish to specify a different file, you can do so with `sheriff patrol --config your-config-file.toml`.
+
+> [!NOTE]
+> When using several type of configuration at once there is an order of preference: **cli flags** > **env vars** > **config file**
+
+## Supported platforms
+
+### Source code hosting services
+
+- [x] [GitLab](https://gitlab.com/dashboard/merge_requests?assignee_username=sergio.lara1)
+- [ ] [GitHub](https://github.com) ([#9](https://github.com/elementsinteractive/sheriff/issues/9))
+
+### Messaging services
+
+- [x] [Slack](http://slack.com)
+- [ ] Email ([#12](https://github.com/elementsinteractive/sheriff/issues/12))
+
+### Scanners
+
+- [x] [OSV-Scanner](https://github.com/google/osv-scanner)
+- [ ] [Trivy](https://github.com/aquasecurity/trivy)
+
+## Contributors ✨
+
+Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/docs/en/emoji-key)):
+
+
+
+
+Sacha Brouté 💻 🎨 🤔 🚧 |
+ Sergio Castillo 💻 🤔 🚧 |
+ Jakub Bożanowski 🤔 🎨 |
+