Skip to Main Content

DevOps, CI/CD and Automation


For appeals, questions and feedback, please email

Connect autonomous database with fn through python

3497231Sep 11 2019

Hi Everyone,

Can anyone ,please suggest me in the below .

I wanted to run my python code through oracle serverless computing( through fn function)

Therefore I am facing challenge in connecting to adwc database with fn.

In order to connect I need a init image file in python or Dockerfile in python.

Can anyone suggest me, how to connect to autonomous database using fn .

I tried connecting using instant client . How ever it didn't worked.

Here is the dockerfile

FROM oraclelinux:7-slim

ARG release=18

ARG update=5

RUN  yum -y install oracle-release-el7 && yum-config-manager --enable ol7_oracle_instantclient && \

     yum -y install oracle-instantclient${release}.${update}-basic oracle-instantclient${release}.${update}-devel oracle-instantclient${release}.${update}-sqlplus && \

     rm -rf /var/cache/yum && \

     echo /usr/lib/oracle/${release}.${update}/client64/lib > /etc/${release}.${update}.conf && \


Please suggest.

ENV PATH=$PATH:/usr/lib/oracle/${release}.${update}/client64/bin

CMD ["sqlplus", "-v"]

Post Details
Added on Sep 11 2019