diff --git a/.gitignore b/.gitignore index c27c6be3e887423403f0be2a726fa4ef7edaa134..40d2726caa6c8b449d1c6de34025d9be0ac66f9a 100644 --- a/.gitignore +++ b/.gitignore @@ -19,15 +19,15 @@ services/easy_rsa/certs/*EasyRSA* services/easy_rsa/certs/*.profile services/easy_rsa/certs/*.csr -monitoring/grafana/grafana_db/* -!monitoring/grafana/grafana_db/.keep -monitoring/prometheus/prometheus_db/* -!monitoring/prometheus/prometheus_db/.keep -monitoring/prometheus/alert.rules/* -!monitoring/prometheus/alert.rules/.keep -monitoring/tempo/tempo-data/* -!monitoring/tempo/tempo-data/.keep - +services/monitoring/grafana/grafana_db/* +!services/monitoring/grafana/grafana_db/.keep +services/monitoring/prometheus/prometheus_db/* +!services/monitoring/prometheus/prometheus_db/.keep +services/monitoring/prometheus/alert.rules/* +!services/monitoring/prometheus/alert.rules/.keep +services/monitoring/tempo/tempo-data/* +!services/monitoring/tempo/tempo-data/.keep +services/monitoring/grafana/grafana_db/* docs/testing_with_postman/*node_modules* docs/testing_with_postman/Responses diff --git a/helm/capif/charts/mock-server/README.md b/helm/capif/charts/mock-server/README.md index 6a321e3e484476f3f87625b1cfa14ce70b98611a..d33a78a1b077381c3b7c4cc169e03917e02aac30 100644 --- a/helm/capif/charts/mock-server/README.md +++ b/helm/capif/charts/mock-server/README.md @@ -29,7 +29,7 @@ A Helm chart for Kubernetes of mock-server OCF | ingress.tls | list | `[]` | | | livenessProbe.initialDelaySeconds | int | `20` | | | livenessProbe.periodSeconds | int | `5` | | -| livenessProbe.tcpSocket.port | int | `9090` | | +| livenessProbe.tcpSocket.port | int | `9100` | | | nameOverride | string | `""` | | | nodeSelector | object | `{}` | | | podAnnotations | object | `{}` | | @@ -39,7 +39,7 @@ A Helm chart for Kubernetes of mock-server OCF | replicaCount | int | `1` | | | resources | object | `{}` | | | securityContext | object | `{}` | | -| service.port | int | `9090` | | +| service.port | int | `9100` | | | service.type | string | `"ClusterIP"` | | | serviceAccount.annotations | object | `{}` | | | serviceAccount.automount | bool | `true` | | diff --git a/helm/capif/charts/mock-server/values.yaml b/helm/capif/charts/mock-server/values.yaml index 058c7fe3ff49c3ecebbb381e46783a37bdb9262b..06de7306faf9f12d414d232909b550fbbc458d1a 100644 --- a/helm/capif/charts/mock-server/values.yaml +++ b/helm/capif/charts/mock-server/values.yaml @@ -46,7 +46,7 @@ securityContext: {} service: type: ClusterIP - port: 9090 + port: 9100 ingress: enabled: true @@ -78,7 +78,7 @@ resources: livenessProbe: tcpSocket: - port: 9090 + port: 9100 initialDelaySeconds: 20 periodSeconds: 5 readinessProbe: diff --git a/helm/scripts/create_remote_users.sh b/helm/scripts/create_remote_users.sh index 153ea33307b6c4f112cfcba579a6efb42ec1d0cc..a0209b31da4538e17dcb49b4c1343e903a029726 100755 --- a/helm/scripts/create_remote_users.sh +++ b/helm/scripts/create_remote_users.sh @@ -75,7 +75,14 @@ CAPIF_VAULT_TOKEN=$VAULT_ACCESS_TOKEN # Mock Server MOCK_SERVER_URL=http://mock-server-$CAPIF_CI_ENV_ENDPOINT.$CAPIF_DOMAIN:80 -NOTIFICATION_DESTINATION_URL=http://mock-server.$CAPIF_NAMESPACE.svc.cluster.local:9090 +NOTIFICATION_DESTINATION_URL=http://mock-server.$CAPIF_NAMESPACE.svc.cluster.local:9100 + +PLATFORM=$(uname -m) +if [ "x86_64" == "$PLATFORM" ]; then + DOCKER_ROBOT_IMAGE_VERSION=$DOCKER_ROBOT_IMAGE_VERSION-amd64 +else + DOCKER_ROBOT_IMAGE_VERSION=$DOCKER_ROBOT_IMAGE_VERSION-arm64 +fi # Show variables echo "CAPIF_HOSTNAME = $CAPIF_HOSTNAME" @@ -90,6 +97,7 @@ echo "USERNAME_PREFIX=$USERNAME_PREFIX" echo "USER_PASSWORD=$USER_PASSWORD" echo "MOCK_SERVER_URL=$MOCK_SERVER_URL" echo "NOTIFICATION_DESTINATION_URL=$NOTIFICATION_DESTINATION_URL" +echo "DOCKER_ROBOT_IMAGE = $DOCKER_ROBOT_IMAGE:$DOCKER_ROBOT_IMAGE_VERSION" docker >/dev/null 2>/dev/null if [[ $? -ne 0 ]] diff --git a/helm/scripts/populate_create_remote_dummy_users.sh b/helm/scripts/populate_create_remote_dummy_users.sh index 1dc89b172b326eb3f83a59c3ec0a9be3b3e86a54..3243db82bb52d55c481ac9bc92389e67742d9937 100755 --- a/helm/scripts/populate_create_remote_dummy_users.sh +++ b/helm/scripts/populate_create_remote_dummy_users.sh @@ -56,8 +56,14 @@ CAPIF_VAULT_TOKEN=$VAULT_ACCESS_TOKEN # Mock Server MOCK_SERVER_URL=http://mock-server-$CAPIF_CI_ENV_ENDPOINT.$CAPIF_DOMAIN:80 -NOTIFICATION_DESTINATION_URL=http://mock-server.$CAPIF_NAMESPACE.svc.cluster.local:9090 +NOTIFICATION_DESTINATION_URL=http://mock-server.$CAPIF_NAMESPACE.svc.cluster.local:9100 +PLATFORM=$(uname -m) +if [ "x86_64" == "$PLATFORM" ]; then + DOCKER_ROBOT_IMAGE_VERSION=$DOCKER_ROBOT_IMAGE_VERSION-amd64 +else + DOCKER_ROBOT_IMAGE_VERSION=$DOCKER_ROBOT_IMAGE_VERSION-arm64 +fi # Show variables echo "CAPIF_HOSTNAME = $CAPIF_HOSTNAME" @@ -72,6 +78,7 @@ echo "USERNAME_PREFIX=$USERNAME_PREFIX" echo "USER_PASSWORD=$USER_PASSWORD" echo "MOCK_SERVER_URL=$MOCK_SERVER_URL" echo "NOTIFICATION_DESTINATION_URL=$NOTIFICATION_DESTINATION_URL" +echo "DOCKER_ROBOT_IMAGE = $DOCKER_ROBOT_IMAGE:$DOCKER_ROBOT_IMAGE_VERSION" docker >/dev/null 2>/dev/null if [[ $? -ne 0 ]] diff --git a/helm/scripts/populate_remove_remote_dummy_users.sh b/helm/scripts/populate_remove_remote_dummy_users.sh index 3bcde327dc48da5d6f8d74cc904f593a47b9dc10..7847525ef7004e37789866e30947f2f27358b2bf 100755 --- a/helm/scripts/populate_remove_remote_dummy_users.sh +++ b/helm/scripts/populate_remove_remote_dummy_users.sh @@ -45,8 +45,14 @@ CAPIF_VAULT_TOKEN=$VAULT_ACCESS_TOKEN # Mock Server MOCK_SERVER_URL=http://mock-server-$CAPIF_CI_ENV_ENDPOINT.$CAPIF_DOMAIN:80 -NOTIFICATION_DESTINATION_URL=http://mock-server.$CAPIF_NAMESPACE.svc.cluster.local:9090 +NOTIFICATION_DESTINATION_URL=http://mock-server.$CAPIF_NAMESPACE.svc.cluster.local:9100 +PLATFORM=$(uname -m) +if [ "x86_64" == "$PLATFORM" ]; then + DOCKER_ROBOT_IMAGE_VERSION=$DOCKER_ROBOT_IMAGE_VERSION-amd64 +else + DOCKER_ROBOT_IMAGE_VERSION=$DOCKER_ROBOT_IMAGE_VERSION-arm64 +fi # Show variables echo "CAPIF_HOSTNAME = $CAPIF_HOSTNAME" @@ -61,6 +67,7 @@ echo "USERNAME_PREFIX=$USERNAME_PREFIX" echo "USER_PASSWORD=$USER_PASSWORD" echo "MOCK_SERVER_URL=$MOCK_SERVER_URL" echo "NOTIFICATION_DESTINATION_URL=$NOTIFICATION_DESTINATION_URL" +echo "DOCKER_ROBOT_IMAGE = $DOCKER_ROBOT_IMAGE:$DOCKER_ROBOT_IMAGE_VERSION" docker >/dev/null 2>/dev/null if [[ $? -ne 0 ]] diff --git a/helm/scripts/remove_remote_users.sh b/helm/scripts/remove_remote_users.sh index 98f3f3f5b5027957220d134ba1feab55118838ba..dc6fa7620590aabca3fbeb11384a2f48d85735a7 100755 --- a/helm/scripts/remove_remote_users.sh +++ b/helm/scripts/remove_remote_users.sh @@ -12,7 +12,7 @@ help() { } # Read params -while getopts ":u:p:t:h" opt; do +while getopts ":u:h" opt; do case $opt in u) USERNAME_PREFIX="$OPTARG" @@ -58,7 +58,14 @@ CAPIF_VAULT_TOKEN=$VAULT_ACCESS_TOKEN # Mock Server MOCK_SERVER_URL=http://mock-server-$CAPIF_CI_ENV_ENDPOINT.$CAPIF_DOMAIN:80 -NOTIFICATION_DESTINATION_URL=http://mock-server.$CAPIF_NAMESPACE.svc.cluster.local:9090 +NOTIFICATION_DESTINATION_URL=http://mock-server.$CAPIF_NAMESPACE.svc.cluster.local:9100 + +PLATFORM=$(uname -m) +if [ "x86_64" == "$PLATFORM" ]; then + DOCKER_ROBOT_IMAGE_VERSION=$DOCKER_ROBOT_IMAGE_VERSION-amd64 +else + DOCKER_ROBOT_IMAGE_VERSION=$DOCKER_ROBOT_IMAGE_VERSION-arm64 +fi # Show variables echo "CAPIF_HOSTNAME = $CAPIF_HOSTNAME" @@ -73,6 +80,7 @@ echo "USERNAME_PREFIX=$USERNAME_PREFIX" echo "USER_PASSWORD=$USER_PASSWORD" echo "MOCK_SERVER_URL=$MOCK_SERVER_URL" echo "NOTIFICATION_DESTINATION_URL=$NOTIFICATION_DESTINATION_URL" +echo "DOCKER_ROBOT_IMAGE = $DOCKER_ROBOT_IMAGE:$DOCKER_ROBOT_IMAGE_VERSION" docker >/dev/null 2>/dev/null if [[ $? -ne 0 ]] diff --git a/helm/scripts/remove_remote_users_by_prefix.sh b/helm/scripts/remove_remote_users_by_prefix.sh index 9f084e6ba055dd6c9147fe54fea29866e81541d3..003d694feec94cb1038ebdd5f3cd61370960a3d0 100755 --- a/helm/scripts/remove_remote_users_by_prefix.sh +++ b/helm/scripts/remove_remote_users_by_prefix.sh @@ -12,7 +12,7 @@ help() { } # Read params -while getopts ":u:p:t:h" opt; do +while getopts ":u:h" opt; do case $opt in u) USERNAME_PREFIX="$OPTARG" @@ -58,7 +58,14 @@ CAPIF_VAULT_TOKEN=$VAULT_ACCESS_TOKEN # Mock Server MOCK_SERVER_URL=http://mock-server-$CAPIF_CI_ENV_ENDPOINT.$CAPIF_DOMAIN:80 -NOTIFICATION_DESTINATION_URL=http://mock-server.$CAPIF_NAMESPACE.svc.cluster.local:9090 +NOTIFICATION_DESTINATION_URL=http://mock-server.$CAPIF_NAMESPACE.svc.cluster.local:9100 + +PLATFORM=$(uname -m) +if [ "x86_64" == "$PLATFORM" ]; then + DOCKER_ROBOT_IMAGE_VERSION=$DOCKER_ROBOT_IMAGE_VERSION-amd64 +else + DOCKER_ROBOT_IMAGE_VERSION=$DOCKER_ROBOT_IMAGE_VERSION-arm64 +fi # Show variables echo "CAPIF_HOSTNAME = $CAPIF_HOSTNAME" @@ -73,6 +80,7 @@ echo "USERNAME_PREFIX=$USERNAME_PREFIX" echo "USER_PASSWORD=$USER_PASSWORD" echo "MOCK_SERVER_URL=$MOCK_SERVER_URL" echo "NOTIFICATION_DESTINATION_URL=$NOTIFICATION_DESTINATION_URL" +echo "DOCKER_ROBOT_IMAGE = $DOCKER_ROBOT_IMAGE:$DOCKER_ROBOT_IMAGE_VERSION" docker >/dev/null 2>/dev/null if [[ $? -ne 0 ]] diff --git a/helm/scripts/run_remote_capif_tests.sh b/helm/scripts/run_remote_capif_tests.sh index 6f67bb574a734aefeaf608bc6d89fe3c49121f10..38b7e807399963c8bb2b5be342cee4c56c6d8693 100755 --- a/helm/scripts/run_remote_capif_tests.sh +++ b/helm/scripts/run_remote_capif_tests.sh @@ -20,7 +20,14 @@ CAPIF_VAULT_TOKEN=$VAULT_ACCESS_TOKEN MOCK_SERVER_URL=http://mock-server-$CAPIF_CI_ENV_ENDPOINT.$CAPIF_DOMAIN:80 -NOTIFICATION_DESTINATION_URL=http://mock-server.$CAPIF_NAMESPACE.svc.cluster.local:9090 +NOTIFICATION_DESTINATION_URL=http://mock-server.$CAPIF_NAMESPACE.svc.cluster.local:9100 + +PLATFORM=$(uname -m) +if [ "x86_64" == "$PLATFORM" ]; then + DOCKER_ROBOT_IMAGE_VERSION=$DOCKER_ROBOT_IMAGE_VERSION-amd64 +else + DOCKER_ROBOT_IMAGE_VERSION=$DOCKER_ROBOT_IMAGE_VERSION-arm64 +fi echo "CAPIF_HOSTNAME = $CAPIF_HOSTNAME" echo "CAPIF_REGISTER = $REGISTER_HOSTNAME" @@ -29,6 +36,7 @@ echo "CAPIF_VAULT = $VAULT_INTERNAL_HOSTNAME" echo "CAPIF_VAULT_PORT = $VAULT_PORT" echo "CAPIF_VAULT_TOKEN = $VAULT_ACCESS_TOKEN" echo "MOCK_SERVER_URL = $MOCK_SERVER_URL" +echo "DOCKER_ROBOT_IMAGE = $DOCKER_ROBOT_IMAGE:$DOCKER_ROBOT_IMAGE_VERSION" INPUT_OPTIONS=$@ # Check if input is provided diff --git a/services/TS29222_CAPIF_API_Invoker_Management_API/Dockerfile b/services/TS29222_CAPIF_API_Invoker_Management_API/Dockerfile index d544fc17ee7f4ee4ec6a75c410de7f4c7daa948f..2d8bbe74dae1305697234308fd67e65f05f82920 100644 --- a/services/TS29222_CAPIF_API_Invoker_Management_API/Dockerfile +++ b/services/TS29222_CAPIF_API_Invoker_Management_API/Dockerfile @@ -1,15 +1,21 @@ -FROM labs.etsi.org:5050/ocf/capif/python:3-alpine +FROM labs.etsi.org:5050/ocf/capif/python:3-slim-bullseye RUN mkdir -p /usr/src/app WORKDIR /usr/src/app COPY requirements.txt /usr/src/app/requirements.txt -RUN apk add -U --no-cache gcc build-base linux-headers ca-certificates libffi-dev libressl-dev libxslt-dev +RUN apt-get update && apt-get install -y --no-install-recommends \ + gcc \ + build-essential \ + linux-headers-generic \ + ca-certificates \ + libffi-dev \ + libssl-dev \ + libxslt1-dev && \ + rm -rf /var/lib/apt/lists/* RUN pip3 install --no-cache-dir -r requirements.txt -RUN apk add redis -RUN apk add jq -RUN apk add curl +RUN apt-get update && apt-get install -y --no-install-recommends jq curl redis COPY . /usr/src/app diff --git a/services/TS29222_CAPIF_API_Provider_Management_API/Dockerfile b/services/TS29222_CAPIF_API_Provider_Management_API/Dockerfile index 867e52dcf638efc0273547fd8c4eec997ec73e83..a6ee27499f6c07ccfa46f443bfa9c9c3dddcc666 100644 --- a/services/TS29222_CAPIF_API_Provider_Management_API/Dockerfile +++ b/services/TS29222_CAPIF_API_Provider_Management_API/Dockerfile @@ -1,15 +1,21 @@ -FROM labs.etsi.org:5050/ocf/capif/python:3-alpine +FROM labs.etsi.org:5050/ocf/capif/python:3-slim-bullseye RUN mkdir -p /usr/src/app WORKDIR /usr/src/app COPY requirements.txt /usr/src/app/ -RUN apk add -U --no-cache gcc build-base linux-headers ca-certificates libffi-dev libressl-dev libxslt-dev +RUN apt-get update && apt-get install -y --no-install-recommends \ + gcc \ + build-essential \ + linux-headers-generic \ + ca-certificates \ + libffi-dev \ + libssl-dev \ + libxslt1-dev && \ + rm -rf /var/lib/apt/lists/* RUN pip3 install --no-cache-dir -r requirements.txt -RUN apk add redis -RUN apk add jq -RUN apk add curl +RUN apt-get update && apt-get install -y --no-install-recommends jq curl redis COPY . /usr/src/app diff --git a/services/TS29222_CAPIF_Access_Control_Policy_API/Dockerfile b/services/TS29222_CAPIF_Access_Control_Policy_API/Dockerfile index 0de5ebba180dcd14bce63c02a4dc7aff64995a69..b10cb585a4ba305ee3ecf4eee64194f49d4f4a25 100644 --- a/services/TS29222_CAPIF_Access_Control_Policy_API/Dockerfile +++ b/services/TS29222_CAPIF_Access_Control_Policy_API/Dockerfile @@ -1,4 +1,4 @@ -FROM labs.etsi.org:5050/ocf/capif/python:3-alpine +FROM labs.etsi.org:5050/ocf/capif/python:3-slim-bullseye RUN mkdir -p /usr/src/app WORKDIR /usr/src/app diff --git a/services/TS29222_CAPIF_Auditing_API/Dockerfile b/services/TS29222_CAPIF_Auditing_API/Dockerfile index 0435a4cfcf7ea5d2fa0edc17eabf6130ab9b78a5..909445e22087b5f3cb04c9c08405a8eea5b59d32 100644 --- a/services/TS29222_CAPIF_Auditing_API/Dockerfile +++ b/services/TS29222_CAPIF_Auditing_API/Dockerfile @@ -1,11 +1,19 @@ -FROM labs.etsi.org:5050/ocf/capif/python:3-alpine +FROM labs.etsi.org:5050/ocf/capif/python:3-slim-bullseye RUN mkdir -p /usr/src/app WORKDIR /usr/src/app COPY requirements.txt /usr/src/app/requirements.txt -RUN apk add -U --no-cache gcc build-base linux-headers ca-certificates libffi-dev libressl-dev libxslt-dev +RUN apt-get update && apt-get install -y --no-install-recommends \ + gcc \ + build-essential \ + linux-headers-generic \ + ca-certificates \ + libffi-dev \ + libssl-dev \ + libxslt1-dev && \ + rm -rf /var/lib/apt/lists/* RUN pip3 install --no-cache-dir -r requirements.txt COPY . /usr/src/app diff --git a/services/TS29222_CAPIF_Discover_Service_API/Dockerfile b/services/TS29222_CAPIF_Discover_Service_API/Dockerfile index 859ad379ab1d261818186d21a83055fbc94e4c86..350f5883ead9947dc54a608eee32cf2379d8d9fa 100644 --- a/services/TS29222_CAPIF_Discover_Service_API/Dockerfile +++ b/services/TS29222_CAPIF_Discover_Service_API/Dockerfile @@ -1,11 +1,19 @@ -FROM labs.etsi.org:5050/ocf/capif/python:3-alpine +FROM labs.etsi.org:5050/ocf/capif/python:3-slim-bullseye RUN mkdir -p /usr/src/app WORKDIR /usr/src/app COPY requirements.txt /usr/src/app/requirements.txt -RUN apk add -U --no-cache gcc build-base linux-headers ca-certificates libffi-dev libressl-dev libxslt-dev +RUN apt-get update && apt-get install -y --no-install-recommends \ + gcc \ + build-essential \ + linux-headers-generic \ + ca-certificates \ + libffi-dev \ + libssl-dev \ + libxslt1-dev && \ + rm -rf /var/lib/apt/lists/* RUN pip3 install --no-cache-dir -r requirements.txt COPY . /usr/src/app diff --git a/services/TS29222_CAPIF_Events_API/Dockerfile b/services/TS29222_CAPIF_Events_API/Dockerfile index 1fcfe7228aa4e1806619d4785e9f903a71458bce..b69327af156c0105c49fd0378186c6ebe1d4ea94 100644 --- a/services/TS29222_CAPIF_Events_API/Dockerfile +++ b/services/TS29222_CAPIF_Events_API/Dockerfile @@ -1,4 +1,4 @@ -FROM labs.etsi.org:5050/ocf/capif/python:3-alpine +FROM labs.etsi.org:5050/ocf/capif/python:3-slim-bullseye RUN mkdir -p /usr/src/app WORKDIR /usr/src/app @@ -6,7 +6,15 @@ WORKDIR /usr/src/app COPY requirements.txt /usr/src/app/requirements.txt COPY config.yaml /usr/src/app/config.yaml -RUN apk add -U --no-cache gcc build-base linux-headers ca-certificates libffi-dev libressl-dev libxslt-dev +RUN apt-get update && apt-get install -y --no-install-recommends \ + gcc \ + build-essential \ + linux-headers-generic \ + ca-certificates \ + libffi-dev \ + libssl-dev \ + libxslt1-dev && \ + rm -rf /var/lib/apt/lists/* RUN pip3 install --no-cache-dir -r requirements.txt COPY . /usr/src/app diff --git a/services/TS29222_CAPIF_Logging_API_Invocation_API/Dockerfile b/services/TS29222_CAPIF_Logging_API_Invocation_API/Dockerfile index 55d6d831dc6fc7df27e54660ce76094b033cf8b9..d68f8ce5c0030446f8e5c5a32f09ac0abc5f7cd3 100644 --- a/services/TS29222_CAPIF_Logging_API_Invocation_API/Dockerfile +++ b/services/TS29222_CAPIF_Logging_API_Invocation_API/Dockerfile @@ -1,11 +1,19 @@ -FROM labs.etsi.org:5050/ocf/capif/python:3-alpine +FROM labs.etsi.org:5050/ocf/capif/python:3-slim-bullseye RUN mkdir -p /usr/src/app WORKDIR /usr/src/app COPY requirements.txt /usr/src/app/requirements.txt -RUN apk add -U --no-cache gcc build-base linux-headers ca-certificates libffi-dev libressl-dev libxslt-dev +RUN apt-get update && apt-get install -y --no-install-recommends \ + gcc \ + build-essential \ + linux-headers-generic \ + ca-certificates \ + libffi-dev \ + libssl-dev \ + libxslt1-dev && \ + rm -rf /var/lib/apt/lists/* RUN pip3 install --no-cache-dir -r requirements.txt COPY . /usr/src/app diff --git a/services/TS29222_CAPIF_Publish_Service_API/Dockerfile b/services/TS29222_CAPIF_Publish_Service_API/Dockerfile index 6a044e0dd3121d9388d82a439dc15d2b133eebbd..fc3504b1abcb82718b3d0079bb59cb3be5e93b93 100644 --- a/services/TS29222_CAPIF_Publish_Service_API/Dockerfile +++ b/services/TS29222_CAPIF_Publish_Service_API/Dockerfile @@ -1,11 +1,19 @@ -FROM labs.etsi.org:5050/ocf/capif/python:3-alpine +FROM labs.etsi.org:5050/ocf/capif/python:3-slim-bullseye RUN mkdir -p /usr/src/app WORKDIR /usr/src/app COPY requirements.txt /usr/src/app/requirements.txt -RUN apk add -U --no-cache gcc build-base linux-headers ca-certificates libffi-dev libressl-dev libxslt-dev +RUN apt-get update && apt-get install -y --no-install-recommends \ + gcc \ + build-essential \ + linux-headers-generic \ + ca-certificates \ + libffi-dev \ + libssl-dev \ + libxslt1-dev && \ + rm -rf /var/lib/apt/lists/* RUN pip3 install --no-cache-dir -r requirements.txt COPY . /usr/src/app diff --git a/services/TS29222_CAPIF_Routing_Info_API/Dockerfile b/services/TS29222_CAPIF_Routing_Info_API/Dockerfile index 616c1db8f632fad65234c9acd123801cd5902b13..0f3e0e4662735f614c19a357c185d424463d04cb 100644 --- a/services/TS29222_CAPIF_Routing_Info_API/Dockerfile +++ b/services/TS29222_CAPIF_Routing_Info_API/Dockerfile @@ -1,4 +1,4 @@ -FROM labs.etsi.org:5050/ocf/capif/python:3-alpine +FROM labs.etsi.org:5050/ocf/capif/python:3-slim-bullseye RUN mkdir -p /usr/src/app WORKDIR /usr/src/app diff --git a/services/TS29222_CAPIF_Security_API/Dockerfile b/services/TS29222_CAPIF_Security_API/Dockerfile index cb18c9d5e7f9771ab569c0efddb3f482f36fc3b6..eef4705c082320893abe94ba90159b54187b47e1 100644 --- a/services/TS29222_CAPIF_Security_API/Dockerfile +++ b/services/TS29222_CAPIF_Security_API/Dockerfile @@ -1,14 +1,21 @@ -FROM labs.etsi.org:5050/ocf/capif/python:3-alpine +FROM labs.etsi.org:5050/ocf/capif/python:3-slim-bullseye RUN mkdir -p /usr/src/app WORKDIR /usr/src/app COPY requirements.txt /usr/src/app/requirements.txt -RUN apk add -U --no-cache gcc build-base linux-headers ca-certificates libffi-dev libressl-dev libxslt-dev -RUN apk add redis -RUN apk add jq -RUN apk add curl +RUN apt-get update && apt-get install -y --no-install-recommends \ + gcc \ + build-essential \ + linux-headers-generic \ + ca-certificates \ + libffi-dev \ + libssl-dev \ + libxslt1-dev && \ + rm -rf /var/lib/apt/lists/* +RUN apt-get update && apt-get install -y --no-install-recommends jq curl redis + RUN pip3 install --no-cache-dir -r requirements.txt COPY . /usr/src/app diff --git a/services/create_users.sh b/services/create_users.sh index 14066a8ef5277d0befa11698ab14e2d3365af3dd..d285bd1e1c3b5f7013ea9f835e0c433b4f6cc048 100755 --- a/services/create_users.sh +++ b/services/create_users.sh @@ -1,5 +1,4 @@ #!/bin/bash -LOCAL=true # User to create TOTAL_USERS=1 @@ -81,9 +80,16 @@ CAPIF_VAULT_PORT=8200 CAPIF_VAULT_TOKEN=read-ca-token # Mock Server -MOCK_SERVER_URL=http://mock-server:9090 +MOCK_SERVER_URL=http://mock-server:9100 NOTIFICATION_DESTINATION_URL=$MOCK_SERVER_URL +PLATFORM=$(uname -m) +if [ "x86_64" == "$PLATFORM" ]; then + DOCKER_ROBOT_IMAGE_VERSION=$DOCKER_ROBOT_IMAGE_VERSION-amd64 +else + DOCKER_ROBOT_IMAGE_VERSION=$DOCKER_ROBOT_IMAGE_VERSION-arm64 +fi + # Show variables echo "CAPIF_HOSTNAME = $CAPIF_HOSTNAME" echo "CAPIF_REGISTER = $CAPIF_REGISTER" @@ -97,6 +103,7 @@ echo "USERNAME_PREFIX=$USERNAME_PREFIX" echo "USER_PASSWORD=$USER_PASSWORD" echo "MOCK_SERVER_URL=$MOCK_SERVER_URL" echo "NOTIFICATION_DESTINATION_URL=$NOTIFICATION_DESTINATION_URL" +echo "DOCKER_ROBOT_IMAGE = $DOCKER_ROBOT_IMAGE:$DOCKER_ROBOT_IMAGE_VERSION" docker >/dev/null 2>/dev/null if [[ $? -ne 0 ]] @@ -123,45 +130,25 @@ fi mkdir -p $RESULT_FOLDER -if [[ "$LOCAL" == "true" ]] -then - docker run -ti --rm --network="host" \ - --add-host host.docker.internal:host-gateway \ - --add-host vault:host-gateway \ - --add-host register:host-gateway \ - --add-host mock-server:host-gateway \ - -v $TEST_FOLDER:/opt/robot-tests/tests \ - -v $RESULT_FOLDER:/opt/robot-tests/results ${DOCKER_ROBOT_IMAGE}:${DOCKER_ROBOT_IMAGE_VERSION} \ - --variable CAPIF_HOSTNAME:$CAPIF_HOSTNAME \ - --variable CAPIF_HTTP_PORT:$CAPIF_HTTP_PORT \ - --variable CAPIF_HTTPS_PORT:$CAPIF_HTTPS_PORT \ - --variable CAPIF_REGISTER:$CAPIF_REGISTER \ - --variable CAPIF_REGISTER_PORT:$CAPIF_REGISTER_PORT \ - --variable CAPIF_VAULT:$CAPIF_VAULT \ - --variable CAPIF_VAULT_PORT:$CAPIF_VAULT_PORT \ - --variable CAPIF_VAULT_TOKEN:$CAPIF_VAULT_TOKEN \ - --variable NOTIFICATION_DESTINATION_URL:$NOTIFICATION_DESTINATION_URL \ - --variable MOCK_SERVER_URL:$MOCK_SERVER_URL \ - --variable TOTAL_USERS:$TOTAL_USERS \ - --variable USERNAME_PREFIX:$USERNAME_PREFIX \ - --variable USER_PASSWORD:$USER_PASSWORD \ - --include create-users -else - docker run -ti --rm --network="host" \ - -v $TEST_FOLDER:/opt/robot-tests/tests \ - -v $RESULT_FOLDER:/opt/robot-tests/results ${DOCKER_ROBOT_IMAGE}:${DOCKER_ROBOT_IMAGE_VERSION} \ - --variable CAPIF_HOSTNAME:$CAPIF_HOSTNAME \ - --variable CAPIF_HTTP_PORT:$CAPIF_HTTP_PORT \ - --variable CAPIF_HTTPS_PORT:$CAPIF_HTTPS_PORT \ - --variable CAPIF_REGISTER:$CAPIF_REGISTER \ - --variable CAPIF_REGISTER_PORT:$CAPIF_REGISTER_PORT \ - --variable CAPIF_VAULT:$CAPIF_VAULT \ - --variable CAPIF_VAULT_PORT:$CAPIF_VAULT_PORT \ - --variable CAPIF_VAULT_TOKEN:$CAPIF_VAULT_TOKEN \ - --variable NOTIFICATION_DESTINATION_URL:$NOTIFICATION_DESTINATION_URL \ - --variable MOCK_SERVER_URL:$MOCK_SERVER_URL \ - --variable TOTAL_USERS:$TOTAL_USERS \ - --variable USERNAME_PREFIX:$USERNAME_PREFIX \ - --variable USER_PASSWORD:$USER_PASSWORD \ - --include create-users -fi \ No newline at end of file + +docker run -ti --rm --network="host" \ + --add-host host.docker.internal:host-gateway \ + --add-host vault:host-gateway \ + --add-host register:host-gateway \ + --add-host mock-server:host-gateway \ + -v $TEST_FOLDER:/opt/robot-tests/tests \ + -v $RESULT_FOLDER:/opt/robot-tests/results ${DOCKER_ROBOT_IMAGE}:${DOCKER_ROBOT_IMAGE_VERSION} \ + --variable CAPIF_HOSTNAME:$CAPIF_HOSTNAME \ + --variable CAPIF_HTTP_PORT:$CAPIF_HTTP_PORT \ + --variable CAPIF_HTTPS_PORT:$CAPIF_HTTPS_PORT \ + --variable CAPIF_REGISTER:$CAPIF_REGISTER \ + --variable CAPIF_REGISTER_PORT:$CAPIF_REGISTER_PORT \ + --variable CAPIF_VAULT:$CAPIF_VAULT \ + --variable CAPIF_VAULT_PORT:$CAPIF_VAULT_PORT \ + --variable CAPIF_VAULT_TOKEN:$CAPIF_VAULT_TOKEN \ + --variable NOTIFICATION_DESTINATION_URL:$NOTIFICATION_DESTINATION_URL \ + --variable MOCK_SERVER_URL:$MOCK_SERVER_URL \ + --variable TOTAL_USERS:$TOTAL_USERS \ + --variable USERNAME_PREFIX:$USERNAME_PREFIX \ + --variable USER_PASSWORD:$USER_PASSWORD \ + --include create-users diff --git a/services/docker-compose-capif.yml b/services/docker-compose-capif.yml index 7d08526c90c10641ada9b79a3a6a756170626738..8aa7d02deb7fcf890888c7c703bf16d0b04f9ea3 100644 --- a/services/docker-compose-capif.yml +++ b/services/docker-compose-capif.yml @@ -12,7 +12,7 @@ services: helper: - build: + build: context: ./helper expose: - "8080" @@ -37,7 +37,8 @@ services: - nginx access-control-policy: - build: TS29222_CAPIF_Access_Control_Policy_API + build: + context: ./TS29222_CAPIF_Access_Control_Policy_API expose: - "8080" volumes: @@ -82,7 +83,8 @@ services: - nginx api-provider-management: - build: TS29222_CAPIF_API_Provider_Management_API/. + build: + context: ./TS29222_CAPIF_API_Provider_Management_API expose: - "8080" volumes: @@ -145,7 +147,8 @@ services: - mongo capif-events: - build: TS29222_CAPIF_Events_API/. + build: + context: ./TS29222_CAPIF_Events_API expose: - "8080" volumes: @@ -185,7 +188,8 @@ services: - mongo published-apis: - build: TS29222_CAPIF_Publish_Service_API/. + build: + context: ./TS29222_CAPIF_Publish_Service_API expose: - "8080" volumes: @@ -205,13 +209,15 @@ services: - mongo capif-routing-info: - build: TS29222_CAPIF_Routing_Info_API/. + build: + context: ./TS29222_CAPIF_Routing_Info_API expose: - "8080" image: labs.etsi.org:5050/ocf/capif/routing-info-api:v2.x.x-release capif-security: - build: TS29222_CAPIF_Security_API/. + build: + context: ./TS29222_CAPIF_Security_API expose: - "8080" volumes: diff --git a/services/docker-compose-mock-server.yml b/services/docker-compose-mock-server.yml index 0b941271b3cd299f38c1ad72a918d4fb8edbda41..2529b8d8b5af681bc57c767b505a0c8ea945c606 100644 --- a/services/docker-compose-mock-server.yml +++ b/services/docker-compose-mock-server.yml @@ -3,7 +3,7 @@ services: build: context: ./mock_server ports: - - 9090:9090 + - 9100:9100 volumes: - ./mock_server:/usr/src/app extra_hosts: diff --git a/services/helper/Dockerfile b/services/helper/Dockerfile index f313ad8f36bb4f1512fa45066d3f7cfd982dad42..78c9a2e0bd3f1de4d6d1052bb9de694e00569408 100644 --- a/services/helper/Dockerfile +++ b/services/helper/Dockerfile @@ -1,13 +1,22 @@ -FROM labs.etsi.org:5050/ocf/capif/python:3-alpine +FROM labs.etsi.org:5050/ocf/capif/python:3-slim-bullseye RUN mkdir -p /usr/src/app WORKDIR /usr/src/app COPY requirements.txt /usr/src/app/requirements.txt -RUN apk add -U --no-cache gcc build-base linux-headers ca-certificates libffi-dev libressl-dev libxslt-dev +RUN apt-get update && apt-get install -y --no-install-recommends \ + gcc \ + build-essential \ + linux-headers-generic \ + ca-certificates \ + libffi-dev \ + libssl-dev \ + libxslt1-dev && \ + rm -rf /var/lib/apt/lists/* + RUN pip3 install --no-cache-dir -r requirements.txt -RUN apk add openssl curl redis +RUN apt-get update && apt-get install -y --no-install-recommends openssl curl redis COPY . /usr/src/app diff --git a/services/mock_server/Dockerfile b/services/mock_server/Dockerfile index 541395da8c166d2603a241b7cb2e1aa348fdd8c7..da6840802135931e41c0ec66c0db2341f4416d76 100644 --- a/services/mock_server/Dockerfile +++ b/services/mock_server/Dockerfile @@ -1,5 +1,5 @@ # start by pulling the python image -FROM labs.etsi.org:5050/ocf/capif/python:3-alpine +FROM labs.etsi.org:5050/ocf/capif/python:3-slim-bullseye # copy the requirements file into the image COPY ./requirements.txt /app/requirements.txt @@ -13,7 +13,7 @@ RUN pip install -r requirements.txt # copy every content from the local file to the image COPY . /app -EXPOSE 9090 +EXPOSE 9100 # configure the container to run in an executed manner ENTRYPOINT [ "python" ] diff --git a/services/mock_server/mock_server.py b/services/mock_server/mock_server.py index 41ba65066d81a1857f53a69eb752995c6bd14210..a3d26b84f5dacca484b371513c674853370d0868 100644 --- a/services/mock_server/mock_server.py +++ b/services/mock_server/mock_server.py @@ -57,4 +57,4 @@ def requests_list(): configure_logging(app) if __name__ == '__main__': - app.run(host=os.environ.get("IP",'0.0.0.0'),port=os.environ.get("PORT",9090),debug=True) + app.run(host=os.environ.get("IP",'0.0.0.0'),port=os.environ.get("PORT",9100),debug=True) diff --git a/services/monitoring/grafana/grafana_db/grafana.db b/services/monitoring/grafana/grafana_db/grafana.db deleted file mode 100644 index 78af2bae35edeccd5788efab79568fa54281fb41..0000000000000000000000000000000000000000 Binary files a/services/monitoring/grafana/grafana_db/grafana.db and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/01HVSTBRKRPHTKGXWB222EZ4ZY/chunks/000001 b/services/monitoring/prometheus/prometheus_db/data/01HVSTBRKRPHTKGXWB222EZ4ZY/chunks/000001 deleted file mode 100644 index 1b94dcf33ae22898b49c551f5cbd93e0f92bd1fb..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/01HVSTBRKRPHTKGXWB222EZ4ZY/chunks/000001 and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/01HVSTBRKRPHTKGXWB222EZ4ZY/index b/services/monitoring/prometheus/prometheus_db/data/01HVSTBRKRPHTKGXWB222EZ4ZY/index deleted file mode 100644 index 6974dd2b07146016d5fede24d4c7b8c7bececd54..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/01HVSTBRKRPHTKGXWB222EZ4ZY/index and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/01HVSTBRKRPHTKGXWB222EZ4ZY/meta.json b/services/monitoring/prometheus/prometheus_db/data/01HVSTBRKRPHTKGXWB222EZ4ZY/meta.json deleted file mode 100644 index 6155762fea7fa4fbfbed7d2846b9f15d1d8dd400..0000000000000000000000000000000000000000 --- a/services/monitoring/prometheus/prometheus_db/data/01HVSTBRKRPHTKGXWB222EZ4ZY/meta.json +++ /dev/null @@ -1,30 +0,0 @@ -{ - "ulid": "01HVSTBRKRPHTKGXWB222EZ4ZY", - "minTime": 1713449906811, - "maxTime": 1713463200000, - "stats": { - "numSamples": 920061, - "numSeries": 8403, - "numChunks": 14070 - }, - "compaction": { - "level": 2, - "sources": [ - "01HVS3ZJGFCP273BZ2227QCBQP", - "01HVSCQJ99F8BAWEZYFAW5DPMG" - ], - "parents": [ - { - "ulid": "01HVS3ZJGFCP273BZ2227QCBQP", - "minTime": 1713449906811, - "maxTime": 1713456000000 - }, - { - "ulid": "01HVSCQJ99F8BAWEZYFAW5DPMG", - "minTime": 1713457156573, - "maxTime": 1713463200000 - } - ] - }, - "version": 1 -} \ No newline at end of file diff --git a/services/monitoring/prometheus/prometheus_db/data/01HVSTBRKRPHTKGXWB222EZ4ZY/tombstones b/services/monitoring/prometheus/prometheus_db/data/01HVSTBRKRPHTKGXWB222EZ4ZY/tombstones deleted file mode 100644 index 95fb83272e6f55edeee7e5d86bdec5fcd217eae0..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/01HVSTBRKRPHTKGXWB222EZ4ZY/tombstones and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/01HVT7QVBXPCA5GM8AH9RQ5MJ3/chunks/000001 b/services/monitoring/prometheus/prometheus_db/data/01HVT7QVBXPCA5GM8AH9RQ5MJ3/chunks/000001 deleted file mode 100644 index 614ed33d71a4964ff8fe700fa69da483fe3d6a23..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/01HVT7QVBXPCA5GM8AH9RQ5MJ3/chunks/000001 and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/01HVT7QVBXPCA5GM8AH9RQ5MJ3/index b/services/monitoring/prometheus/prometheus_db/data/01HVT7QVBXPCA5GM8AH9RQ5MJ3/index deleted file mode 100644 index 84d895731cebb63997dadb85f77e800fd3456dd1..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/01HVT7QVBXPCA5GM8AH9RQ5MJ3/index and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/01HVT7QVBXPCA5GM8AH9RQ5MJ3/meta.json b/services/monitoring/prometheus/prometheus_db/data/01HVT7QVBXPCA5GM8AH9RQ5MJ3/meta.json deleted file mode 100644 index 9f6bc9508688e41649976c6bc2eb5ce1df5134f4..0000000000000000000000000000000000000000 --- a/services/monitoring/prometheus/prometheus_db/data/01HVT7QVBXPCA5GM8AH9RQ5MJ3/meta.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "ulid": "01HVT7QVBXPCA5GM8AH9RQ5MJ3", - "minTime": 1713486181515, - "maxTime": 1713492000000, - "stats": { - "numSamples": 10197, - "numSeries": 5289, - "numChunks": 5289 - }, - "compaction": { - "level": 1, - "sources": [ - "01HVT7QVBXPCA5GM8AH9RQ5MJ3" - ] - }, - "version": 1 -} \ No newline at end of file diff --git a/services/monitoring/prometheus/prometheus_db/data/01HVT7QVBXPCA5GM8AH9RQ5MJ3/tombstones b/services/monitoring/prometheus/prometheus_db/data/01HVT7QVBXPCA5GM8AH9RQ5MJ3/tombstones deleted file mode 100644 index 95fb83272e6f55edeee7e5d86bdec5fcd217eae0..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/01HVT7QVBXPCA5GM8AH9RQ5MJ3/tombstones and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/01HVTE261SHE47WJN66FKM6MEN/chunks/000001 b/services/monitoring/prometheus/prometheus_db/data/01HVTE261SHE47WJN66FKM6MEN/chunks/000001 deleted file mode 100644 index 4a8e7a3f05207aa8541d191d47b0ea4ca9056b89..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/01HVTE261SHE47WJN66FKM6MEN/chunks/000001 and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/01HVTE261SHE47WJN66FKM6MEN/index b/services/monitoring/prometheus/prometheus_db/data/01HVTE261SHE47WJN66FKM6MEN/index deleted file mode 100644 index 4d5a640cf495a058c837d34ff3321a8d31e9648d..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/01HVTE261SHE47WJN66FKM6MEN/index and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/01HVTE261SHE47WJN66FKM6MEN/meta.json b/services/monitoring/prometheus/prometheus_db/data/01HVTE261SHE47WJN66FKM6MEN/meta.json deleted file mode 100644 index 42a6b7809751245b7743413cb9965a21b6779d72..0000000000000000000000000000000000000000 --- a/services/monitoring/prometheus/prometheus_db/data/01HVTE261SHE47WJN66FKM6MEN/meta.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "ulid": "01HVTE261SHE47WJN66FKM6MEN", - "minTime": 1713494454205, - "maxTime": 1713499200000, - "stats": { - "numSamples": 20493, - "numSeries": 5339, - "numChunks": 5339 - }, - "compaction": { - "level": 1, - "sources": [ - "01HVTE261SHE47WJN66FKM6MEN" - ] - }, - "version": 1 -} \ No newline at end of file diff --git a/services/monitoring/prometheus/prometheus_db/data/01HVTE261SHE47WJN66FKM6MEN/tombstones b/services/monitoring/prometheus/prometheus_db/data/01HVTE261SHE47WJN66FKM6MEN/tombstones deleted file mode 100644 index 95fb83272e6f55edeee7e5d86bdec5fcd217eae0..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/01HVTE261SHE47WJN66FKM6MEN/tombstones and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/01HVTE269MJJWKFVJEQEY9F74T/chunks/000001 b/services/monitoring/prometheus/prometheus_db/data/01HVTE269MJJWKFVJEQEY9F74T/chunks/000001 deleted file mode 100644 index dda53c1d0000dc7fc1bc7e0487326cd61a48d68a..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/01HVTE269MJJWKFVJEQEY9F74T/chunks/000001 and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/01HVTE269MJJWKFVJEQEY9F74T/index b/services/monitoring/prometheus/prometheus_db/data/01HVTE269MJJWKFVJEQEY9F74T/index deleted file mode 100644 index 25612cd3bd86b2117442217faf43d1ade95d1e04..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/01HVTE269MJJWKFVJEQEY9F74T/index and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/01HVTE269MJJWKFVJEQEY9F74T/meta.json b/services/monitoring/prometheus/prometheus_db/data/01HVTE269MJJWKFVJEQEY9F74T/meta.json deleted file mode 100644 index fb9fd66257610b35de913dd511dfe15288ab7187..0000000000000000000000000000000000000000 --- a/services/monitoring/prometheus/prometheus_db/data/01HVTE269MJJWKFVJEQEY9F74T/meta.json +++ /dev/null @@ -1,36 +0,0 @@ -{ - "ulid": "01HVTE269MJJWKFVJEQEY9F74T", - "minTime": 1713466825347, - "maxTime": 1713484800000, - "stats": { - "numSamples": 71981, - "numSeries": 5472, - "numChunks": 16142 - }, - "compaction": { - "level": 2, - "sources": [ - "01HVSMKAKMCPJSN3P1AN2N6775", - "01HVSTBR4Q8XKAJN8X9M0V1ZF0", - "01HVSZ68RW5DAN1CZTZPJ188X5" - ], - "parents": [ - { - "ulid": "01HVSMKAKMCPJSN3P1AN2N6775", - "minTime": 1713466825347, - "maxTime": 1713470400000 - }, - { - "ulid": "01HVSTBR4Q8XKAJN8X9M0V1ZF0", - "minTime": 1713470425347, - "maxTime": 1713477600000 - }, - { - "ulid": "01HVSZ68RW5DAN1CZTZPJ188X5", - "minTime": 1713478673132, - "maxTime": 1713484800000 - } - ] - }, - "version": 1 -} \ No newline at end of file diff --git a/services/monitoring/prometheus/prometheus_db/data/01HVTE269MJJWKFVJEQEY9F74T/tombstones b/services/monitoring/prometheus/prometheus_db/data/01HVTE269MJJWKFVJEQEY9F74T/tombstones deleted file mode 100644 index 95fb83272e6f55edeee7e5d86bdec5fcd217eae0..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/01HVTE269MJJWKFVJEQEY9F74T/tombstones and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/chunks_head/000004 b/services/monitoring/prometheus/prometheus_db/data/chunks_head/000004 deleted file mode 100644 index f13c22baa8e3ec185345329a629645cc6ca07b7e..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/chunks_head/000004 and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/queries.active b/services/monitoring/prometheus/prometheus_db/data/queries.active deleted file mode 100644 index 8bfef0eabd49630443efda04a88fc8fb2b6b67bd..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/queries.active and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/wal/00000249 b/services/monitoring/prometheus/prometheus_db/data/wal/00000249 deleted file mode 100644 index 37797ce1badae2f08d16b0134abb5b8c17cb144f..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/wal/00000249 and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/wal/00000250 b/services/monitoring/prometheus/prometheus_db/data/wal/00000250 deleted file mode 100644 index 6974b1fdfe7fc6cfb933d64ce817020d82c8662e..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/wal/00000250 and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/wal/00000251 b/services/monitoring/prometheus/prometheus_db/data/wal/00000251 deleted file mode 100644 index cddf5dd82b7e4fcf972e137364d70dcb3884f4fa..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/wal/00000251 and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/wal/00000252 b/services/monitoring/prometheus/prometheus_db/data/wal/00000252 deleted file mode 100644 index 8fe8cace7f3674ac08fc367179a81ee1891ee6e8..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/wal/00000252 and /dev/null differ diff --git a/services/monitoring/prometheus/prometheus_db/data/wal/checkpoint.00000248/00000000 b/services/monitoring/prometheus/prometheus_db/data/wal/checkpoint.00000248/00000000 deleted file mode 100644 index bd5980715e545c437268b226f0ab272030301eff..0000000000000000000000000000000000000000 Binary files a/services/monitoring/prometheus/prometheus_db/data/wal/checkpoint.00000248/00000000 and /dev/null differ diff --git a/services/monitoring/tempo/tempo-data/blocks/single-tenant/1af0217d-4c51-45cc-8666-8d3905037270/bloom-0 b/services/monitoring/tempo/tempo-data/blocks/single-tenant/1af0217d-4c51-45cc-8666-8d3905037270/bloom-0 deleted file mode 100644 index 74f5867c9dac45c8d6f18e231aaf6f34bf26c75f..0000000000000000000000000000000000000000 Binary files a/services/monitoring/tempo/tempo-data/blocks/single-tenant/1af0217d-4c51-45cc-8666-8d3905037270/bloom-0 and /dev/null differ diff --git a/services/monitoring/tempo/tempo-data/blocks/single-tenant/1af0217d-4c51-45cc-8666-8d3905037270/data.parquet b/services/monitoring/tempo/tempo-data/blocks/single-tenant/1af0217d-4c51-45cc-8666-8d3905037270/data.parquet deleted file mode 100644 index 9c357d6719200a7ea2eb635df9c5d96d65e57977..0000000000000000000000000000000000000000 Binary files a/services/monitoring/tempo/tempo-data/blocks/single-tenant/1af0217d-4c51-45cc-8666-8d3905037270/data.parquet and /dev/null differ diff --git a/services/monitoring/tempo/tempo-data/blocks/single-tenant/1af0217d-4c51-45cc-8666-8d3905037270/index b/services/monitoring/tempo/tempo-data/blocks/single-tenant/1af0217d-4c51-45cc-8666-8d3905037270/index deleted file mode 100644 index 3f84243a59c09013f1c55d68dd8c708875c781ba..0000000000000000000000000000000000000000 --- a/services/monitoring/tempo/tempo-data/blocks/single-tenant/1af0217d-4c51-45cc-8666-8d3905037270/index +++ /dev/null @@ -1 +0,0 @@ -{"rowGroups":["/mzEdGWlxwxfAkAiAcO0lA=="]} \ No newline at end of file diff --git a/services/monitoring/tempo/tempo-data/blocks/single-tenant/1af0217d-4c51-45cc-8666-8d3905037270/meta.compacted.json b/services/monitoring/tempo/tempo-data/blocks/single-tenant/1af0217d-4c51-45cc-8666-8d3905037270/meta.compacted.json deleted file mode 100644 index 17f13d2105c478b544ab68f44d33d273f60a7e8e..0000000000000000000000000000000000000000 --- a/services/monitoring/tempo/tempo-data/blocks/single-tenant/1af0217d-4c51-45cc-8666-8d3905037270/meta.compacted.json +++ /dev/null @@ -1 +0,0 @@ -{"format":"vParquet3","blockID":"1af0217d-4c51-45cc-8666-8d3905037270","minID":"BUyRL6KsYdeKXOv3O/6oHw==","maxID":"/mzEdGWlxwxfAkAiAcO0lA==","tenantID":"single-tenant","startTime":"2024-04-18T15:13:03Z","endTime":"2024-04-18T15:19:11Z","totalObjects":42,"size":24160,"compactionLevel":1,"encoding":"none","indexPageSize":0,"totalRecords":1,"dataEncoding":"","bloomShards":1,"footerSize":11754} \ No newline at end of file diff --git a/services/monitoring/tempo/tempo-data/blocks/single-tenant/555c3df1-a215-4c31-8c48-67847ea0690c/bloom-0 b/services/monitoring/tempo/tempo-data/blocks/single-tenant/555c3df1-a215-4c31-8c48-67847ea0690c/bloom-0 deleted file mode 100644 index d0717dad6b0193ce19f69c70b02fce34b26f5c92..0000000000000000000000000000000000000000 Binary files a/services/monitoring/tempo/tempo-data/blocks/single-tenant/555c3df1-a215-4c31-8c48-67847ea0690c/bloom-0 and /dev/null differ diff --git a/services/monitoring/tempo/tempo-data/blocks/single-tenant/555c3df1-a215-4c31-8c48-67847ea0690c/data.parquet b/services/monitoring/tempo/tempo-data/blocks/single-tenant/555c3df1-a215-4c31-8c48-67847ea0690c/data.parquet deleted file mode 100644 index 12c980dbdf48675bd8d65eb24d7517806654fb47..0000000000000000000000000000000000000000 Binary files a/services/monitoring/tempo/tempo-data/blocks/single-tenant/555c3df1-a215-4c31-8c48-67847ea0690c/data.parquet and /dev/null differ diff --git a/services/monitoring/tempo/tempo-data/blocks/single-tenant/555c3df1-a215-4c31-8c48-67847ea0690c/index b/services/monitoring/tempo/tempo-data/blocks/single-tenant/555c3df1-a215-4c31-8c48-67847ea0690c/index deleted file mode 100644 index 3c629467f86857f46f78cba083f803a5bd8a8e57..0000000000000000000000000000000000000000 --- a/services/monitoring/tempo/tempo-data/blocks/single-tenant/555c3df1-a215-4c31-8c48-67847ea0690c/index +++ /dev/null @@ -1 +0,0 @@ -{"rowGroups":["56VgHse1LH0lc6AVUT+rdw=="]} \ No newline at end of file diff --git a/services/monitoring/tempo/tempo-data/blocks/single-tenant/555c3df1-a215-4c31-8c48-67847ea0690c/meta.compacted.json b/services/monitoring/tempo/tempo-data/blocks/single-tenant/555c3df1-a215-4c31-8c48-67847ea0690c/meta.compacted.json deleted file mode 100644 index 2fa72acdd17a766093406b4a7df5b16439881e72..0000000000000000000000000000000000000000 --- a/services/monitoring/tempo/tempo-data/blocks/single-tenant/555c3df1-a215-4c31-8c48-67847ea0690c/meta.compacted.json +++ /dev/null @@ -1 +0,0 @@ -{"format":"vParquet3","blockID":"555c3df1-a215-4c31-8c48-67847ea0690c","minID":"EsaWvRUC0PPk4KekLVmvsg==","maxID":"56VgHse1LH0lc6AVUT+rdw==","tenantID":"single-tenant","startTime":"2024-04-18T15:13:03Z","endTime":"2024-04-18T15:13:08Z","totalObjects":12,"size":20432,"compactionLevel":0,"encoding":"none","indexPageSize":0,"totalRecords":1,"dataEncoding":"","bloomShards":1,"footerSize":11618} \ No newline at end of file diff --git a/services/monitoring/tempo/tempo-data/blocks/single-tenant/5be550d3-0d77-41ea-a950-080fd772c13f/bloom-0 b/services/monitoring/tempo/tempo-data/blocks/single-tenant/5be550d3-0d77-41ea-a950-080fd772c13f/bloom-0 deleted file mode 100644 index 9bffb4effa62bf030769da9fc79988e97e2cb361..0000000000000000000000000000000000000000 Binary files a/services/monitoring/tempo/tempo-data/blocks/single-tenant/5be550d3-0d77-41ea-a950-080fd772c13f/bloom-0 and /dev/null differ diff --git a/services/monitoring/tempo/tempo-data/blocks/single-tenant/5be550d3-0d77-41ea-a950-080fd772c13f/data.parquet b/services/monitoring/tempo/tempo-data/blocks/single-tenant/5be550d3-0d77-41ea-a950-080fd772c13f/data.parquet deleted file mode 100644 index 8ebb4061c29a03b50e24fbc65e353df49e722abf..0000000000000000000000000000000000000000 Binary files a/services/monitoring/tempo/tempo-data/blocks/single-tenant/5be550d3-0d77-41ea-a950-080fd772c13f/data.parquet and /dev/null differ diff --git a/services/monitoring/tempo/tempo-data/blocks/single-tenant/5be550d3-0d77-41ea-a950-080fd772c13f/index b/services/monitoring/tempo/tempo-data/blocks/single-tenant/5be550d3-0d77-41ea-a950-080fd772c13f/index deleted file mode 100644 index 3f84243a59c09013f1c55d68dd8c708875c781ba..0000000000000000000000000000000000000000 --- a/services/monitoring/tempo/tempo-data/blocks/single-tenant/5be550d3-0d77-41ea-a950-080fd772c13f/index +++ /dev/null @@ -1 +0,0 @@ -{"rowGroups":["/mzEdGWlxwxfAkAiAcO0lA=="]} \ No newline at end of file diff --git a/services/monitoring/tempo/tempo-data/blocks/single-tenant/5be550d3-0d77-41ea-a950-080fd772c13f/meta.compacted.json b/services/monitoring/tempo/tempo-data/blocks/single-tenant/5be550d3-0d77-41ea-a950-080fd772c13f/meta.compacted.json deleted file mode 100644 index 6b25c49e8c3ff0ad79cdee6715a083484ce539a6..0000000000000000000000000000000000000000 --- a/services/monitoring/tempo/tempo-data/blocks/single-tenant/5be550d3-0d77-41ea-a950-080fd772c13f/meta.compacted.json +++ /dev/null @@ -1 +0,0 @@ -{"format":"vParquet3","blockID":"5be550d3-0d77-41ea-a950-080fd772c13f","minID":"BUyRL6KsYdeKXOv3O/6oHw==","maxID":"/mzEdGWlxwxfAkAiAcO0lA==","tenantID":"single-tenant","startTime":"2024-04-18T15:18:53Z","endTime":"2024-04-18T15:19:11Z","totalObjects":30,"size":22097,"compactionLevel":0,"encoding":"none","indexPageSize":0,"totalRecords":1,"dataEncoding":"","bloomShards":1,"footerSize":11704} \ No newline at end of file diff --git a/services/monitoring/tempo/tempo-data/blocks/single-tenant/64151eb3-1928-484a-b510-cec670a873e9/bloom-0 b/services/monitoring/tempo/tempo-data/blocks/single-tenant/64151eb3-1928-484a-b510-cec670a873e9/bloom-0 deleted file mode 100644 index 5ee9467db2663a95410c6c80fca73e5d09aee619..0000000000000000000000000000000000000000 Binary files a/services/monitoring/tempo/tempo-data/blocks/single-tenant/64151eb3-1928-484a-b510-cec670a873e9/bloom-0 and /dev/null differ diff --git a/services/monitoring/tempo/tempo-data/blocks/single-tenant/64151eb3-1928-484a-b510-cec670a873e9/data.parquet b/services/monitoring/tempo/tempo-data/blocks/single-tenant/64151eb3-1928-484a-b510-cec670a873e9/data.parquet deleted file mode 100644 index 10fd45a41e9ee75fb061bd6392fde58b4a4682ef..0000000000000000000000000000000000000000 Binary files a/services/monitoring/tempo/tempo-data/blocks/single-tenant/64151eb3-1928-484a-b510-cec670a873e9/data.parquet and /dev/null differ diff --git a/services/monitoring/tempo/tempo-data/blocks/single-tenant/64151eb3-1928-484a-b510-cec670a873e9/index b/services/monitoring/tempo/tempo-data/blocks/single-tenant/64151eb3-1928-484a-b510-cec670a873e9/index deleted file mode 100644 index 3ba2a72fe26e18ca079a448b9cb9f6204b9dade2..0000000000000000000000000000000000000000 --- a/services/monitoring/tempo/tempo-data/blocks/single-tenant/64151eb3-1928-484a-b510-cec670a873e9/index +++ /dev/null @@ -1 +0,0 @@ -{"rowGroups":["+sDcdjEBMHVWJKxkHdkyiQ=="]} \ No newline at end of file diff --git a/services/monitoring/tempo/tempo-data/blocks/single-tenant/64151eb3-1928-484a-b510-cec670a873e9/meta.compacted.json b/services/monitoring/tempo/tempo-data/blocks/single-tenant/64151eb3-1928-484a-b510-cec670a873e9/meta.compacted.json deleted file mode 100644 index ee0e984f93ae33f22d425f3596c04f6323d86242..0000000000000000000000000000000000000000 --- a/services/monitoring/tempo/tempo-data/blocks/single-tenant/64151eb3-1928-484a-b510-cec670a873e9/meta.compacted.json +++ /dev/null @@ -1 +0,0 @@ -{"format":"vParquet3","blockID":"64151eb3-1928-484a-b510-cec670a873e9","minID":"ApN785trkRliSAEQjQzIXQ==","maxID":"+sDcdjEBMHVWJKxkHdkyiQ==","tenantID":"single-tenant","startTime":"2024-02-06T09:02:01Z","endTime":"2024-02-06T09:02:23Z","totalObjects":34,"size":23588,"compactionLevel":0,"encoding":"none","indexPageSize":0,"totalRecords":1,"dataEncoding":"","bloomShards":1,"footerSize":11760} \ No newline at end of file diff --git a/services/monitoring/tempo/tempo-data/blocks/single-tenant/index.json.gz b/services/monitoring/tempo/tempo-data/blocks/single-tenant/index.json.gz deleted file mode 100644 index 2ec4a4185068b2d3a0eeef0657068f7c3d93d28c..0000000000000000000000000000000000000000 Binary files a/services/monitoring/tempo/tempo-data/blocks/single-tenant/index.json.gz and /dev/null differ diff --git a/services/monitoring/tempo/tempo-data/wal/780e2b0c-10c8-4c9e-84a5-a9befefc50ab+single-tenant+vParquet3/0000000001 b/services/monitoring/tempo/tempo-data/wal/780e2b0c-10c8-4c9e-84a5-a9befefc50ab+single-tenant+vParquet3/0000000001 deleted file mode 100644 index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0000000000000000000000000000000000000000 diff --git a/services/nginx/Dockerfile b/services/nginx/Dockerfile index e3f65827f5af498314941a4a5682ad150fbe3fda..c87732c5ba562af7dac31974b62bc560a47faef1 100644 --- a/services/nginx/Dockerfile +++ b/services/nginx/Dockerfile @@ -1,7 +1,7 @@ -FROM labs.etsi.org:5050/ocf/capif/nginx:base_1.23.1 +FROM labs.etsi.org:5050/ocf/capif/nginx:1.27.1 RUN apt-get update && apt-get install -y jq && apt-get clean RUN apt-get install -y openssl -RUN apt-get install -y curl=7.74.0-1.3+deb11u3 +RUN apt-get install -y curl RUN apt-get -y install redis diff --git a/services/register/Dockerfile b/services/register/Dockerfile index 03fb295e158be2bb1330c5c594e7c618783a5aea..bb03b219822ebcd8641e50013b0e6b84d72ece6e 100644 --- a/services/register/Dockerfile +++ b/services/register/Dockerfile @@ -1,13 +1,21 @@ -FROM labs.etsi.org:5050/ocf/capif/python:3-alpine +FROM labs.etsi.org:5050/ocf/capif/python:3-slim-bullseye RUN mkdir -p /usr/src/app WORKDIR /usr/src/app COPY requirements.txt /usr/src/app/requirements.txt -RUN apk add -U --no-cache gcc build-base linux-headers ca-certificates libffi-dev libressl-dev libxslt-dev +RUN apt-get update && apt-get install -y --no-install-recommends \ + gcc \ + build-essential \ + linux-headers-generic \ + ca-certificates \ + libffi-dev \ + libssl-dev \ + libxslt1-dev && \ + rm -rf /var/lib/apt/lists/* RUN pip3 install --no-cache-dir -r requirements.txt -RUN apk add openssl jq curl redis +RUN apt-get update && apt-get install -y --no-install-recommends openssl curl redis #ENV CAPIF_PRIV_KEY = $CAPIF_PRIV_KEY diff --git a/services/remove_users.sh b/services/remove_users.sh index 5325490e34af1577e937422ff7e88b16c523100e..7221981410fb101f4f5ec779142731d0b2d3db2a 100755 --- a/services/remove_users.sh +++ b/services/remove_users.sh @@ -1,5 +1,4 @@ #!/bin/bash -LOCAL=true # User to remove USERNAME_PREFIX= @@ -7,20 +6,16 @@ USERNAME_PREFIX= help() { echo "Usage: $1 " echo " -u : User prefix to use" - echo " -l : Local usage of script (default true)" echo " -h : show this help" exit 1 } # Read params -while getopts ":u:p:l:t:h" opt; do +while getopts ":u:h" opt; do case $opt in u) USERNAME_PREFIX="$OPTARG" ;; - l) - LOCAL=$OPTARG - ;; h) help ;; @@ -64,9 +59,16 @@ CAPIF_VAULT_PORT=8200 CAPIF_VAULT_TOKEN=read-ca-token # Mock Server -MOCK_SERVER_URL=http://mock-server:9090 +MOCK_SERVER_URL=http://mock-server:9100 NOTIFICATION_DESTINATION_URL=$MOCK_SERVER_URL +PLATFORM=$(uname -m) +if [ "x86_64" == "$PLATFORM" ]; then + DOCKER_ROBOT_IMAGE_VERSION=$DOCKER_ROBOT_IMAGE_VERSION-amd64 +else + DOCKER_ROBOT_IMAGE_VERSION=$DOCKER_ROBOT_IMAGE_VERSION-arm64 +fi + # Show variables echo "CAPIF_HOSTNAME = $CAPIF_HOSTNAME" echo "CAPIF_REGISTER = $CAPIF_REGISTER" @@ -80,6 +82,7 @@ echo "USERNAME_PREFIX=$USERNAME_PREFIX" echo "USER_PASSWORD=$USER_PASSWORD" echo "MOCK_SERVER_URL=$MOCK_SERVER_URL" echo "NOTIFICATION_DESTINATION_URL=$NOTIFICATION_DESTINATION_URL" +echo "DOCKER_ROBOT_IMAGE = $DOCKER_ROBOT_IMAGE:$DOCKER_ROBOT_IMAGE_VERSION" docker >/dev/null 2>/dev/null if [[ $? -ne 0 ]] @@ -106,41 +109,22 @@ fi mkdir -p $RESULT_FOLDER -if [[ "$LOCAL" == "true" ]] -then - docker run -ti --rm --network="host" \ - --add-host host.docker.internal:host-gateway \ - --add-host vault:host-gateway \ - --add-host register:host-gateway \ - --add-host mock-server:host-gateway \ - -v $TEST_FOLDER:/opt/robot-tests/tests \ - -v $RESULT_FOLDER:/opt/robot-tests/results ${DOCKER_ROBOT_IMAGE}:${DOCKER_ROBOT_IMAGE_VERSION} \ - --variable CAPIF_HOSTNAME:$CAPIF_HOSTNAME \ - --variable CAPIF_HTTP_PORT:$CAPIF_HTTP_PORT \ - --variable CAPIF_HTTPS_PORT:$CAPIF_HTTPS_PORT \ - --variable CAPIF_REGISTER:$CAPIF_REGISTER \ - --variable CAPIF_REGISTER_PORT:$CAPIF_REGISTER_PORT \ - --variable CAPIF_VAULT:$CAPIF_VAULT \ - --variable CAPIF_VAULT_PORT:$CAPIF_VAULT_PORT \ - --variable CAPIF_VAULT_TOKEN:$CAPIF_VAULT_TOKEN \ - --variable NOTIFICATION_DESTINATION_URL:$NOTIFICATION_DESTINATION_URL \ - --variable MOCK_SERVER_URL:$MOCK_SERVER_URL \ - --variable USERNAME_PREFIX:$USERNAME_PREFIX \ - --include remove-users -else - docker run -ti --rm --network="host" \ - -v $TEST_FOLDER:/opt/robot-tests/tests \ - -v $RESULT_FOLDER:/opt/robot-tests/results ${DOCKER_ROBOT_IMAGE}:${DOCKER_ROBOT_IMAGE_VERSION} \ - --variable CAPIF_HOSTNAME:$CAPIF_HOSTNAME \ - --variable CAPIF_HTTP_PORT:$CAPIF_HTTP_PORT \ - --variable CAPIF_HTTPS_PORT:$CAPIF_HTTPS_PORT \ - --variable CAPIF_REGISTER:$CAPIF_REGISTER \ - --variable CAPIF_REGISTER_PORT:$CAPIF_REGISTER_PORT \ - --variable CAPIF_VAULT:$CAPIF_VAULT \ - --variable CAPIF_VAULT_PORT:$CAPIF_VAULT_PORT \ - --variable CAPIF_VAULT_TOKEN:$CAPIF_VAULT_TOKEN \ - --variable NOTIFICATION_DESTINATION_URL:$NOTIFICATION_DESTINATION_URL \ - --variable MOCK_SERVER_URL:$MOCK_SERVER_URL \ - --variable USERNAME_PREFIX:$USERNAME_PREFIX \ - --include remove-users -fi \ No newline at end of file +docker run -ti --rm --network="host" \ + --add-host host.docker.internal:host-gateway \ + --add-host vault:host-gateway \ + --add-host register:host-gateway \ + --add-host mock-server:host-gateway \ + -v $TEST_FOLDER:/opt/robot-tests/tests \ + -v $RESULT_FOLDER:/opt/robot-tests/results ${DOCKER_ROBOT_IMAGE}:${DOCKER_ROBOT_IMAGE_VERSION} \ + --variable CAPIF_HOSTNAME:$CAPIF_HOSTNAME \ + --variable CAPIF_HTTP_PORT:$CAPIF_HTTP_PORT \ + --variable CAPIF_HTTPS_PORT:$CAPIF_HTTPS_PORT \ + --variable CAPIF_REGISTER:$CAPIF_REGISTER \ + --variable CAPIF_REGISTER_PORT:$CAPIF_REGISTER_PORT \ + --variable CAPIF_VAULT:$CAPIF_VAULT \ + --variable CAPIF_VAULT_PORT:$CAPIF_VAULT_PORT \ + --variable CAPIF_VAULT_TOKEN:$CAPIF_VAULT_TOKEN \ + --variable NOTIFICATION_DESTINATION_URL:$NOTIFICATION_DESTINATION_URL \ + --variable MOCK_SERVER_URL:$MOCK_SERVER_URL \ + --variable USERNAME_PREFIX:$USERNAME_PREFIX \ + --include remove-users diff --git a/services/run.sh b/services/run.sh index c77083ef8c3da9a18f5dbb473c9605f7b5004263..8a0094e6febdb0fa8ba3b3fbb8abfa959d3b4116 100755 --- a/services/run.sh +++ b/services/run.sh @@ -10,6 +10,7 @@ help() { echo " -s : Run Mock server" echo " -m : Run monitoring service" echo " -l : Set Log Level (default DEBUG). Select one of: [CRITICAL, FATAL, ERROR, WARNING, WARN, INFO, DEBUG, NOTSET]" + echo " -r : Remove cached information on build" echo " -h : show this help" exit 1 } @@ -18,6 +19,7 @@ HOSTNAME=capifcore MONITORING_STATE=false DEPLOY=all LOG_LEVEL=DEBUG +CACHED_INFO="" # Needed to avoid write permissions on bind volumes with prometheus and grafana DUID=$(id -u) @@ -25,7 +27,7 @@ DGID=$(id -g) # Mock Server configuration IP=0.0.0.0 -PORT=9090 +PORT=9100 # Get docker compose version docker_version=$(docker compose version --short | cut -d',' -f1) @@ -39,7 +41,7 @@ else fi # Read params -while getopts ":c:l:msh" opt; do +while getopts ":c:l:mshr" opt; do case $opt in c) HOSTNAME="$OPTARG" @@ -56,6 +58,9 @@ while getopts ":c:l:msh" opt; do l) LOG_LEVEL="$OPTARG" ;; + r) + CACHED_INFO="--no-cache" + ;; \?) echo "Not valid option: -$OPTARG" >&2 help @@ -72,8 +77,8 @@ echo Nginx hostname will be $HOSTNAME, deploy $DEPLOY, monitoring $MONITORING_ST if [ "$MONITORING_STATE" == "true" ] ; then echo '***Monitoring set as true***' echo '***Creating Monitoring stack***' + DUID=$DUID DGID=$DGID docker compose -f "$SERVICES_DIR/monitoring/docker-compose.yml" up --detach --build $CACHED_INFO - DUID=$DUID DGID=$DGID docker compose -f "$SERVICES_DIR/monitoring/docker-compose.yml" up --detach status=$? if [ $status -eq 0 ]; then echo "*** Monitoring Stack Runing ***" @@ -85,7 +90,7 @@ fi docker network create capif-network -docker compose -f "$SERVICES_DIR/docker-compose-vault.yml" up --detach --build +docker compose -f "$SERVICES_DIR/docker-compose-vault.yml" up --detach --build $CACHED_INFO status=$? if [ $status -eq 0 ]; then @@ -95,7 +100,7 @@ else exit $status fi -CAPIF_HOSTNAME=$HOSTNAME MONITORING=$MONITORING_STATE LOG_LEVEL=$LOG_LEVEL docker compose -f "$SERVICES_DIR/docker-compose-capif.yml" up --detach --build +CAPIF_HOSTNAME=$HOSTNAME MONITORING=$MONITORING_STATE LOG_LEVEL=$LOG_LEVEL docker compose -f "$SERVICES_DIR/docker-compose-capif.yml" up --detach --build $CACHED_INFO status=$? if [ $status -eq 0 ]; then @@ -105,9 +110,8 @@ else exit $status fi - CAPIF_PRIV_KEY_BASE_64=$(echo "$(cat nginx/certs/server.key)") -CAPIF_PRIV_KEY=$CAPIF_PRIV_KEY_BASE_64 LOG_LEVEL=$LOG_LEVEL docker compose -f "$SERVICES_DIR/docker-compose-register.yml" up --detach --build +CAPIF_PRIV_KEY=$CAPIF_PRIV_KEY_BASE_64 LOG_LEVEL=$LOG_LEVEL docker compose -f "$SERVICES_DIR/docker-compose-register.yml" up --detach --build $CACHED_INFO status=$? if [ $status -eq 0 ]; then @@ -121,7 +125,7 @@ if [ "$ROBOT_MOCK_SERVER" == "true" ] ; then echo '***Robot Mock Server set as true***' echo '***Creating Robot Mock Server stack***' - IP=$IP PORT=$PORT docker compose -f "$SERVICES_DIR/docker-compose-mock-server.yml" up --detach + IP=$IP PORT=$PORT docker compose -f "$SERVICES_DIR/docker-compose-mock-server.yml" up --detach --build $CACHED_INFO status=$? if [ $status -eq 0 ]; then echo "*** Monitoring Stack Runing ***" diff --git a/services/run_capif_tests.sh b/services/run_capif_tests.sh index b4a9e13bf7d8eba9eaa957d4cd1f51aed44d8fc6..3316f187466cd9967fbcb70d8f95f817e1ad4a58 100755 --- a/services/run_capif_tests.sh +++ b/services/run_capif_tests.sh @@ -21,9 +21,15 @@ CAPIF_VAULT_PORT=8200 CAPIF_VAULT_TOKEN=read-ca-token -MOCK_SERVER_URL=http://mock-server:9090 -NOTIFICATION_DESTINATION_URL=http://mock-server:9090 +MOCK_SERVER_URL=http://mock-server:9100 +NOTIFICATION_DESTINATION_URL=http://mock-server:9100 +PLATFORM=$(uname -m) +if [ "x86_64" == "$PLATFORM" ]; then + DOCKER_ROBOT_IMAGE_VERSION=$DOCKER_ROBOT_IMAGE_VERSION-amd64 +else + DOCKER_ROBOT_IMAGE_VERSION=$DOCKER_ROBOT_IMAGE_VERSION-arm64 +fi echo "CAPIF_HOSTNAME = $CAPIF_HOSTNAME" echo "CAPIF_REGISTER = $CAPIF_REGISTER" @@ -33,6 +39,7 @@ echo "CAPIF_VAULT = $CAPIF_VAULT" echo "CAPIF_VAULT_PORT = $CAPIF_VAULT_PORT" echo "CAPIF_VAULT_TOKEN = $CAPIF_VAULT_TOKEN" echo "MOCK_SERVER_URL = $MOCK_SERVER_URL" +echo "DOCKER_ROBOT_IMAGE = $DOCKER_ROBOT_IMAGE:$DOCKER_ROBOT_IMAGE_VERSION" INPUT_OPTIONS=$@ # Check if input is provided diff --git a/services/run_mock_server.sh b/services/run_mock_server.sh index f0ca4e3d79497699f4a6bba5e09d3c13eaaff2b3..c7393861a7b7e3e96cc10d2e80a5b7a196c5b767 100755 --- a/services/run_mock_server.sh +++ b/services/run_mock_server.sh @@ -7,13 +7,13 @@ export CAPIF_BASE_DIR=$(dirname "$SERVICES_DIR") help() { echo "Usage: $1 " echo " -i : Setup different host ip for mock server (default 0.0.0.0)" - echo " -p : Setup different port for mock server (default 9090)" + echo " -p : Setup different port for mock server (default 9100)" echo " -h : show this help" exit 1 } IP=0.0.0.0 -PORT=9090 +PORT=9100 # Read params while getopts ":i:p:h" opt; do diff --git a/services/show_logs.sh b/services/show_logs.sh index 747134e9598fe48b57ea9e55709d0fc041e296e1..7a4c807b20638893efa3089f1cc3cd3455067ce2 100755 --- a/services/show_logs.sh +++ b/services/show_logs.sh @@ -59,7 +59,7 @@ while getopts "cvrahmfs" opt; do ;; a) echo "Show all services" - FILES=("-f $SERVICES_DIR/docker-compose-capif.yml" -f "$SERVICES_DIR/docker-compose-vault.yml" -f "$SERVICES_DIR/docker-compose-register.yml" -f "$SERVICES_DIR/docker-compose-mock-server.yml" -f "$SERVICES_DIR./monitoring/docker-compose.yml") + FILES=("-f $SERVICES_DIR/docker-compose-capif.yml" -f "$SERVICES_DIR/docker-compose-vault.yml" -f "$SERVICES_DIR/docker-compose-register.yml" -f "$SERVICES_DIR/docker-compose-mock-server.yml" -f "$SERVICES_DIR/monitoring/docker-compose.yml") ;; f) echo "Setup follow logs" diff --git a/services/vault/Dockerfile b/services/vault/Dockerfile index 0eced912f088adee63778217b87ab3a7d1a846b1..ebf61f5dffc5cc0ae8f8178adac90d889c4b49d4 100644 --- a/services/vault/Dockerfile +++ b/services/vault/Dockerfile @@ -1,4 +1,4 @@ -FROM vault:1.13.2 +FROM labs.etsi.org:5050/ocf/capif/vault:1.13.2 # Instalar paquetes adicionales RUN apk add --no-cache jq openssl diff --git a/tests/features/CAPIF Api Events/capif_events_api.robot b/tests/features/CAPIF Api Events/capif_events_api.robot index 09f2189f881d76172fc89eb4d9fc77f6849a202d..ce014444b9573d9b3ebd7c1bc41adb607eda8075 100644 --- a/tests/features/CAPIF Api Events/capif_events_api.robot +++ b/tests/features/CAPIF Api Events/capif_events_api.robot @@ -19,7 +19,7 @@ ${SUBSCRIPTION_ID_NOT_VALID} not-valid *** Test Cases *** Creates a new individual CAPIF Event Subscription - [Tags] capif_api_events-1 + [Tags] capif_api_events-1 smoke # Default Invoker Registration and Onboarding ${register_user_info_invoker} ${url} ${request_body}= Invoker Default Onboarding