chore: migrate to uv (#69) #74
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: 'Lektor deploy to webserver.c-base.org' | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
lektor-build: | |
name: Build page | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Install uv | |
uses: astral-sh/setup-uv@v5 | |
with: | |
version: "0.6.13" | |
- name: "Set up Python" | |
uses: actions/setup-python@v5 | |
with: | |
python-version-file: ".python-version" | |
- name: Install dependencies | |
run: uv sync --all-extras --dev | |
- name: Build with Lektor | |
run: | | |
uv run lektor build | |
- name: Setup SSH Keys and known_hosts and then deploy | |
env: | |
SSH_AUTH_SOCK: /tmp/ssh_agent.sock | |
run: | | |
mkdir -p ~/.ssh | |
ssh-keyscan 217.197.86.179 >> ~/.ssh/known_hosts | |
ssh-keyscan webserver.c-base.org >> ~/.ssh/known_hosts | |
ssh-agent -a $SSH_AUTH_SOCK > /dev/null | |
ssh-add - <<< "${{ secrets.LEKTOR_DEPLOY_PRODUCTION_KEY }}" | |
uv run lektor deploy |