[Python] Oracle Cloud : Issue to deploy python function using Cloud Shell

Discussão em 'Python' iniciado por Stack, Março 26, 2025.

  1. Stack

    Stack Membro Participativo

    I want to create a python function with Oracle Cloud's function service. To do this, I'm following the Getting started tutorial using Cloud Shell Setup. I follow all the steps as indicated, but when I come to deploy the function with the command fn -v deploy --app DBDB_IO_Refresher. I get this error :

    Fn: error running docker build: Cannot create/use builder instance docker for oci_fn_builder : exit status 125


    Here are all the instructions I followed:

    fn list context
    fn use context eu-marseille-1
    fn update context oracle.compartment-id ocid1.********************
    fn update context registry ***********/func-python
    docker login -u '***********' mrs.ocir.io
    fn list apps
    fn init --runtime java hello-test-python
    cd hello-test-python
    fn -v deploy --app DBDB_IO_Refresher


    Here are the details of the error:

    Deploying hello-test-python to app: DBDB_IO_Refresher
    Bumped to version 0.0.2
    Using Container engine docker
    Building image ******/******/func-python/hello-test-python:0.0.2
    Dockerfile content
    -----------------------------------
    FROM fnproject/fn-java-fdk-build:jdk17-1.0.182 as build-stage
    WORKDIR /function
    ENV MAVEN_OPTS -Dhttp.proxyHost= -Dhttp.proxyPort= -Dhttps.proxyHost= -Dhttps.proxyPort= -Dhttp.nonProxyHosts= -Dmaven.repo.local=/usr/share/maven/ref/repository
    ADD pom.xml /function/pom.xml
    RUN ["mvn", "package", "dependency:copy-dependencies", "-DincludeScope=runtime", "-DskipTests=true", "-Dmdep.prependGroupId=true", "-DoutputDirectory=target", "--fail-never"]
    ADD src /function/src
    RUN ["mvn", "package"]
    FROM fnproject/fn-java-fdk:jre17-1.0.182
    WORKDIR /function
    COPY --from=build-stage /function/target/*.jar /function/app/
    CMD ["com.example.fn.HelloFunction::handleRequest"]
    -----------------------------------
    FN_REGISTRY: *****/*******/func-python
    Current Context: eu-marseille-1
    TargetedPlatform: amd64_arm64HostPlatform: amd64


    Fn: error running docker build: Cannot create/use builder instance docker for oci_fn_builder : exit status 125


    Here is the docker configuration on CLoud Shell Setup :

    pierre_ant@cloudshell:hello-test-python (eu-marseille-1)$ docker version
    Client: Docker Engine - Community
    Version: 19.03.11-ol
    API version: 1.40
    Go version: go1.16.2
    Git commit: 9bb540d
    Built: Fri Jul 23 01:33:55 2021
    OS/Arch: linux/amd64
    Experimental: false

    Server: Docker Engine - Community
    Engine:
    Version: 19.03.11-ol
    API version: 1.40 (minimum version 1.12)
    Go version: go1.16.2
    Git commit: 9bb540d
    Built: Fri Jul 23 01:32:08 2021
    OS/Arch: linux/amd64
    Experimental: false
    Default Registry: docker.io
    containerd:
    Version: v1.4.8
    GitCommit: 7eba5930496d9bbe375fdf71603e610ad737d2b2
    runc:
    Version: 1.1.7
    GitCommit: 860f061
    docker-init:
    Version: 0.18.0
    GitCommit: fec3683


    And here is the Fn configuration:

    pierre_ant@cloudshell:hello-test-python (eu-marseille-1)$ fn version
    Client version is latest version: 0.6.28
    Server version: ?


    If anyone has any ideas or needs further information, please don't hesitate, I've been stuck for over a week and can't find any solutions on the web.

    Continue reading...

Compartilhe esta Página