Skip to content

properly cache action #15

properly cache action

properly cache action #15

Workflow file for this run

name: Run experiment via SSH
on:
push:
branches:
- runpod-rl_hopper # Set your branch here
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Set up SSH connection
uses: webfactory/[email protected]
with:
ssh-private-key: ${{ secrets.PRIVATE_KEY_GITHUB_ACTION }}
- name: SSH and Run
run: |
ssh -o StrictHostKeyChecking=no ${{ secrets.REMOTE_MACHINE_CONNECTION_STR }} << 'EOF'
cd ~/thinking
git pull
# source .venv/bin/activate
# python3 tasks/rl_hopper.py --clear
# python3 tasks/rl_hopper.py
# use tmux instead
# terminate existing session or restart
tmux kill-session -t runpod-rl_hopper
tmux new-session -d -s runpod-rl_hopper
tmux send-keys -t runpod-rl_hopper "source .venv/bin/activate" C-m
# assign env variables
tmux send-keys -t runpod-rl_hopper "export MUJOCO_GL=osmesa" C-m
tmux send-keys -t runpod-rl_hopper "python3 tasks/rl_hopper.py --clear" C-m
tmux send-keys -t runpod-rl_hopper "python3 tasks/rl_hopper.py" C-m
EOF