GitHub
This section details the prerequisites for GitHub.
The accelerator does not support GitHub personal accounts, since they don’t support all the features required for security. You must have a GitHub organization account or the accelerator will fail on apply. You can create a free organization here. Learn more about account types here.
If you choose to use afree
organization account the accelerator bootstrap will make your repositories public. It must do this to support the functionality required by the accelerator. This is not recommended for production environments.
The following instructions refer toclassic
personal access tokens. You can also usefine-grained
access tokens which are still in beta to provide more granular permissions. These docs will be updated to reflect this in the future.
This first PAT is referred to as token-1
.
- Navigate to github.com.
- Click on your user icon in the top right and select
Settings
. - Scroll down and click on
Developer Settings
in the left navigation. - Click
Personal access tokens
in the left navigation and selectTokens (classic)
. - Click
Generate new token
at the top and selectGenerate new token (classic)
. - Enter
Azure Landing Zone Terraform Accelerator
in theNote
field. - Alter the
Expiration
drop down and selectCustom
. - Choose tomorrows date in the date picker.
- Check the following scopes:
repo
workflow
admin:org
user
:read:user
user
:user:email
delete_repo
- Click
Generate token
. - Copy the token and save it somewhere safe.
- If your organization uses single sign on, then click the
Configure SSO
link next to your new PAT. - Select your organization and click
Authorize
, then follow the prompts to allow SSO.
If you are using self-hosted runners, you will need to create a second PAT that we’ll refer to as token-2
for them. You can do this by following the steps above with the following differences:
Select
No expiration
for theExpiration
field.You may want to set a shorter expiration date for security reasons. In either case, you will need to have a process in place to extend expiration the token before it expires.The scope required depends on the type of organization you are using:
- If you are using a Free organization or an Enterprise organization without a runner group, select only the
repo
scope. - If you are using an Enterprise organization and a runner group, select the
admin:org
scope for classic tokens (ororganization_self_hosted_runners:write
for fine-grained tokens).
- If you are using a Free organization or an Enterprise organization without a runner group, select only the