File tree Expand file tree Collapse file tree 2 files changed +5
-19
lines changed Expand file tree Collapse file tree 2 files changed +5
-19
lines changed Original file line number Diff line number Diff line change @@ -3,20 +3,9 @@ const { createProbot } = require("probot");
3
3
const { findPrivateKey } = require ( "probot/lib/private-key" ) ;
4
4
const appFn = require ( "./" ) ;
5
5
6
- process . env . PRIVATE_KEY =
7
- process . env . NOW_GITHUB_COMMIT_REF === "master"
8
- ? process . env . PROD_PRIVATE_KEY
9
- : process . env . DEV_PRIVATE_KEY ;
10
-
11
6
const options = {
12
- id :
13
- process . env . NOW_GITHUB_COMMIT_REF === "master"
14
- ? process . env . PROD_APP_ID
15
- : process . env . DEV_APP_ID ,
16
- secret :
17
- process . env . NOW_GITHUB_COMMIT_REF === "master"
18
- ? process . env . PROD_WEBHOOK_SECRET
19
- : process . env . DEV_WEBHOOK_SECRET ,
7
+ id : process . env . APP_ID ,
8
+ secret : process . env . WEBHOOK_SECRET ,
20
9
cert : findPrivateKey ( )
21
10
} ;
22
11
Original file line number Diff line number Diff line change 2
2
"version" : 2 ,
3
3
"scope" : " changesets" ,
4
4
"env" : {
5
- "PROD_APP_ID" : " @prod-app-id" ,
6
- "PROD_WEBHOOK_SECRET" : " @prod-webhook-secret" ,
7
- "PROD_PRIVATE_KEY" : " @prod-private-key-base64-encoded" ,
8
- "DEV_APP_ID" : " @dev-app-id" ,
9
- "DEV_WEBHOOK_SECRET" : " @dev-webhook-secret" ,
10
- "DEV_PRIVATE_KEY" : " @dev-private-key-base64-encoded"
5
+ "APP_ID" : " @dev-app-id" ,
6
+ "WEBHOOK_SECRET" : " @dev-webhook-secret" ,
7
+ "PRIVATE_KEY" : " @dev-private-key-base64-encoded"
11
8
},
12
9
"builds" : [{ "src" : " now.js" , "use" : " @now/node" }],
13
10
"routes" : [{ "src" : " /" , "dest" : " /now.js" }]
You can’t perform that action at this time.
0 commit comments