Skip to content

Commit

Permalink
install SQLite 3.46.1 in the dockerfile (#2489)
Browse files Browse the repository at this point in the history
* install SQLite 3.46.1 in the dockerfile

* install SQLite 3.46.1 in the dockerfile both main and debug
  • Loading branch information
yourmoonlight committed Aug 22, 2024
1 parent fa74e1c commit 55786ff
Show file tree
Hide file tree
Showing 2 changed files with 63 additions and 11 deletions.
38 changes: 32 additions & 6 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,27 @@ RUN set -eux; \
g++ \
cmake \
make \
libsqlite3-dev \
libprotobuf-dev \
protobuf-compiler; \
protobuf-compiler \
build-essential \
libreadline-dev; \
rm -rf /var/lib/apt/lists/*

# Install SQLite 3.46.1 with multi-threading enabled
RUN set -eux; \
wget https://www.sqlite.org/2024/sqlite-autoconf-3460100.tar.gz; \
tar xvf sqlite-autoconf-3460100.tar.gz; \
cd sqlite-autoconf-3460100; \
CFLAGS="-DSQLITE_THREADSAFE=2" ./configure --prefix=/usr/local; \
make; \
make install; \
cd ..; \
rm -rf sqlite-autoconf-3460100 sqlite-autoconf-3460100.tar.gz; \
ldconfig

ENV RUSTUP_HOME=/usr/local/rustup \
CARGO_HOME=/usr/local/cargo \
PATH=/usr/local/cargo/bin:$PATH \
PATH=/usr/local/cargo/bin:/usr/local/bin:$PATH \
RUSTUP_VERSION=1.26.0 \
RUSTUP_SHA256=0b2f6c8f85a3d02fde2efc0ced4657869d73fccfce59defb4e8d29233116e6db \
RUST_ARCH=x86_64-unknown-linux-gnu
Expand Down Expand Up @@ -58,11 +71,24 @@ RUN set -eux; \
apt-get update; \
apt-get install -y --no-install-recommends \
ca-certificates \
libsqlite3-dev \
wget \
libssl-dev; \
libssl-dev \
build-essential \
libreadline-dev; \
rm -rf /var/lib/apt/lists/*

# Install SQLite 3.46.1 with multi-threading enabled
RUN set -eux; \
wget https://www.sqlite.org/2024/sqlite-autoconf-3460100.tar.gz; \
tar xvf sqlite-autoconf-3460100.tar.gz; \
cd sqlite-autoconf-3460100; \
CFLAGS="-DSQLITE_THREADSAFE=2" ./configure --prefix=/usr/local; \
make; \
make install; \
cd ..; \
rm -rf sqlite-autoconf-3460100 sqlite-autoconf-3460100.tar.gz; \
ldconfig

RUN set -eux; \
wget "http://nz2.archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2.23_amd64.deb"; \
DEBIAN_FRONTEND=noninteractive dpkg -i libssl1.1_1.1.1f-1ubuntu2.23_amd64.deb;
Expand All @@ -74,4 +100,4 @@ COPY --from=builder $RELEASE_PATH/rooch-faucet \
/rooch-faucet/

ENTRYPOINT [ "/rooch/rooch" ]
CMD [ "server", "start" ]
CMD [ "server", "start" ]
36 changes: 31 additions & 5 deletions docker/DockerfileDebug
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,24 @@ RUN set -eux; \
g++ \
cmake \
make \
libsqlite3-dev \
libprotobuf-dev \
protobuf-compiler; \
protobuf-compiler \
build-essential \
libreadline-dev; \
rm -rf /var/lib/apt/lists/*

# Install SQLite 3.46.1 with multi-threading enabled
RUN set -eux; \
wget https://www.sqlite.org/2024/sqlite-autoconf-3460100.tar.gz; \
tar xvf sqlite-autoconf-3460100.tar.gz; \
cd sqlite-autoconf-3460100; \
CFLAGS="-DSQLITE_THREADSAFE=2" ./configure --prefix=/usr/local; \
make; \
make install; \
cd ..; \
rm -rf sqlite-autoconf-3460100 sqlite-autoconf-3460100.tar.gz; \
ldconfig

ENV RUSTUP_HOME=/usr/local/rustup \
CARGO_HOME=/usr/local/cargo \
PATH=/usr/local/cargo/bin:$PATH \
Expand Down Expand Up @@ -58,11 +71,24 @@ RUN set -eux; \
apt-get update; \
apt-get install -y --no-install-recommends \
ca-certificates \
libsqlite3-dev \
wget \
libssl-dev; \
libssl-dev \
build-essential \
libreadline-dev; \
rm -rf /var/lib/apt/lists/*

# Install SQLite 3.46.1 with multi-threading enabled
RUN set -eux; \
wget https://www.sqlite.org/2024/sqlite-autoconf-3460100.tar.gz; \
tar xvf sqlite-autoconf-3460100.tar.gz; \
cd sqlite-autoconf-3460100; \
CFLAGS="-DSQLITE_THREADSAFE=2" ./configure --prefix=/usr/local; \
make; \
make install; \
cd ..; \
rm -rf sqlite-autoconf-3460100 sqlite-autoconf-3460100.tar.gz; \
ldconfig

RUN set -eux; \
wget "http://nz2.archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2.23_amd64.deb"; \
DEBIAN_FRONTEND=noninteractive dpkg -i libssl1.1_1.1.1f-1ubuntu2.23_amd64.deb;
Expand All @@ -74,4 +100,4 @@ COPY --from=builder $RELEASE_PATH/rooch-faucet \
/rooch-faucet/

ENTRYPOINT [ "/rooch/rooch" ]
CMD [ "server", "start" ]
CMD [ "server", "start" ]

0 comments on commit 55786ff

Please sign in to comment.