-
Notifications
You must be signed in to change notification settings - Fork 226
105 lines (92 loc) · 2.99 KB
/
ci_oracle.yml
File metadata and controls
105 lines (92 loc) · 2.99 KB
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
92
93
94
95
96
97
98
99
100
101
102
103
104
105
---
name: CI Oracle
on:
push:
branches:
- '**'
pull_request:
branches:
- '**'
schedule:
- cron: '0 4 1 * *'
# Run workflow manually
workflow_dispatch:
jobs:
rspec:
runs-on: ubuntu-latest
env: # $BUNDLE_GEMFILE must be set at the job level, so it is set for all steps
BUNDLE_GEMFILE: ${{ github.workspace }}/gemfiles/${{ matrix.rails }}_with_${{ matrix.adapter }}.gemfile
ORACLE_HOME: /opt/oracle/instantclient_23_8
LD_LIBRARY_PATH: /opt/oracle/instantclient_23_8
TNS_ADMIN: ./ci/network/admin
DATABASE_SYS_PASSWORD: Oracle18
DATABASE_NAME: FREEPDB1
services:
oracle:
image: gvenzl/oracle-free:latest
ports:
- 1521:1521
env:
TZ: Europe/Paris
ORACLE_PASSWORD: Oracle18
options: >-
--health-cmd healthcheck.sh
--health-interval 10s
--health-timeout 5s
--health-retries 10
strategy:
fail-fast: false
matrix:
ruby:
- '4.0'
- '3.4'
- '3.3'
- '3.2'
- '3.1'
# - 'head'
rails:
- rails_8.0
- rails_7.2
- rails_7.1
adapter:
- oracle_enhanced
exclude:
- rails: 'rails_8.0'
ruby: '3.1'
adapter: 'oracle_enhanced'
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Create symbolic link for libaio library compatibility
run: |
sudo ln -s /usr/lib/x86_64-linux-gnu/libaio.so.1t64 /usr/lib/x86_64-linux-gnu/libaio.so.1
- name: Download Oracle instant client
run: |
wget -q https://download.oracle.com/otn_software/linux/instantclient/2380000/instantclient-basic-linux.x64-23.8.0.25.04.zip
wget -q https://download.oracle.com/otn_software/linux/instantclient/2380000/instantclient-sdk-linux.x64-23.8.0.25.04.zip
wget -q https://download.oracle.com/otn_software/linux/instantclient/2380000/instantclient-sqlplus-linux.x64-23.8.0.25.04.zip
- name: Install Oracle instant client
run: |
sudo unzip instantclient-basic-linux.x64-23.8.0.25.04.zip -d /opt/oracle/
sudo unzip -o instantclient-sdk-linux.x64-23.8.0.25.04.zip -d /opt/oracle/
sudo unzip -o instantclient-sqlplus-linux.x64-23.8.0.25.04.zip -d /opt/oracle/
echo "/opt/oracle/instantclient_23_8" >> $GITHUB_PATH
- name: Create database user
run: |
./ci/setup_accounts.sh
- name: Setup Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true
env:
DB_ADAPTER: ${{ matrix.adapter }}
- name: Run RSpec
env:
DB_ADAPTER: ${{ matrix.adapter }}
run: bin/rspec
- name: Publish code coverage
uses: qltysh/qlty-action/coverage@v1
with:
token: ${{ secrets.QLTY_COVERAGE_TOKEN }}
files: coverage/coverage.json