Skip to content

Commit deb623e

Browse files
committed
custom deploy task for each docs preview
1 parent ea49b1f commit deb623e

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

.github/set_docs_preview_url.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
GITHUB_TOKEN = os.environ['GITHUB_TOKEN']
99
REPOSITORY = os.environ['REPOSITORY']
1010
REF = os.environ['REF']
11-
ENVIRONMENT = os.environ['ENVIRONMENT']
11+
ENVIRONMENT = 'deploy-preview'
1212

1313
m = re.search(r'https://(\S+)\.workers\.dev', DEPLOY_OUTPUT)
1414
assert m, f'Could not find worker URL in {DEPLOY_OUTPUT!r}'
@@ -29,7 +29,7 @@
2929
deployment_url = f'https://api.github.com/repos/{REPOSITORY}/deployments'
3030
deployment_data = {
3131
'ref': REF,
32-
'task': 'docs preview',
32+
'task': f'docs preview {version_id}',
3333
'environment': ENVIRONMENT,
3434
'auto_merge': False,
3535
'required_contexts': [],

.github/workflows/after-ci.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,4 +94,3 @@ jobs:
9494
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
9595
REPOSITORY: ${{ github.repository }}
9696
REF: ${{ github.event.workflow_run.head_sha }}
97-
ENVIRONMENT: deploy-preview

0 commit comments

Comments
 (0)