-
Notifications
You must be signed in to change notification settings - Fork 2
feat: Cronos mainnet image bump v1.4.11 #84
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,30 +1,19 @@ | ||
| FROM debian:bullseye-slim | ||
|
|
||
| # Create user & directories | ||
| RUN adduser --disabled-password --gecos "" --no-create-home --uid 1000 cronos \ | ||
| && mkdir -p /home/cronos/data /home/cronos/config /home/cronos/bin | ||
| RUN adduser --disabled-password --gecos "" --no-create-home --uid 1000 cronos | ||
| RUN mkdir -p /home/cronos/data && mkdir -p /home/cronos/config | ||
|
|
||
| # Install dependencies | ||
| RUN apt-get update -y && apt-get install -y wget curl procps net-tools jq lz4 | ||
|
|
||
| WORKDIR /tmp | ||
| RUN apt-get update -y && apt-get install wget curl procps net-tools jq lz4 -y | ||
|
|
||
| # Download and verify tarball | ||
| RUN wget https://github.com/crypto-org-chain/cronos/releases/download/v1.5.0/cronos_1.5.0-testnet_Linux_x86_64.tar.gz \ | ||
| && echo "d917ca990ed2415905a44ec48d6047664dad06b3441cd09b116f86f1880b1c2b cronos_1.5.0-testnet_Linux_x86_64.tar.gz" | sha256sum -c - | ||
|
|
||
| # Extract and move binary | ||
| RUN tar -xzf cronos_1.5.0-testnet_Linux_x86_64.tar.gz \ | ||
| && mv bin/cronosd /home/cronos/bin/cronosd \ | ||
| && rm -rf cronos_1.5.0-testnet_Linux_x86_64 cronos_1.5.0-testnet_Linux_x86_64.tar.gz | ||
|
|
||
| # Validate binary hash | ||
| RUN sha256sum /home/cronos/bin/cronosd | ||
| RUN cd /tmp && wget --no-check-certificate https://github.com/crypto-org-chain/cronos/releases/download/v1.4.11/cronos_1.4.11_Linux_x86_64.tar.gz && tar -xvf cronos_1.4.11_Linux_x86_64.tar.gz \ | ||
| && rm cronos_1.4.11_Linux_x86_64.tar.gz && mv ./* /home/cronos/ | ||
|
|
||
| # Set permissions | ||
| RUN chown -R cronos:cronos /home/cronos && chmod 1777 /tmp | ||
|
|
||
| USER cronos | ||
| WORKDIR /home/cronos | ||
| USER root | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Revert to the non-root runtime user. Switching the container back to 🤖 Prompt for AI Agents |
||
|
|
||
| ENTRYPOINT ["/home/cronos/bin/cronosd"] | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reinstate TLS and checksum verification for the Cronos tarball.
wget --no-check-certificatedisables TLS validation and the checksum verification step has been dropped, so we now pipe an unauthenticated binary straight into the image. This is a critical supply-chain regression relative to the previous Dockerfile. Please restore CA verification and the SHA256 (or stronger) digest check before we can ship.🧰 Tools
🪛 Checkov (3.2.334)
[high] 11-12: Ensure that certificate validation isn't disabled with wget
(CKV2_DOCKER_3)
🤖 Prompt for AI Agents