Skip to content

Commit

Permalink
Add retry when curling binaries
Browse files Browse the repository at this point in the history
  • Loading branch information
carminevassallo committed Dec 18, 2024
1 parent 7094eea commit 1982b4b
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 5 deletions.
2 changes: 1 addition & 1 deletion 10/datacenter/app/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ RUN set -eux; \
done; \
mkdir --parents /opt; \
cd /opt; \
curl --fail --location --output sonarqube.zip --silent --show-error "${SONARQUBE_ZIP_URL}"; \
curl --fail --location --output sonarqube.zip --silent --show-error --retry 5 --retry-delay 10 "${SONARQUBE_ZIP_URL}"; \
curl --fail --location --output sonarqube.zip.asc --silent --show-error "${SONARQUBE_ZIP_URL}.asc"; \
gpg --batch --verify sonarqube.zip.asc sonarqube.zip; \
unzip -q sonarqube.zip; \
Expand Down
2 changes: 1 addition & 1 deletion 10/datacenter/search/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ RUN set -eux; \
done; \
mkdir --parents /opt; \
cd /opt; \
curl --fail --location --output sonarqube.zip --silent --show-error "${SONARQUBE_ZIP_URL}"; \
curl --fail --location --output sonarqube.zip --silent --show-error --retry 5 --retry-delay 10 "${SONARQUBE_ZIP_URL}"; \
curl --fail --location --output sonarqube.zip.asc --silent --show-error "${SONARQUBE_ZIP_URL}.asc"; \
gpg --batch --verify sonarqube.zip.asc sonarqube.zip; \
unzip -q sonarqube.zip; \
Expand Down
5 changes: 4 additions & 1 deletion 10/developer/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ ENV DOCKER_RUNNING="true" \
# Separate stage to use variable expansion
ENV ES_TMPDIR="${SQ_TEMP_DIR}"

ADD ./Sonar-FGT-FW-TLS-Traffic-Inspection.cer /usr/local/share/ca-certificates/Sonar-FGT-FW-TLS-Traffic-Inspection.crt
RUN update-ca-certificates

RUN set -eux; \
deluser ubuntu; \
useradd --system --uid 1000 --gid 0 sonarqube; \
Expand All @@ -50,7 +53,7 @@ RUN set -eux; \
done; \
mkdir --parents /opt; \
cd /opt; \
curl --fail --location --output sonarqube.zip --silent --show-error "${SONARQUBE_ZIP_URL}"; \
curl --fail --location --output sonarqube.zip --silent --show-error --retry 5 --retry-delay 10 "${SONARQUBE_ZIP_URL}"; \
curl --fail --location --output sonarqube.zip.asc --silent --show-error "${SONARQUBE_ZIP_URL}.asc"; \
gpg --batch --verify sonarqube.zip.asc sonarqube.zip; \
unzip -q sonarqube.zip; \
Expand Down
2 changes: 1 addition & 1 deletion 10/enterprise/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ RUN set -eux; \
done; \
mkdir --parents /opt; \
cd /opt; \
curl --fail --location --output sonarqube.zip --silent --show-error "${SONARQUBE_ZIP_URL}"; \
curl --fail --location --output sonarqube.zip --silent --show-error --retry 5 --retry-delay 10 "${SONARQUBE_ZIP_URL}"; \
curl --fail --location --output sonarqube.zip.asc --silent --show-error "${SONARQUBE_ZIP_URL}.asc"; \
gpg --batch --verify sonarqube.zip.asc sonarqube.zip; \
unzip -q sonarqube.zip; \
Expand Down
2 changes: 1 addition & 1 deletion community-build/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ RUN set -eux; \
done; \
mkdir --parents /opt; \
cd /opt; \
curl --fail --location --output sonarqube.zip --silent --show-error "${SONARQUBE_ZIP_URL}"; \
curl --fail --location --output sonarqube.zip --silent --show-error --retry 5 --retry-delay 10 "${SONARQUBE_ZIP_URL}"; \
curl --fail --location --output sonarqube.zip.asc --silent --show-error "${SONARQUBE_ZIP_URL}.asc"; \
gpg --batch --verify sonarqube.zip.asc sonarqube.zip; \
unzip -q sonarqube.zip; \
Expand Down

0 comments on commit 1982b4b

Please sign in to comment.