-
Notifications
You must be signed in to change notification settings - Fork 174
61 lines (49 loc) · 1.44 KB
/
mssql.yaml
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
on:
push:
branches:
- main
pull_request:
branches:
- main
name: mssql
jobs:
mssql:
runs-on: ubuntu-latest
services:
sqlserver:
image: mcr.microsoft.com/mssql/server:2017-latest-ubuntu
ports:
- 1433:1433
env:
ACCEPT_EULA: Y
SA_PASSWORD: Password12
env:
R_REMOTES_NO_ERRORS_FROM_WARNINGS: true
GITHUB_MSSQL: true
ODBCSYSINI: ${{ github.workspace }}/.github/odbc
steps:
- uses: actions/checkout@v3
- uses: r-lib/actions/setup-r@v2
- uses: r-lib/actions/setup-pandoc@v2
- uses: r-lib/actions/setup-r@v2
with:
use-public-rspm: true
- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::rcmdcheck
needs: check
- name: Install SQL Server driver
run: |
curl https://packages.microsoft.com/keys/microsoft.asc | apt-key add -
curl https://packages.microsoft.com/config/ubuntu/20.04/prod.list > /etc/apt/sources.list.d/mssql-release.list
apt-get update
ACCEPT_EULA=Y apt-get install -y msodbcsql17
sqlcmd -U SA -P 'Password12' -Q 'CREATE DATABASE test;'
dpkg -L msodbcsql17
shell: sudo bash {0}
- name: Check drivers
run: odbc::odbcListDrivers()
shell: Rscript {0}
- uses: r-lib/actions/check-r-package@v2
with:
upload-snapshots: true