diff --git a/Dockerfile b/Dockerfile index d9d1ffb..66eaa2e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,7 @@ ARG APP_FOLDER=/home/build ARG MVN_REPO_FOLDER=/home/.m2 -FROM maven:3.8.7-amazoncorretto-8 AS build +FROM maven:3.8.7-amazoncorretto-8@sha256:ec86ad98267c73eae1b7fb1bd0142723e4c9f05cc52f3466a548ce6f6f471e26 AS build ARG APP_FOLDER ARG MVN_REPO_FOLDER COPY . ${APP_FOLDER} @@ -9,7 +9,7 @@ RUN mkdir ${MVN_REPO_FOLDER} WORKDIR ${MVN_REPO_FOLDER} RUN --mount=type=cache,target=/root/.m2 mvn -f ${APP_FOLDER}/pom.xml -s ${APP_FOLDER}/settings.xml clean package -FROM openjdk:8-jdk-alpine +FROM openjdk:8-jdk-alpine@sha256:94792824df2df33402f201713f932b58cb9de94a0cd524164a0f2283343547b3 ARG APP_FOLDER RUN addgroup -S spring && adduser -S spring -G spring USER spring:spring diff --git a/docker-compose.yaml b/docker-compose.yaml index 8af4f36..89462e3 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -3,7 +3,7 @@ name: bs-banking-services services: zookeeper: - image: confluentinc/cp-zookeeper:latest + image: confluentinc/cp-zookeeper:latest@sha256:5ca5f3269814804ebf88e4da80f9bdc73df1f70ec66b4b8ed0344159e8d342ec hostname: zookeeper container_name: zookeeper healthcheck: @@ -18,7 +18,7 @@ services: - "2181:2181" kafka: - image: confluentinc/cp-kafka:latest + image: confluentinc/cp-kafka:latest@sha256:adc392d28a1e99e8c9a1ec7f087e9e91041837b35b8b7cc8b8a691b82dd581b0 container_name: kafka hostname: kafka healthcheck: @@ -41,7 +41,7 @@ services: condition: service_healthy kafka-init: - image: confluentinc/cp-kafka:latest + image: confluentinc/cp-kafka:latest@sha256:adc392d28a1e99e8c9a1ec7f087e9e91041837b35b8b7cc8b8a691b82dd581b0 container_name: kafka-init entrypoint: [ '/bin/sh', '-c' ] command: | @@ -63,7 +63,7 @@ services: init: true hazelcast: - image: hazelcast/hazelcast:4.2.6 + image: hazelcast/hazelcast:4.2.6@sha256:df067a11e4a9892379cc064ac5ad110cad4cffc8b7f367fb6ebca6a5d0909ddf container_name: hazelcast restart: unless-stopped environment: @@ -73,14 +73,14 @@ services: - 5702:5702 aws-mock: - image: motoserver/moto:latest + image: motoserver/moto:latest@sha256:68042b17e9a55c7a32347f802b7a02f2793201b4f1c788ca0e85084f5218c233 container_name: aws-mock restart: unless-stopped ports: - 5000:5000 oracle: - image: gvenzl/oracle-xe:21-slim-faststart + image: gvenzl/oracle-xe:21-slim-faststart@sha256:f82bccdf6020d27373fdf0e93046b63eb3f777a0289e329d9839feebaf4555de container_name: oracle restart: unless-stopped environment: