-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile.builder
More file actions
30 lines (22 loc) · 907 Bytes
/
Copy pathDockerfile.builder
File metadata and controls
30 lines (22 loc) · 907 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
FROM ubuntu:22.04
ARG DEBIAN_FRONTEND=noninteractive
ARG PIO_ENV=pico
ENV PIO_ENV=${PIO_ENV}
ENV ROS_DISTRO=humble
RUN apt-get update && apt-get install -y --no-install-recommends \
git curl ca-certificates \
python3 python3-venv python3-full \
build-essential cmake \
&& rm -rf /var/lib/apt/lists/*
# PlatformIO installer -> creates ~/.platformio/penv (needed by micro_ros_platformio)
RUN curl -fsSL -o /tmp/get-platformio.py \
https://raw.githubusercontent.com/platformio/platformio-core-installer/master/get-platformio.py \
&& python3 /tmp/get-platformio.py \
&& rm -f /tmp/get-platformio.py
ENV PATH="/root/.platformio/penv/bin:${PATH}"
WORKDIR /work/linorobot2_hardware
COPY . .
WORKDIR /work/linorobot2_hardware/firmware
RUN pio run -t clean_microros -e ${PIO_ENV} && \
pio run -e ${PIO_ENV}
CMD ["bash", "-lc", "pio run -e ${PIO_ENV} && ls -lah .pio/build/${PIO_ENV}"]