38 lines
1.4 KiB
YAML
38 lines
1.4 KiB
YAML
name: Test Gitea Secrets
|
|
on: [push]
|
|
|
|
jobs:
|
|
deploy-to-modal:
|
|
runs-on: ubuntu-latest
|
|
container:
|
|
image: gitea-modal-runner:latest
|
|
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Debug Modal Credentials
|
|
run: |
|
|
echo "DEBUG: Token ID is: '${MODAL_TOKEN_ID}'"
|
|
echo "DEBUG: Token ID length is: ${#MODAL_TOKEN_ID}"
|
|
# Use 'cut' to get the first 5 characters safely
|
|
FIRST_5=$(echo "$MODAL_TOKEN_ID" | cut -c1-5)
|
|
echo "DEBUG: First 5 chars are: '$FIRST_5'"
|
|
|
|
env:
|
|
# This maps the Gitea Repository Secret to an Environment Variable
|
|
MODAL_TOKEN_ID: ${{ secrets.MODAL_KEY }}
|
|
MODAL_TOKEN_SECRET: ${{ secrets.MODAL_SECRET }}
|
|
- name: Deploy worker pipeline to Modal
|
|
run: |
|
|
echo "DEBUG: Token ID is: '${MODAL_TOKEN_ID}'"
|
|
echo "DEBUG: Token ID length is: ${#MODAL_TOKEN_ID}"
|
|
# Use 'cut' to get the first 5 characters safely
|
|
FIRST_5=$(echo "$MODAL_TOKEN_ID" | cut -c1-5)
|
|
echo "DEBUG: First 5 chars are: '$FIRST_5'"
|
|
cd workspace/sprint_1_2/CODEBASE/deps/implementation
|
|
modal deploy test_worker.py
|
|
env:
|
|
# This maps the Gitea Repository Secret to an Environment Variable
|
|
MODAL_TOKEN_ID: ${{ secrets.MODAL_KEY }}
|
|
MODAL_TOKEN_SECRET: ${{ secrets.MODAL_SECRET }} |