Skip to content

feat: remove searcher context from harness and master [MD-498] #1235

feat: remove searcher context from harness and master [MD-498]

feat: remove searcher context from harness and master [MD-498] #1235

---
name: "Link docsite preview"
on: # yamllint disable-line rule:truthy
pull_request_target:
paths:
- "docs/*"
types:
- opened
- edited
- synchronize
jobs:
link:
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write
steps:
- name: Get hash for branch
id: hash
env:
# not just pointless indirection; this mitigates script injections
# https://docs.github.com/en/actions/security-guides/security-hardening-for-github-actions#good-practices-for-mitigating-script-injection-attacks
BRANCH: ${{ github.event.pull_request.head.ref }}
run: |
echo "branch: $BRANCH"
SUM="$(echo -n "$BRANCH" | md5sum | awk '{print $1}')" && echo $SUM
echo "SUM=${SUM}" >> $GITHUB_OUTPUT
- uses: peter-evans/create-or-update-comment@v4
with:
token: ${{ secrets.DETERMINED_TOKEN }}
issue-number: ${{ github.event.number }}
body: |
Docsite preview being generated for this PR.
You can (eventually) find the generated docsite [here](https://determined-ai-docs.s3.us-west-2.amazonaws.com/previews/${{ steps.hash.outputs.SUM }}/index.html).