forked from cesanta/docker_auth
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs: quick setup steps for github auth (cesanta#234)
- Loading branch information
Showing
2 changed files
with
27 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
## Github | ||
|
||
First you need to setup a [Github OAuth Application](https://github.com/settings/applications). | ||
|
||
- The callback url needs to be `$fqdn:5001/github_auth` | ||
- `$fqdn` is the domain where docker_auth is accessed | ||
- `5001` or what port is specified in the `server` block | ||
|
||
Once you have setup a Github OAuth application you need to add a `github` block to the docker_auth config file: | ||
|
||
```yaml | ||
github_auth: | ||
organization: "my-org-name" | ||
client_id: "..." | ||
client_secret: "..." # or client_secret_file | ||
token_db: /data/tokens.db | ||
``` | ||
Then specify what teams can do via acls | ||
```yaml | ||
acl: | ||
- match: {team: "infrastructure"} | ||
actions: ["pull", "push"] | ||
comment: "Infrastructure team members can push and all images" | ||
``` |