You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
## Step 1: Create and install a dummy GitHub app for testing with
4
+
5
+
Go to https://github.com/settings/apps/new
6
+
7
+
1. Enter a name for the app (needs to be unique across GitHub).
8
+
2. Set the required `homepage URL` field (can be any valid URL).
9
+
3. Under `Webhook`, uncheck the `Active` checkbox.
10
+
4. Click on `Repository permissions` under `Permissions`, and set `Contents` to `Read-only`
11
+
5. Click on `Create GitHub App` at the bottom of the page.
12
+
6. You should be navigated to a new page with a `Registration successful. You must generate a private key in order to install your GitHub App.` message. Click on the `generate a private key` link, and then the `Generate a private key` button, and save it somewhere; it will be used to test the app authentication.
13
+
7. Click on the `Install App` tab on the left, and then click on `Install` on the right.
14
+
8. Select `Only select repositories`, and pick any private repository that contains a "LICENSE" file (may need to be created beforehand).
15
+
16
+
## Step 2: Export the necessary environment variables
17
+
18
+
The following environment variables are *required* to run the git-sync github app auth tests:
19
+
-`GITHUB_APP_PRIVATE_KEY`
20
+
-`GITHUB_APP_APPLICATION_ID`
21
+
-`GITHUB_APP_CLIENT_ID`
22
+
-`GITHUB_APP_INSTALLATION_ID`
23
+
-`GITHUB_APP_AUTH_TEST_REPO`
24
+
25
+
### GITHUB_APP_PRIVATE_KEY
26
+
Should have been saved when creating the app
27
+
28
+
### GITHUB_APP_APPLICATION_ID
29
+
The value after "App ID" in the app's settings page
30
+
31
+
### GITHUB_APP_CLIENT_ID
32
+
The value after "Client ID" in the app's settings page
33
+
34
+
### GITHUB_APP_INSTALLATION_ID
35
+
Found in the URL of the app's installation page if you installed it to a repository: https://github.com/settings/installations/<installation_id>
36
+
37
+
### GITHUB_APP_AUTH_TEST_REPO
38
+
Should be set to the repository that the github app is installed to.
0 commit comments