commit chages to docker file in which we are directly accessing and running the dev files

This commit is contained in:
Kumar Sahaj 2023-09-06 18:18:47 +00:00
parent 79fc0c67af
commit c348055ee5

View File

@ -1,45 +1,26 @@
# Use a base Ubuntu image
# Use a base image
FROM ubuntu:20.04
# Set environment variables to avoid interaction during installation
ENV DEBIAN_FRONTEND=noninteractive
# Install required packages
# Install necessary packages
RUN apt-get update && \
apt-get install -y \
git \
build-essential \
cmake \
libtool \
autoconf \
automake \
pkg-config \
libssl-dev \
libsqlite3-dev \
libboost-all-dev \
libcurl4-openssl-dev \
golang \
npm \
curl
apt-get install -y wget && \
apt-get install -y gnupg2 && \
apt-get install -y software-properties-common
# Clone the blockbook repository
RUN git clone https://github.com/ranchimall/blockbook /opt/blockbook
# Download the pre-built files from GitHub releases
RUN wget https://github.com/ranchimall/blockbook/releases/download/v0.4.0/blockbook-flo_0.4.0_amd64.deb && \
wget https://github.com/ranchimall/blockbook/releases/download/v0.15.1.1/backend-flo_0.15.1.1-satoshilabs-1_amd64.deb
# Build the blockbook files
WORKDIR /opt/blockbook
RUN make deb-flo
# Install the downloaded packages
RUN apt install -y ./backend-flo_0.15.1.1-satoshilabs-1_amd64.deb && \
apt install -y ./blockbook-flo_0.4.0_amd64.deb
# Install the backend and blockbook services
RUN apt-get install -y ./blockbook-flo*.deb && \
apt-get install -y ./backend-flo*.deb
# Clean up downloaded packages
RUN rm -f ./backend-flo_0.15.1.1-satoshilabs-1_amd64.deb && \
rm -f ./blockbook-flo_0.4.0_amd64.deb
# Start the backend service
RUN systemctl start backend-flo.service
# Expose the blockbook port
# Expose the port for the Blockbook web interface
EXPOSE 9166
# Start the blockbook service
CMD ["systemctl", "start", "blockbook-flo.service"]
# Start the Blockbook service
CMD ["/usr/local/bin/blockbook", "--config", "/etc/blockbook/blockbook-flo.cfg"]