diff --git a/.github/workflows/continuous-integration.yml b/.github/workflows/continuous-integration.yml index 62968ee..c0faab5 100644 --- a/.github/workflows/continuous-integration.yml +++ b/.github/workflows/continuous-integration.yml @@ -43,12 +43,16 @@ jobs: run: echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json" - name: Setup OCI8 - run: ./oci8-php8.sh + run: ./oci8-php80.sh if: matrix.php == 8 - name: Setup OCI8 - run: ./oci8.sh - if: matrix.php > 8 + run: ./oci8-php81.sh + if: matrix.php == 8.1 + + - name: Setup OCI8 + run: ./oci8-php82.sh + if: matrix.php == 8.2 - name: Install dependencies uses: nick-invision/retry@v1 diff --git a/oci8-php8.sh b/oci8-php80.sh similarity index 100% rename from oci8-php8.sh rename to oci8-php80.sh diff --git a/oci8-php81.sh b/oci8-php81.sh new file mode 100755 index 0000000..530d550 --- /dev/null +++ b/oci8-php81.sh @@ -0,0 +1,23 @@ +#!/usr/bin/env bash + +# install deps +sudo apt-get update -qq +sudo apt-get -y install -qq build-essential unzip wget libaio1 + +# install oci8 libs & extension +sudo mkdir -p /opt/oracle + +wget https://download.oracle.com/otn_software/linux/instantclient/199000/instantclient-basic-linux.x64-19.9.0.0.0dbru.zip +wget https://download.oracle.com/otn_software/linux/instantclient/199000/instantclient-sdk-linux.x64-19.9.0.0.0dbru.zip + +sudo unzip -o ./instantclient-basic-linux.x64-19.9.0.0.0dbru.zip -d /opt/oracle +sudo unzip -o ./instantclient-sdk-linux.x64-19.9.0.0.0dbru.zip -d /opt/oracle + +sudo ln -s /opt/oracle/instantclient/sqlplus /usr/bin/sqlplus +sudo ln -s /opt/oracle/instantclient_19_9 /opt/oracle/instantclient + +sudo sh -c "echo 'instantclient,/opt/oracle/instantclient' | pecl install oci8-3.2.1" + +# setup ld library path +sudo sh -c "echo '/opt/oracle/instantclient' >> /etc/ld.so.conf" +sudo ldconfig diff --git a/oci8-php82.sh b/oci8-php82.sh new file mode 100755 index 0000000..eea9981 --- /dev/null +++ b/oci8-php82.sh @@ -0,0 +1,23 @@ +#!/usr/bin/env bash + +# install deps +sudo apt-get update -qq +sudo apt-get -y install -qq build-essential unzip wget libaio1 + +# install oci8 libs & extension +sudo mkdir -p /opt/oracle + +wget https://download.oracle.com/otn_software/linux/instantclient/199000/instantclient-basic-linux.x64-19.9.0.0.0dbru.zip +wget https://download.oracle.com/otn_software/linux/instantclient/199000/instantclient-sdk-linux.x64-19.9.0.0.0dbru.zip + +sudo unzip -o ./instantclient-basic-linux.x64-19.9.0.0.0dbru.zip -d /opt/oracle +sudo unzip -o ./instantclient-sdk-linux.x64-19.9.0.0.0dbru.zip -d /opt/oracle + +sudo ln -s /opt/oracle/instantclient/sqlplus /usr/bin/sqlplus +sudo ln -s /opt/oracle/instantclient_19_9 /opt/oracle/instantclient + +sudo sh -c "echo 'instantclient,/opt/oracle/instantclient' | pecl install oci8" + +# setup ld library path +sudo sh -c "echo '/opt/oracle/instantclient' >> /etc/ld.so.conf" +sudo ldconfig