Skip to content

Commit

Permalink
docker build error fix attempt
Browse files Browse the repository at this point in the history
  • Loading branch information
woensug-choi committed Jun 5, 2024
1 parent 57433bf commit 6436522
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 5 deletions.
14 changes: 11 additions & 3 deletions .docker/jazzy.amd64.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,21 @@ ARG BRANCH="ros2"
# hadolint ignore=DL3008
RUN apt-get update \
apt-get install -y --no-install-recommends \
sudo tzdata build-essential gfortran automake \
sudo build-essential gfortran automake \
bison flex libtool git wget locales \
software-properties-common nano && \
rm -rf /var/lib/apt/lists/

# Locale for UTF-8
RUN truncate -s0 /tmp/preseed.cfg && \
(echo "tzdata tzdata/Areas select Etc" >> /tmp/preseed.cfg) && \
(echo "tzdata tzdata/Zones/Etc select UTC" >> /tmp/preseed.cfg) && \
debconf-set-selections /tmp/preseed.cfg && \
rm -f /etc/timezone && \
dpkg-reconfigure -f noninteractive tzdata
# hadolint ignore=DL3008
RUN apt-get -y install --no-install-recommends locales tzdata \
&& rm -rf /tmp/*
RUN locale-gen en_US en_US.UTF-8 && update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \
export LANG=en_US.UTF-8

Expand All @@ -27,8 +36,7 @@ RUN bash install.sh
# Make user (assume host user has 1000:1000 permission)
ARG USER=dave
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
RUN addgroup --gid 1000 $USER && \
adduser --uid 1000 --ingroup $USER --shell /bin/bash --disabled-password --gecos '' $USER \
RUN adduser --shell /bin/bash --disabled-password --gecos '' $USER \
&& echo "$USER:$USER" | chpasswd && adduser $USER sudo \
&& echo '%sudo ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers
# Set User as user
Expand Down
13 changes: 11 additions & 2 deletions .docker/jazzy.arm64v8.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -67,12 +67,21 @@ ENV DEBCONF_NONINTERACTIVE_SEEN=true
# hadolint ignore=DL3008
RUN apt-get update \
apt-get install -y --no-install-recommends \
sudo tzdata build-essential gfortran automake \
bison flex libtool git wget locales \
sudo build-essential gfortran automake \
bison flex libtool git wget \
software-properties-common nano && \
rm -rf /var/lib/apt/lists/

# Locale for UTF-8
RUN truncate -s0 /tmp/preseed.cfg && \
(echo "tzdata tzdata/Areas select Etc" >> /tmp/preseed.cfg) && \
(echo "tzdata tzdata/Zones/Etc select UTC" >> /tmp/preseed.cfg) && \
debconf-set-selections /tmp/preseed.cfg && \
rm -f /etc/timezone && \
dpkg-reconfigure -f noninteractive tzdata
# hadolint ignore=DL3008
RUN apt-get -y install --no-install-recommends locales tzdata \
&& rm -rf /tmp/*
RUN locale-gen en_US en_US.UTF-8 && update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \
export LANG=en_US.UTF-8

Expand Down

0 comments on commit 6436522

Please sign in to comment.