forked from pytorch/benchmark
-
Notifications
You must be signed in to change notification settings - Fork 0
40 lines (37 loc) · 1.21 KB
/
build-gcp-docker.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
35
36
37
38
39
40
name: TorchBench Nightly GCP Base Docker Build
on:
workflow_dispatch:
schedule:
# Build the base Docker monthly
- cron: '0 0 1 * *'
env:
WITH_PUSH: "true"
jobs:
build-push-docker:
if: ${{ github.repository_owner == 'pytorch' }}
runs-on: [self-hosted, linux.4xlarge]
environment: docker-s3-upload
steps:
- name: Checkout
uses: actions/checkout@v3
with:
path: benchmark
- name: Login to Docker Container Registry
if: ${{ env.WITH_PUSH == 'true' }}
uses: docker/login-action@v2
with:
registry: docker.io
username: xzhao9
password: ${{ secrets.DOCKER_PERSONAL_ACCESS_TOKEN }}
- name: Build TorchBench Nightly GCP Base Docker
run: |
cd benchmark/docker
docker build . \
-f gcp-a100-runner-dind.dockerfile -t xzhao9/gcp-a100-runner-dind:latest
- name: Push docker to remote
if: ${{ env.WITH_PUSH == 'true' }}
run: |
docker push xzhao9/gcp-a100-runner-dind:latest
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}-${{ github.event_name == 'workflow_dispatch' }}
cancel-in-progress: true