Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ansible,docker: install Python 3.9 in Stretch RPi's #2606

Merged
merged 3 commits into from
Apr 19, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
15 changes: 13 additions & 2 deletions ansible/roles/jenkins-worker/templates/rpi_stretch.Dockerfile.j2
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM resin/rpi-raspbian:stretch
FROM balenalib/rpi-raspbian:stretch

ENV LC_ALL=C \
USER={{ server_user }} \
Expand Down Expand Up @@ -26,7 +26,9 @@ RUN apt-get update && apt-get dist-upgrade -y && apt-get install -y \
openssh-client \
gzip \
xz-utils \
curl && \
curl \
libffi-dev \
zlib1g-dev && \
apt-get clean -y && \
rm -rf /var/lib/apt/lists/*

Expand All @@ -36,6 +38,15 @@ RUN update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-6 50 && \
update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-6 50 && \
update-alternatives --install /usr/bin/cc cc /usr/bin/gcc-6 50

RUN mkdir /python && \
cd /python && \
curl https://github.com/python/cpython/archive/refs/tags/v3.9.4.tar.gz -L --output v3.9.4.tar.gz && \
tar xf v3.9.4.tar.gz && \
cd cpython-3.9.4 && \
./configure && \
make install && \
rm -rf /python

RUN addgroup \
--gid {{ server_user_gid.stdout_lines[0] }} \
{{ server_user }} && \
Expand Down
2 changes: 0 additions & 2 deletions ansible/roles/jenkins-worker/vars/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -121,11 +121,9 @@ raspberry_pi: {
{ name: 'jessie', template: 'rpi_jessie.Dockerfile.j2' }
],
armv7l: [
{ name: 'jessie', template: 'rpi_jessie.Dockerfile.j2' },
{ name: 'stretch', template: 'rpi_stretch.Dockerfile.j2' }
],
arm64: [
{ name: 'jessie', template: 'rpi_jessie.Dockerfile.j2' },
{ name: 'stretch', template: 'rpi_stretch.Dockerfile.j2' }
]
}
Expand Down