Spaces:
Running
Running
File size: 1,549 Bytes
25f01d1 0bf9463 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 |
name: Deploy Gradio App
on:
push:
branches:
- main
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.12.3' # Specify the Python version you are using
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt # Ensure you have a requirements.txt file
- name: Login to Hugging Face
env:
HUGGINGFACE_TOKEN: ${{ secrets.HUGGING_FACE_TOKEN }}
run: |
huggingface-cli login --token $HUGGINGFACE_TOKEN
- name: Deploy Gradio App
env:
HUGGINGFACE_TOKEN: ${{ secrets.HUGGING_FACE_TOKEN }}
run: gradio deploy
# - name: Upload to Hugging Face Spaces
# env:
# HF_TOKEN: ${{ secrets.HUGGING_FACE_TOKEN }}
# run: |
# git lfs install
# huggingface-cli lfs-enable-largefiles .
# huggingface-cli repo create reviewerarena/reviewer-arena --type=space
# huggingface-cli repo upload reviewerarena/reviewer-arena . --all-yes
# - name: Login to Hugging Face
# env:
# HUGGINGFACE_TOKEN: ${{ secrets.HUGGING_FACE_TOKEN }}
# run: |
# echo "$HUGGINGFACE_TOKEN" | huggingface-cli login --token
# - name: Deploy Gradio App
# env:
# HUGGINGFACE_TOKEN: ${{ secrets.HUGGING_FACE_TOKEN }}
# run: |
# gradio deploy --token $HUGGINGFACE_TOKEN |