Skip to content

Update action

Update action #4

Workflow file for this run

name: Test workflows based on torch
on: [push]
jobs:
my_job:
runs-on: ubuntu-latest
container:
image: pytorch/pytorch:latest # docker://{docker-image-name}:{tag}
options: --volume ${{ github.workspace }}:${{ github.workspace }}
steps:
- name: Cache Docker image layers
uses: actions/cache@v2
with:
path: /var/lib/docker/image
key: ${{ runner.os }}-docker-${{ hashFiles('**/Dockerfile') }}
- name: Run commands in container
run: |
# Now the repository code is available inside the Docker container
# You can use it as needed
cd ${{ github.workspace }} &&
# Run your commands here
ls -la &&
pwd &&
echo ${{ github.workspace }}