2019-07-17 12:19:38 -07:00
|
|
|
FROM christroutner/ct-base-ubuntu
|
|
|
|
|
MAINTAINER Chris Troutner <chris.troutner@gmail.com>
|
|
|
|
|
|
|
|
|
|
RUN apt-get update -y
|
|
|
|
|
|
|
|
|
|
#Set the working directory to be the home directory
|
|
|
|
|
WORKDIR /home/safeuser
|
|
|
|
|
|
|
|
|
|
# Switch to user account.
|
|
|
|
|
USER safeuser
|
|
|
|
|
# Prep 'sudo' commands.
|
|
|
|
|
#RUN echo 'abcd8765' | sudo -S pwd
|
|
|
|
|
|
|
|
|
|
# Clone the repository
|
|
|
|
|
WORKDIR /home/safeuser
|
2020-08-07 15:39:56 -07:00
|
|
|
RUN git clone https://github.com/Permissionless-Software-Foundation/bch-api
|
2019-07-17 12:19:38 -07:00
|
|
|
WORKDIR /home/safeuser/bch-api
|
2020-08-07 15:39:56 -07:00
|
|
|
RUN git checkout free
|
2020-08-08 10:27:34 -07:00
|
|
|
RUN npm install --silent
|
2019-07-17 12:19:38 -07:00
|
|
|
|
|
|
|
|
# Generate documentation
|
|
|
|
|
RUN npm run docs
|
|
|
|
|
|
2020-08-07 16:27:49 -07:00
|
|
|
EXPOSE 4000
|
2019-07-17 12:19:38 -07:00
|
|
|
|
|
|
|
|
COPY start-local-testnet.sh start-local-testnet.sh
|
|
|
|
|
CMD ["./start-local-testnet.sh"]
|