Removed environment variables from dockerfile
This commit is contained in:
29
Dockerfile
29
Dockerfile
@@ -9,43 +9,32 @@ MAINTAINER jacobgadikian@gmail.com
|
|||||||
# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=863199
|
# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=863199
|
||||||
RUN apt-get update && \
|
RUN apt-get update && \
|
||||||
apt-get upgrade -y && \
|
apt-get upgrade -y && \
|
||||||
mkdir -p /usr/share/man/man1 && \
|
|
||||||
apt-get install -y \
|
apt-get install -y \
|
||||||
curl \
|
curl \
|
||||||
git \
|
git \
|
||||||
sudo \
|
sudo
|
||||||
tar \
|
|
||||||
apt-utils
|
# Stopping docker keyboard-config from disrupting ubuntu-req.sh
|
||||||
|
RUN sudo DEBIAN_FRONTEND=noninteractive apt-get install -y keyboard-configuration && \
|
||||||
|
sudo DEBIAN_FRONTEND=noninteractive apt-get install -y console-setup
|
||||||
|
|
||||||
RUN groupadd --gid 3434 riscvuser \
|
RUN groupadd --gid 3434 riscvuser \
|
||||||
&& useradd --uid 3434 --gid riscvuser --shell /bin/bash --create-home riscvuser \
|
&& useradd --uid 3434 --gid riscvuser --shell /bin/bash --create-home riscvuser \
|
||||||
&& echo 'riscvuser ALL=NOPASSWD: ALL' >> /etc/sudoers.d/50-riscvuser \
|
&& echo 'riscvuser ALL=NOPASSWD: ALL' >> /etc/sudoers.d/50-riscvuser \
|
||||||
&& echo 'Defaults env_keep += "DEBIAN_FRONTEND"' >> /etc/sudoers.d/env_keep
|
&& echo 'Defaults env_keep += "DEBIAN_FRONTEND"' >> /etc/sudoers.d/env_keep
|
||||||
|
|
||||||
# Add HOME environment variable
|
WORKDIR /home/riscvuser
|
||||||
ENV HOME="/home/riscvuser"
|
|
||||||
|
|
||||||
# Update PATH for RISCV toolchain (note: hardcoded for CircleCI)
|
|
||||||
ENV RISCV="$HOME/riscv-tools-install"
|
|
||||||
ENV LD_LIBRARY_PATH="$RISCV/lib"
|
|
||||||
ENV PATH="$RISCV/bin:$PATH"
|
|
||||||
|
|
||||||
WORKDIR $HOME
|
|
||||||
USER riscvuser
|
USER riscvuser
|
||||||
|
|
||||||
# Install Chipyard
|
# Install Chipyard
|
||||||
RUN git clone https://github.com/ucb-bar/chipyard.git && \
|
RUN git clone https://github.com/ucb-bar/chipyard.git && \
|
||||||
cd chipyard && \
|
cd chipyard && \
|
||||||
export MAKEFLAGS=-"j $(nproc)" && \
|
./scripts/ubuntu-req.sh 1>/dev/null
|
||||||
./scripts/init-submodules-no-riscv-tools.sh 1>/dev/null
|
|
||||||
|
|
||||||
# Stopping docker keyboard-config from disrupting ubuntu-req.sh
|
|
||||||
RUN sudo DEBIAN_FRONTEND=noninteractive apt-get install -y keyboard-configuration && \
|
|
||||||
sudo DEBIAN_FRONTEND=noninteractive apt-get install -y console-setup
|
|
||||||
|
|
||||||
# Install dependencies from ubuntu-req.sh
|
# Install dependencies from ubuntu-req.sh
|
||||||
RUN cd chipyard && \
|
RUN cd chipyard && \
|
||||||
./scripts/ubuntu-req.sh 1>/dev/null
|
export MAKEFLAGS=-"j $(nproc)" && \
|
||||||
|
./scripts/init-submodules-no-riscv-tools.sh 1>/dev/null
|
||||||
|
|
||||||
# Install riscv-tools
|
# Install riscv-tools
|
||||||
RUN cd chipyard && \
|
RUN cd chipyard && \
|
||||||
|
|||||||
Reference in New Issue
Block a user