Skip to content

Commit

Permalink
Merge pull request #77 from jason-fox/patch-5
Browse files Browse the repository at this point in the history
Ensure wget and node are present
  • Loading branch information
fgalan authored Apr 6, 2020
2 parents b326368 + 8f0be3b commit 003f596
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,11 @@ MAINTAINER FIWARE IoTAgent Team. Telefónica I+D
#
# COPY . /opt/iotasigfox/
#
RUN if [ "${DOWNLOAD}" = "latest" ] ; \
RUN apt-get update && \
# Ensure that unzip, wget and curl are installed
apt-get install -y --no-install-recommends unzip ca-certificates curl wget && \
# Now download the sources from GitHub
if [ "${DOWNLOAD}" = "latest" ] ; \
then \
RELEASE="${SOURCE_BRANCH}"; \
echo "INFO: Building Latest Development from ${SOURCE_BRANCH} branch."; \
Expand All @@ -70,17 +74,15 @@ RUN if [ "${DOWNLOAD}" = "latest" ] ; \
echo "INFO: Building Release: ${RELEASE}"; \
fi && \
RELEASE_CONCAT=$(echo "${RELEASE}" | tr / -); \
# Ensure that unzip is installed, and download the sources
apt-get update && \
apt-get install -y --no-install-recommends unzip && \
wget --no-check-certificate -O source.zip https://github.com/"${GITHUB_ACCOUNT}"/"${GITHUB_REPOSITORY}"/archive/"${RELEASE}".zip && \
unzip source.zip && \
rm source.zip && \
mv "${GITHUB_REPOSITORY}-${RELEASE_CONCAT}" /opt/iotasigfox && \
# Remove unzip and clean apt cache
apt-get clean && \
apt-get remove -y unzip && \
apt-get -y autoremove
apt-get -y autoremove && \
rm -rf /var/lib/apt/lists/*

WORKDIR /opt/iotasigfox

Expand Down

0 comments on commit 003f596

Please sign in to comment.