-
Notifications
You must be signed in to change notification settings - Fork 180
91 lines (87 loc) · 2.65 KB
/
r-build-test.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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
name: test for install R from source
on:
pull_request:
branches:
- master
paths:
- scripts/install_R_source.sh
- scripts/setup_R.sh
- scripts/bin/**
- dockerfiles/r-ver_devel.Dockerfile
- "!**.md"
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: true
matrix:
tag:
- "devel"
- "4.0.0"
platforms:
- linux/amd64
steps:
- uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Expose GitHub Runtime
uses: crazy-max/ghaction-github-runtime@v3
- name: test build
run: |
docker buildx bake \
-f bakefiles/"${{ matrix.tag }}".docker-bake.json \
--set=*.platform="${{ matrix.platforms }}" \
--set=*.cache-from=docker.io/rocker/r-ver:"${{ matrix.tag }}" \
--set=*.cache-from=type=gha,scope=r-ver-"${{ matrix.tag }}" \
--set=*.cache-to=type=gha,scope=r-ver-"${{ matrix.tag }}" \
--set=r-ver.tags=r-ver-test-"${{ matrix.tag }}" \
--load \
r-ver
- name: inspect image
run: |
make inspect-image/r-ver-test-"${{ matrix.tag }}"
- name: Upload artifacts
uses: actions/upload-artifact@v3
with:
name: tmp
path: tmp
regression-test:
needs: build
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
tag:
- "4.0.0"
platforms:
- linux/amd64
script:
- install_rstudio.sh
- install_tidyverse.sh
- install_verse.sh
- install_shiny_server.sh
- install_geospatial.sh
steps:
- uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Expose GitHub Runtime
uses: crazy-max/ghaction-github-runtime@v3
- name: test build
run: |
docker buildx bake \
-f bakefiles/"${{ matrix.tag }}".docker-bake.json \
--set=*.platform="${{ matrix.platforms }}" \
--set=*.cache-from=docker.io/rocker/r-ver:"${{ matrix.tag }}" \
--set=*.cache-from=type=gha,scope=r-ver-"${{ matrix.tag }}" \
--set=*.cache-to=type=gha,scope=r-ver-"${{ matrix.tag }}" \
--set=r-ver.tags=r-ver-test-"${{ matrix.tag }}" \
--load \
r-ver
- name: test run rocker scripts
run: |
docker run --rm r-ver-test-"${{ matrix.tag }}" "/rocker_scripts/${{ matrix.script }}"