Skip to content

Commit 52e09cc

Browse files
authored
MAINT: migrate to github actions gpu instance, dependabot testing (#404)
* MAINT: migrate to github actions gpu instance, dependabot testing * update runner name * Revert "update runner name" This reverts commit 054d458. * use quantecon-gpu-runner * update publish and cache workflows to run locally * TMP: disable cache for full run * update to cuda=12.6.0 for later driver
1 parent b88b912 commit 52e09cc

File tree

4 files changed

+27
-74
lines changed

4 files changed

+27
-74
lines changed

.github/dependabot.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# To get started with Dependabot version updates, you'll need to specify which
2+
# package ecosystems to update and where the package manifests are located.
3+
# Please see the documentation for all configuration options:
4+
# https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file
5+
6+
version: 2
7+
updates:
8+
- package-ecosystem: github-actions
9+
directory: /
10+
commit-message:
11+
prefix: ⬆️
12+
schedule:
13+
interval: weekly

.github/workflows/cache.yml

Lines changed: 2 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -4,30 +4,10 @@ on:
44
branches:
55
- main
66
jobs:
7-
deploy-runner:
8-
runs-on: ubuntu-latest
9-
steps:
10-
- uses: iterative/setup-cml@v1
11-
- uses: actions/checkout@v3
12-
with:
13-
ref: ${{ github.event.pull_request.head.sha }}
14-
- name: Deploy runner on EC2
15-
env:
16-
REPO_TOKEN: ${{ secrets.QUANTECON_SERVICES_PAT }}
17-
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
18-
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
19-
run: |
20-
cml runner launch \
21-
--cloud=aws \
22-
--cloud-region=us-west-2 \
23-
--cloud-type=p3.2xlarge \
24-
--labels=cml-gpu \
25-
--cloud-hdd-size=40
267
cache:
27-
needs: deploy-runner
28-
runs-on: [self-hosted, cml-gpu]
8+
runs-on: quantecon-gpu-runner
299
container:
30-
image: docker://mmcky/quantecon-lecture-python:cuda-12.3.1-anaconda-2024-02-py311
10+
image: ghcr.io/quantecon/lecture-python-container:cuda-12.5.0-anaconda-2024-06-py311
3111
options: --gpus all
3212
steps:
3313
- uses: actions/checkout@v3

.github/workflows/ci.yml

Lines changed: 10 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,13 @@
11
name: Build Project [using jupyter-book]
22
on: [pull_request]
33
jobs:
4-
deploy-runner:
5-
runs-on: ubuntu-latest
6-
steps:
7-
- uses: iterative/setup-cml@v2
8-
- uses: actions/checkout@v3
9-
with:
10-
ref: ${{ github.event.pull_request.head.sha }}
11-
- name: Deploy runner on EC2
12-
env:
13-
REPO_TOKEN: ${{ secrets.QUANTECON_SERVICES_PAT }}
14-
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
15-
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
16-
run: |
17-
cml runner launch \
18-
--cloud=aws \
19-
--cloud-region=us-west-2 \
20-
--cloud-type=p3.2xlarge \
21-
--labels=cml-gpu \
22-
--cloud-hdd-size=40
234
preview:
24-
needs: deploy-runner
25-
runs-on: [self-hosted, cml-gpu]
5+
runs-on: quantecon-gpu-runner
266
container:
27-
image: docker://mmcky/quantecon-lecture-python:cuda-12.3.1-anaconda-2024-02-py311
7+
image: ghcr.io/quantecon/lecture-python-container:cuda-12.6.0-anaconda-2024-06-py311
288
options: --gpus all
299
steps:
30-
- uses: actions/checkout@v3
10+
- uses: actions/checkout@v4
3111
with:
3212
ref: ${{ github.event.pull_request.head.sha }}
3313
# Check nvidia drivers
@@ -40,13 +20,13 @@ jobs:
4020
- name: Display Pip Versions
4121
shell: bash -l {0}
4222
run: pip list
43-
- name: Download "build" folder (cache)
44-
uses: dawidd6/action-download-artifact@v2
45-
with:
46-
workflow: cache.yml
47-
branch: main
48-
name: build-cache
49-
path: _build
23+
# - name: Download "build" folder (cache)
24+
# uses: dawidd6/action-download-artifact@v2
25+
# with:
26+
# workflow: cache.yml
27+
# branch: main
28+
# name: build-cache
29+
# path: _build
5030
# Build Assets (Download Notebooks and PDF via LaTeX)
5131
- name: Build Download Notebooks (sphinx-tojupyter)
5232
shell: bash -l {0}

.github/workflows/publish.yml

Lines changed: 2 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -4,31 +4,11 @@ on:
44
tags:
55
- 'publish*'
66
jobs:
7-
deploy-runner:
8-
runs-on: ubuntu-latest
9-
steps:
10-
- uses: iterative/setup-cml@v1
11-
- uses: actions/checkout@v3
12-
with:
13-
ref: ${{ github.event.pull_request.head.sha }}
14-
- name: Deploy runner on EC2
15-
env:
16-
REPO_TOKEN: ${{ secrets.QUANTECON_SERVICES_PAT }}
17-
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
18-
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
19-
run: |
20-
cml runner launch \
21-
--cloud=aws \
22-
--cloud-region=us-west-2 \
23-
--cloud-type=p3.2xlarge \
24-
--labels=cml-gpu \
25-
--cloud-hdd-size=40
267
publish:
278
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags')
28-
needs: deploy-runner
29-
runs-on: [self-hosted, cml-gpu]
9+
runs-on: quantecon-gpu-runner
3010
container:
31-
image: docker://mmcky/quantecon-lecture-python:cuda-12.3.1-anaconda-2024-02-py311
11+
image: ghcr.io/quantecon/lecture-python-container:cuda-12.5.0-anaconda-2024-06-py311
3212
options: --gpus all
3313
steps:
3414
- name: Checkout

0 commit comments

Comments
 (0)