Loading ci_cd_test/Dockerfile 0 → 100644 +17 −0 Original line number Diff line number Diff line FROM labs.etsi.org:5050/ocf/capif/python:3-slim-bullseye RUN apt update RUN apt install -y git ARG BRANCH=main RUN echo "Cloning branch: ${BRANCH}" && \ git clone -b ${BRANCH} https://labs.etsi.org/rep/ocf/sdk.git WORKDIR /sdk RUN python -m pip install --upgrade pip RUN pip install -r installation/requirements.txt RUN pip install . ENTRYPOINT ["tail", "-f", "/dev/null"] ci_cd_test/Dockerfile2 0 → 100644 +8 −0 Original line number Diff line number Diff line FROM labs.etsi.org:5050/ocf/capif/python:3-slim-bullseye RUN apt update RUN apt install -y git COPY setup.sh . ENTRYPOINT ["bash", "setup.sh"] ci_cd_test/setup.sh 0 → 100644 +29 −0 Original line number Diff line number Diff line #!/bin/bash set -euo pipefail SDK_DIR="/sdk" SDK_REPO="https://labs.etsi.org/rep/ocf/sdk.git" SDK_JUST_INSTALLED="true" if [[ -d "$SDK_DIR/.git" ]]; then echo "OpenCAPIF SDK repository exists. Updating..." git -C "$SDK_DIR" pull SDK_JUST_INSTALLED="false" else echo "OpenCAPIF SDK repository not found. Cloning..." git clone "$SDK_REPO" "$SDK_DIR" fi ### !!! # python -m build echo "Installing OpenCAPIF SDK dependencies..." python -m pip install -r "$SDK_DIR/installation/requirements.txt" python -m pip install "$SDK_DIR" [[ "$SDK_JUST_INSTALLED" == "true" ]] && action_text="installation completed" || action_text="updated" echo "OpenCAPIF SDK $action_text successfully." tail -f /dev/null # TODO: Replace with actual entrypoint command (tests) network_app_samples/network_app_provider_sample/network_app_provider.py +1 −1 Original line number Diff line number Diff line Loading @@ -8,7 +8,7 @@ from werkzeug import serving capif_sdk_config_path = "./capif_sdk_config_sample.json" capif_sdk_config_path = "./testing_CICD_capif_sdk_config_sample.json" resilience_app = Flask("resilience_app") jwt_flask = JWTManager(resilience_app) Loading network_app_samples/network_app_provider_sample/testing_CICD_capif_sdk_config_sample.json 0 → 100644 +0 −0 Empty file added. Loading
ci_cd_test/Dockerfile 0 → 100644 +17 −0 Original line number Diff line number Diff line FROM labs.etsi.org:5050/ocf/capif/python:3-slim-bullseye RUN apt update RUN apt install -y git ARG BRANCH=main RUN echo "Cloning branch: ${BRANCH}" && \ git clone -b ${BRANCH} https://labs.etsi.org/rep/ocf/sdk.git WORKDIR /sdk RUN python -m pip install --upgrade pip RUN pip install -r installation/requirements.txt RUN pip install . ENTRYPOINT ["tail", "-f", "/dev/null"]
ci_cd_test/Dockerfile2 0 → 100644 +8 −0 Original line number Diff line number Diff line FROM labs.etsi.org:5050/ocf/capif/python:3-slim-bullseye RUN apt update RUN apt install -y git COPY setup.sh . ENTRYPOINT ["bash", "setup.sh"]
ci_cd_test/setup.sh 0 → 100644 +29 −0 Original line number Diff line number Diff line #!/bin/bash set -euo pipefail SDK_DIR="/sdk" SDK_REPO="https://labs.etsi.org/rep/ocf/sdk.git" SDK_JUST_INSTALLED="true" if [[ -d "$SDK_DIR/.git" ]]; then echo "OpenCAPIF SDK repository exists. Updating..." git -C "$SDK_DIR" pull SDK_JUST_INSTALLED="false" else echo "OpenCAPIF SDK repository not found. Cloning..." git clone "$SDK_REPO" "$SDK_DIR" fi ### !!! # python -m build echo "Installing OpenCAPIF SDK dependencies..." python -m pip install -r "$SDK_DIR/installation/requirements.txt" python -m pip install "$SDK_DIR" [[ "$SDK_JUST_INSTALLED" == "true" ]] && action_text="installation completed" || action_text="updated" echo "OpenCAPIF SDK $action_text successfully." tail -f /dev/null # TODO: Replace with actual entrypoint command (tests)
network_app_samples/network_app_provider_sample/network_app_provider.py +1 −1 Original line number Diff line number Diff line Loading @@ -8,7 +8,7 @@ from werkzeug import serving capif_sdk_config_path = "./capif_sdk_config_sample.json" capif_sdk_config_path = "./testing_CICD_capif_sdk_config_sample.json" resilience_app = Flask("resilience_app") jwt_flask = JWTManager(resilience_app) Loading
network_app_samples/network_app_provider_sample/testing_CICD_capif_sdk_config_sample.json 0 → 100644 +0 −0 Empty file added.