-
Notifications
You must be signed in to change notification settings - Fork 2
34 lines (31 loc) · 1.1 KB
/
pytorch_image.yml
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
name: Build and Publish PyTorch Docker Image
env:
PyTorch_Version: '2.0.0'
CUDA_Major: '11'
CUDA_Minor: '7'
on:
workflow_dispatch:
push:
branches: [ singularity-compatible ]
paths: [ PyTorch/Dockerfile, .github/workflows/pytorch_image.yml ]
pull_request:
branches: [ singularity-compatible ]
paths: [ PyTorch/Dockerfile, .github/workflows/pytorch_image.yml ]
jobs:
build_pytorch:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Build Pytorch Docker
uses: elgohr/Publish-Docker-Github-Action@v5
env:
PyTorch_Tag: "${{ env.PyTorch_Version }}-cuda${{ env.CUDA_Major }}.${{ env.CUDA_Minor }}-cudnn8"
PyTorch_Variants: '-runtime'
with:
name: fnallpc/fnallpc-docker
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
buildargs: PyTorch_Version,CUDA_Major,CUDA_Minor,PyTorch_Tag,PyTorch_Variants
workdir: PyTorch/
tags: "pytorch-${{ env.PyTorch_Tag }}${{ env.PyTorch_Variants }}-singularity"
no_push: ${{ github.event_name == 'pull_request' }}