Install the Autodock GitHub App on your repository. This allows Autodock to clone your code and post PR comments as your preview environment progresses.
Install Autodock AppSign in or sign up to create an API token. No credit card required and a pretty sweet free tier.
Sign In or Sign UpGo to your repository Settings → Secrets and variables → Actions and add:
Using Doppler? Echo your config to AUTODOCK_ENV.
Create .github/workflows/preview.yml in your repository:
# .github/workflows/preview.yml
name: Preview
on:
pull_request:
types: [opened, synchronize, reopened, closed]
jobs:
preview:
runs-on: ubuntu-latest
steps:
- uses: mikesol/autodock-preview@v1
env:
AUTODOCK_TOKEN: ${{ secrets.AUTODOCK_TOKEN }}
AUTODOCK_ENV: ${{ secrets.AUTODOCK_ENV }} # OptionalSingle-repo previews only for now
Each preview environment is tied to one repository. Multi-repo previews coming soon.