File tree Expand file tree Collapse file tree 1 file changed +23
-6
lines changed Expand file tree Collapse file tree 1 file changed +23
-6
lines changed Original file line number Diff line number Diff line change 11FROM debian:bullseye-slim
22
3- RUN adduser --disabled-password --gecos "" --no-create-home --uid 1000 cronos
3+ # Create user & directories
4+ RUN adduser --disabled-password --gecos "" --no-create-home --uid 1000 cronos \
5+ && mkdir -p /home/cronos/data /home/cronos/config /home/cronos/bin
46
5- RUN mkdir -p /home/cronos/data && mkdir -p /home/cronos/config
6- RUN apt-get update -y && apt-get install wget curl procps net-tools jq lz4 -y
7- RUN cd /tmp && wget --no-check-certificate https://github.com/crypto-org-chain/cronos/releases/download/v1.5.0/cronos_1.5.0-testnet_Linux_x86_64.tar.gz && tar -xvf cronos_1.5.0-testnet_Linux_x86_64.tar.gz \
8- && rm cronos_1.5.0-testnet_Linux_x86_64.tar.gz && mv ./* /home/cronos/
7+ # Install dependencies
8+ RUN apt-get update -y && apt-get install -y wget curl procps net-tools jq lz4
9+
10+ WORKDIR /tmp
11+
12+ # Download and verify tarball
13+ RUN wget https://github.com/crypto-org-chain/cronos/releases/download/v1.5.0/cronos_1.5.0-testnet_Linux_x86_64.tar.gz \
14+ && echo "d917ca990ed2415905a44ec48d6047664dad06b3441cd09b116f86f1880b1c2b cronos_1.5.0-testnet_Linux_x86_64.tar.gz" | sha256sum -c -
15+
16+ # Extract and move binary
17+ RUN tar -xzf cronos_1.5.0-testnet_Linux_x86_64.tar.gz \
18+ && mv bin/cronosd /home/cronos/bin/cronosd \
19+ && rm -rf cronos_1.5.0-testnet_Linux_x86_64 cronos_1.5.0-testnet_Linux_x86_64.tar.gz
20+
21+ # Validate binary hash
22+ RUN sha256sum /home/cronos/bin/cronosd
23+
24+ # Set permissions
925RUN chown -R cronos:cronos /home/cronos && chmod 1777 /tmp
1026
11- USER root
27+ USER cronos
28+ WORKDIR /home/cronos
1229
1330ENTRYPOINT ["/home/cronos/bin/cronosd" ]
You can’t perform that action at this time.
0 commit comments