Skip to content

Commit

Permalink
Initial Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
eguzki committed Jan 17, 2023
1 parent cad5e96 commit 51d579c
Show file tree
Hide file tree
Showing 3 changed files with 49 additions and 2 deletions.
20 changes: 20 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
FROM registry.redhat.io/3scale-amp2/system-rhel7:3scale2.13

USER root

COPY ./oracle-client-files/instantclient-basic*-linux.*.zip \
./oracle-client-files/instantclient-sdk-linux.*.zip \
./oracle-client-files/instantclient-odbc-linux.*.zip \
/opt/system/vendor/oracle/

ENV LD_LIBRARY_PATH=/opt/oracle/instantclient/:$LD_LIBRARY_PATH \
ORACLE_HOME=/opt/oracle/instantclient/ \
DB=oracle \
TZ=utc \
NLS_LANG=AMERICAN_AMERICA.UTF8

RUN ./script/oracle/install-instantclient-packages.sh \
&& source /opt/app-root/etc/scl_enable \
&& DB=oracle bundle install --local --deployment --jobs $(grep -c processor /proc/cpuinfo) --retry=5

USER 1001
31 changes: 29 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,29 @@
# system-oracle
System image build with Oracle Database support
# System image build with Oracle Database support


## Prerequisites

In order to work with Oracle Database for Red Hat 3scale API Management, you will need to create a custom image as Red Hat cannot distribute the binaries of Oracle Database client.

You **MUST** download the client (basic-lite or basic), the odbc driver and the sdk for **19.6** in [Oracle Technology Network](http://www.oracle.com/technetwork/database/features/instant-client/index-097480.html).

* Instant Client Package - Basic or Basic Lite
* Instant Client Package - SDK
* Instant Client Package - ODBC driver

Example:

* instantclient-basiclite-linux.x64-19.6.0.0.0dbru.zip or instantclient-basic-linux.x64-19.6.0.0.0dbru.zip
* instantclient-sdk-linux.x64-19.6.0.0.0dbru.zip
* instantclient-odbc-linux.x64-19.6.0.0.0dbru.zip

## Instructions

1 - Place the downloaded files in the `oracle-client-files` directory.


2 - Build the custom system Oracle-based image. The image tag must be a fixed image tag as in the following example:

```
$ docker build . --tag myregistry.example.com/system-oracle:2.13.0-1
```
Empty file added oracle-client-files/.keep
Empty file.

0 comments on commit 51d579c

Please sign in to comment.