Skip to content

Commit 3da1c76

Browse files
author
Justin Boswell
authored
ARM Raspbian/Alpine/AL2 Images and package installation/CLI fixes (#9)
* Added more knowledge of package managers * Fixed argument parsing FOR REAL THIS TIME * Added sanity test for both ways of running an action * Massive clean up of docker image stuff * Use make -j 3 on arm builds * Fixed sudo installs on manylinux * Always build images the same way * Switched all builds to using downloaded binaries for libcrypto * Use pre-compiled cmake binaries from S3 on manylinux * Added a short wait to retries * Fixed case where projects were not always re-resolved, resulting in a loss of path info * Added raspbian support/detection
1 parent 8e33def commit 3da1c76

File tree

39 files changed

+702
-955
lines changed

39 files changed

+702
-955
lines changed

.github/actions/buildx-with-cache/.dockerignore

Lines changed: 0 additions & 2 deletions
This file was deleted.

.github/actions/buildx-with-cache/Dockerfile

Lines changed: 0 additions & 8 deletions
This file was deleted.

.github/actions/buildx-with-cache/README.md

Lines changed: 0 additions & 1 deletion
This file was deleted.

.github/actions/buildx-with-cache/action.yml

Lines changed: 0 additions & 47 deletions
This file was deleted.

.github/actions/buildx-with-cache/entrypoint.sh

Lines changed: 0 additions & 126 deletions
This file was deleted.
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
FROM arm64v8/amazonlinux:latest
2+
3+
4+
###############################################################################
5+
# Install prereqs
6+
###############################################################################
7+
RUN yum -y update \
8+
&& yum -y install \
9+
tar \
10+
git \
11+
curl \
12+
sudo \
13+
# Python
14+
python3 \
15+
python3-devel \
16+
python3-pip \
17+
make \
18+
cmake3 \
19+
gcc \
20+
gcc-c++ \
21+
&& yum clean all \
22+
&& rm -rf /var/cache/yum \
23+
&& ln -s /usr/bin/cmake3 /usr/bin/cmake \
24+
&& ln -s /usr/bin/ctest3 /usr/bin/ctest \
25+
&& cmake --version \
26+
&& ctest --version
27+
28+
###############################################################################
29+
# Python/AWS CLI
30+
###############################################################################
31+
RUN python3 -m pip install --upgrade pip setuptools virtualenv \
32+
&& python3 -m pip install --upgrade awscli \
33+
&& aws --version
34+
35+
###############################################################################
36+
# Install pre-built OpenSSL
37+
###############################################################################
38+
ADD https://d19elf31gohf1l.cloudfront.net/_binaries/libcrypto/libcrypto-1.1.1-al2-arm64.tar.gz /opt/openssl
39+
40+
###############################################################################
41+
# Install builder package
42+
###############################################################################
43+
ADD builder /usr/local/bin/builder.pyz
44+
ADD entrypoint.sh /usr/local/bin/builder
45+
RUN chmod a+x /usr/local/bin/builder.pyz /usr/local/bin/builder
46+
ENTRYPOINT ["/usr/local/bin/builder"]
Lines changed: 11 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
FROM amazonlinux:latest
22

3-
SHELL ["/bin/bash", "-c"]
43

54
###############################################################################
65
# Install prereqs
76
###############################################################################
8-
RUN yum -y update
9-
10-
RUN yum -y install \
7+
RUN yum -y update \
8+
&& yum -y install \
9+
tar \
1110
git \
1211
curl \
1312
sudo \
@@ -19,6 +18,8 @@ RUN yum -y install \
1918
cmake3 \
2019
gcc \
2120
gcc-c++ \
21+
&& yum clean all \
22+
&& rm -rf /var/cache/yum \
2223
&& ln -s /usr/bin/cmake3 /usr/bin/cmake \
2324
&& ln -s /usr/bin/ctest3 /usr/bin/ctest \
2425
&& cmake --version \
@@ -32,34 +33,14 @@ RUN python3 -m pip install --upgrade pip setuptools virtualenv \
3233
&& aws --version
3334

3435
###############################################################################
35-
# OpenSSL
36-
###############################################################################
37-
RUN ([ -d /opt/openssl ] && rm -rf /opt/openssl) || true \
38-
&& mkdir -p /tmp/build \
39-
&& cd /tmp/build \
40-
&& git clone https://github.com/openssl/openssl.git \
41-
&& pushd openssl \
42-
&& git checkout OpenSSL_1_1_1-stable \
43-
&& ./config -fPIC \
44-
no-md2 no-rc5 no-rfc3779 no-sctp no-ssl-trace no-zlib no-hw no-mdc2 \
45-
no-seed no-idea no-camellia no-bf no-dsa no-ssl3 no-capieng \
46-
no-unit-test no-tests \
47-
-DSSL_FORBID_ENULL -DOPENSSL_NO_DTLS1 -DOPENSSL_NO_HEARTBEATS \
48-
--prefix=/opt/openssl --openssldir=/opt/openssl \
49-
&& make -j \
50-
&& make install_sw \
51-
&& LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/openssl/lib /opt/openssl/bin/openssl version
52-
53-
###############################################################################
54-
# Cleanup
36+
# Install pre-built OpenSSL
5537
###############################################################################
56-
RUN yum clean all \
57-
&& rm -rf /var/cache/yum \
58-
&& rm -rf /tmp/*
38+
ADD https://d19elf31gohf1l.cloudfront.net/_binaries/libcrypto/libcrypto-1.1.1-al2-x64.tar.gz /opt/openssl
5939

6040
###############################################################################
6141
# Install builder package
6242
###############################################################################
63-
ADD builder /usr/local/bin/builder
64-
COPY entrypoint.sh /entrypoint.sh
65-
ENTRYPOINT ["/entrypoint.sh"]
43+
ADD builder /usr/local/bin/builder.pyz
44+
ADD entrypoint.sh /usr/local/bin/builder
45+
RUN chmod a+x /usr/local/bin/builder.pyz /usr/local/bin/builder
46+
ENTRYPOINT ["/usr/local/bin/builder"]

.github/docker-images/alpine-arm64/Dockerfile

Lines changed: 0 additions & 62 deletions
This file was deleted.

0 commit comments

Comments
 (0)