Skip to content

Commit deb214d

Browse files
authored
Merge pull request #2352 from yahonda/use_oci-oracle-free
Use `gvenzl/oracle-free:latest` to run `Oracle Database 23c Free`
2 parents 03643c0 + bfa164d commit deb214d

File tree

3 files changed

+19
-16
lines changed

3 files changed

+19
-16
lines changed

.github/workflows/test.yml

Lines changed: 16 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -25,19 +25,19 @@ jobs:
2525
'2.7'
2626
]
2727
env:
28-
ORACLE_HOME: /usr/lib/oracle/21/client64
29-
LD_LIBRARY_PATH: /usr/lib/oracle/21/client64/lib
28+
ORACLE_HOME: /opt/oracle/instantclient_23_3
29+
LD_LIBRARY_PATH: /opt/oracle/instantclient_23_3
3030
NLS_LANG: AMERICAN_AMERICA.AL32UTF8
3131
TNS_ADMIN: ./ci/network/admin
32-
DATABASE_NAME: XEPDB1
32+
DATABASE_NAME: FREEPDB1
3333
TZ: Europe/Riga
3434
DATABASE_SYS_PASSWORD: Oracle18
3535
DATABASE_HOST: localhost
3636
DATABASE_PORT: 1521
3737

3838
services:
3939
oracle:
40-
image: gvenzl/oracle-xe:latest
40+
image: gvenzl/oracle-free:latest
4141
ports:
4242
- 1521:1521
4343
env:
@@ -54,25 +54,28 @@ jobs:
5454
uses: ruby/setup-ruby@v1
5555
with:
5656
ruby-version: ${{ matrix.ruby }}
57-
- name: Install required package
58-
run: |
59-
sudo apt-get install alien
6057
- name: Download Oracle instant client
6158
run: |
62-
wget -q https://download.oracle.com/otn_software/linux/instantclient/2111000/oracle-instantclient-basic-21.11.0.0.0-1.x86_64.rpm
63-
wget -q https://download.oracle.com/otn_software/linux/instantclient/2111000/oracle-instantclient-sqlplus-21.11.0.0.0-1.x86_64.rpm
64-
wget -q https://download.oracle.com/otn_software/linux/instantclient/2111000/oracle-instantclient-devel-21.11.0.0.0-1.x86_64.rpm
59+
wget -q https://download.oracle.com/otn_software/linux/instantclient/23c/instantclient-basic-linux.x64-23.3.0.0.0.zip
60+
wget -q https://download.oracle.com/otn_software/linux/instantclient/23c/instantclient-sdk-linux.x64-23.3.0.0.0.zip
61+
wget -q https://download.oracle.com/otn_software/linux/instantclient/23c/instantclient-sqlplus-linux.x64-23.3.0.0.0.zip
62+
6563
- name: Install Oracle instant client
6664
run: |
67-
sudo alien -i oracle-instantclient-basic-21.11.0.0.0-1.x86_64.rpm
68-
sudo alien -i oracle-instantclient-sqlplus-21.11.0.0.0-1.x86_64.rpm
69-
sudo alien -i oracle-instantclient-devel-21.11.0.0.0-1.x86_64.rpm
65+
sudo mkdir -p /opt/oracle/
66+
sudo unzip instantclient-basic-linux.x64-23.3.0.0.0.zip -d /opt/oracle/
67+
sudo unzip -o instantclient-sdk-linux.x64-23.3.0.0.0.zip -d /opt/oracle/
68+
sudo unzip -o instantclient-sqlplus-linux.x64-23.3.0.0.0.zip -d /opt/oracle/
69+
echo "/opt/oracle/instantclient_23_3" >> $GITHUB_PATH
7070
- name: Install JDBC Driver
7171
run: |
7272
wget -q https://download.oracle.com/otn-pub/otn_software/jdbc/211/ojdbc11.jar -O ./lib/ojdbc11.jar
7373
- name: Create database user
7474
run: |
7575
./ci/setup_accounts.sh
76+
- name: Update RubyGems
77+
run: |
78+
gem update --system
7679
- name: Bundle install
7780
run: |
7881
bundle install --jobs 4 --retry 3

ci/network/admin/tnsnames.ora

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
XEPDB1 =
1+
FREEPDB1 =
22
(DESCRIPTION =
33
(ADDRESS = (PROTOCOL = TCP)(HOST = 127.0.0.1)(PORT = 1521))
44
(CONNECT_DATA =
5-
(SERVICE_NAME = XEPDB1)
5+
(SERVICE_NAME = FREEPDB1)
66
)
77
)
88

ci/setup_accounts.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
set -ev
44

5-
${ORACLE_HOME}/bin/sqlplus system/${DATABASE_SYS_PASSWORD}@${DATABASE_NAME} <<SQL
5+
sqlplus system/${DATABASE_SYS_PASSWORD}@${DATABASE_NAME} <<SQL
66
@@spec/support/alter_system_set_open_cursors.sql
77
@@spec/support/create_oracle_enhanced_users.sql
88
exit

0 commit comments

Comments
 (0)