Closed Tash2610 closed 1 year ago
[edit: until 6.0 arrives with Thin mode, you'll have to configure Instant Client!]
For Docker tips that relate to Thick mode and Instant Client, see Docker for Oracle Database Applications in Node.js and Python
@cjbj is there a way to handle the oracledb library missing error through package.json or dockerfile?
See the blog post series link I gave earlier which shows how to do it in the Dockerfile.
@cjbj Thank you for sharing those insightful links. We already have a dockerfile in our playwright automation project, as added below, where we're already using the playwright image, and the steps which are mentioned in the Docker for Oracle Database Applications in Node.js and Python suggest to pull oracle client image first from Docker registry and then use that image in a dockerfile. As, we're already using Playwright image and can't use another image to create docker image, Can you suggest something to fix the CI/CD pipeline issue of missing OracleDB libraries through Dockerfile during pipeline execution on server? Dockerfile
FROM mcr.microsoft.com/playwright:v1.32.3-focal AS local
WORKDIR /app
COPY .npmrc .
COPY package.json .
RUN yarn install
COPY . .
FROM local AS ci
ARG ACCOUNT_ENV
ENV ACCOUNT_ENV=$ACCOUNT_ENV
The blog post shows various ways to install and configure Instant Client. Check it out!
Closing this since the solutions for client library installation and loading have been shared.
The just-released node-oracledb 6.0 doesn't necessarily need Instant Client libraries so there is also an easier solution now.
Are you installing into vanilla Node.js, or using something like Electron? Using dockerfile to create an image of automation project and then run the image on the concourse CI/CD pipeline.
Show the directory listing where your Oracle Client libraries are installed (e.g. the Instant Client directory). Is it 64-bit or 32-bit?
Show what the
PATH
environment variable (on Windows) orLD_LIBRARY_PATH
(on Linux) are set to?Show any Oracle environment variables set (e.g. ORACLE_HOME, ORACLE_BASE).