Skip to content

init: oauth docs #2565

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Jun 22, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
update: feedback
  • Loading branch information
ericpaulsen committed Jun 22, 2022
commit 5720279323d37e978e44d1612eaa1b9458410c7d
12 changes: 6 additions & 6 deletions docs/install/oauth.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ configuration steps.

## Step 1: Configure the OAuth application in GitHub

When [https://developer.github.com/apps/building-oauth-apps/creating-an-oauth-app/](creating an OAuth app),
GitHub will ask you for the following Coder parameters:
First, [https://developer.github.com/apps/building-oauth-apps/creating-an-oauth-app/](register a GitHub OAuth app). GitHub will ask you for the following Coder parameters:

- **Homepage URL**: Set to your Coder domain, e.g. `https://coder.domain.com`

- **Homepage URL**: Set to your Coder domain (e.g. `https://coder.domain.com`)
- **User Authorization Callback URL**: Set to `https://coder.domain.com/api/v2/users/oauth2/github/callback`

Note the Client ID and Client secret generated by GitHub. You will use these
Note the Client ID and Client Secret generated by GitHub. You will use these
values in the next step.

## Step 2: Configure Coder with the OAuth credentials
Expand All @@ -24,7 +24,7 @@ server:
coder server --oauth2-github-allow-signups=true --oauth2-github-allowed-orgs="your-org" --oauth2-github-client-id="8d1...e05" --oauth2-github-client-secret="57ebc9...02c24c"
```

Alternatively, if you already have a running Coder instance, you can achieve the
Alternatively, if you are running Coder as a system service, you can achieve the
same result as the command above by adding the following environment variables
to the `/etc/coder.d/coder.env` file:

Expand All @@ -35,4 +35,4 @@ CODER_OAUTH2_GITHUB_CLIENT_ID="8d1...e05"
CODER_OAUTH2_GITHUB_CLIENT_SECRET="57ebc9...02c24c"
```

Once complete, run `sudo systemctl enable --now coder` to reboot Coder.
Once complete, run `sudo service coder restart` to reboot Coder.
2 changes: 1 addition & 1 deletion docs/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
},
{
"title": "GitHub OAuth",
"description": "Learn how to authenticate with GitHub.",
"description": "Learn how to set up OAuth using your GitHub organization.",
"path": "./install/oauth.md"
}
]
Expand Down