forked from openhab/openhabian
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Enhanced and more verbose testing in Travis (openhab#859)
* ZRAM tests to work if on ARM but lxc * cond_echo cmd in tryUntil() * restrict container to 1G for RPi3 * dont allow for failure of BATS tests * add warning 64bit on aarch64 is NOT supposed to work; check if OH downgrades to 32bit * reduce to a single shellcheck run (else builds succeed when there's no error in the last run) * increased verbosity on test cases Signed-off-by: Markus Storm <[email protected]>
- Loading branch information
Showing
11 changed files
with
306 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
# RPi1, RPi0W (ARMv6hf arch) | ||
FROM balenalib/raspberry-pi-debian-node:latest-buster | ||
|
||
|
||
ENV container docker | ||
ENV INITSYSTEM on | ||
ENV APT_KEY_DONT_WARN_ON_DANGEROUS_USAGE=DontWarn | ||
|
||
RUN apt-get update -qq \ | ||
&& apt-get install -y -qq --no-install-recommends systemd systemd-sysv git wget python python-pip python3 python3-pip apt-utils jq virt-what \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
RUN git clone https://github.com/bats-core/bats-core.git && \ | ||
cd bats-core && \ | ||
./install.sh /usr/local | ||
|
||
# We never want these to run in a container | ||
# Feel free to edit the list but this is the one we used | ||
RUN systemctl mask \ | ||
dev-hugepages.mount \ | ||
sys-fs-fuse-connections.mount \ | ||
sys-kernel-config.mount \ | ||
display-manager.service \ | ||
[email protected] \ | ||
systemd-logind.service \ | ||
systemd-remount-fs.service \ | ||
getty.target \ | ||
graphical.target | ||
|
||
WORKDIR / | ||
COPY docker-tests/entry.sh /usr/bin/entry.sh | ||
COPY docker-tests/resin.service /etc/systemd/system/resin.service | ||
|
||
RUN systemctl enable /etc/systemd/system/resin.service | ||
|
||
RUN git clone https://github.com/gdraheim/docker-systemctl-replacement | ||
RUN cp docker-systemctl-replacement/files/docker/systemctl.py /bin/systemctl | ||
|
||
ENTRYPOINT ["/usr/bin/entry.sh"] | ||
|
||
RUN adduser openhabian --gecos "Openhabian,,," --disabled-password | ||
RUN echo "openhabian:openhabian" | chpasswd | ||
RUN /bin/echo -n "Running on " && /usr/bin/arch | ||
|
||
COPY . /opt/openhabian/ | ||
COPY build-image/openhabian.conf /etc/openhabian.conf | ||
|
||
WORKDIR /opt/openhabian/ | ||
COPY docker-tests/start.sh ./ | ||
|
||
VOLUME ["/sys/fs/cgroup"] | ||
STOPSIGNAL 37 | ||
|
||
CMD ["bash", "start.sh"] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
# Note RPi3 base (first RPi to have aarch64 available) WITH 64bit OS | ||
#FROM balenalib/raspberrypi3-debian-node:latest-buster | ||
#FROM balenalib/generic-aarch64-debian-node | ||
FROM balenalib/raspberrypi4-64-debian-node | ||
|
||
|
||
ENV container docker | ||
ENV INITSYSTEM on | ||
ENV APT_KEY_DONT_WARN_ON_DANGEROUS_USAGE=DontWarn | ||
|
||
RUN apt-get update -qq \ | ||
&& apt-get install -y -qq --no-install-recommends systemd systemd-sysv git wget python python-pip python3 python3-pip apt-utils jq virt-what \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
RUN git clone https://github.com/bats-core/bats-core.git && \ | ||
cd bats-core && \ | ||
./install.sh /usr/local | ||
|
||
# We never want these to run in a container | ||
# Feel free to edit the list but this is the one we used | ||
RUN systemctl mask \ | ||
dev-hugepages.mount \ | ||
sys-fs-fuse-connections.mount \ | ||
sys-kernel-config.mount \ | ||
display-manager.service \ | ||
[email protected] \ | ||
systemd-logind.service \ | ||
systemd-remount-fs.service \ | ||
getty.target \ | ||
graphical.target | ||
|
||
WORKDIR / | ||
COPY docker-tests/entry.sh /usr/bin/entry.sh | ||
COPY docker-tests/resin.service /etc/systemd/system/resin.service | ||
|
||
RUN systemctl enable /etc/systemd/system/resin.service | ||
|
||
RUN git clone https://github.com/gdraheim/docker-systemctl-replacement | ||
RUN cp docker-systemctl-replacement/files/docker/systemctl.py /bin/systemctl | ||
|
||
ENTRYPOINT ["/usr/bin/entry.sh"] | ||
|
||
RUN adduser openhabian --gecos "Openhabian,,," --disabled-password | ||
RUN echo "openhabian:openhabian" | chpasswd | ||
RUN /bin/echo -n "Running on " && /usr/bin/arch | ||
|
||
COPY . /opt/openhabian/ | ||
COPY build-image/openhabian.conf /etc/openhabian.conf | ||
|
||
WORKDIR /opt/openhabian/ | ||
COPY docker-tests/start.sh ./ | ||
|
||
VOLUME ["/sys/fs/cgroup"] | ||
STOPSIGNAL 37 | ||
|
||
CMD ["bash", "start.sh"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
# CM3 is like RPi3 but without BT,WiFi,Ethernet | ||
# ATTENTION: Zulu Java on raspberrypi3 images fails to run | ||
FROM balenalib/fincm3-debian-node:latest-buster | ||
|
||
|
||
ENV container docker | ||
ENV INITSYSTEM on | ||
ENV APT_KEY_DONT_WARN_ON_DANGEROUS_USAGE=DontWarn | ||
|
||
RUN apt-get update -qq \ | ||
&& apt-get install -y -qq --no-install-recommends systemd systemd-sysv git wget python python-pip python3 python3-pip apt-utils jq virt-what \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
RUN git clone https://github.com/bats-core/bats-core.git && \ | ||
cd bats-core && \ | ||
./install.sh /usr/local | ||
|
||
# We never want these to run in a container | ||
# Feel free to edit the list but this is the one we used | ||
RUN systemctl mask \ | ||
dev-hugepages.mount \ | ||
sys-fs-fuse-connections.mount \ | ||
sys-kernel-config.mount \ | ||
display-manager.service \ | ||
[email protected] \ | ||
systemd-logind.service \ | ||
systemd-remount-fs.service \ | ||
getty.target \ | ||
graphical.target | ||
|
||
WORKDIR / | ||
COPY docker-tests/entry.sh /usr/bin/entry.sh | ||
COPY docker-tests/resin.service /etc/systemd/system/resin.service | ||
|
||
RUN systemctl enable /etc/systemd/system/resin.service | ||
|
||
RUN git clone https://github.com/gdraheim/docker-systemctl-replacement | ||
RUN cp docker-systemctl-replacement/files/docker/systemctl.py /bin/systemctl | ||
|
||
ENTRYPOINT ["/usr/bin/entry.sh"] | ||
|
||
RUN adduser openhabian --gecos "Openhabian,,," --disabled-password | ||
RUN echo "openhabian:openhabian" | chpasswd | ||
RUN /bin/echo -n "Running on " && /usr/bin/arch | ||
|
||
COPY . /opt/openhabian/ | ||
COPY build-image/openhabian.conf /etc/openhabian.conf | ||
|
||
WORKDIR /opt/openhabian/ | ||
COPY docker-tests/start.sh ./ | ||
|
||
VOLUME ["/sys/fs/cgroup"] | ||
STOPSIGNAL 37 | ||
|
||
CMD ["bash", "start.sh"] |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
# assumes at least ARMv71 but not ARMv8 (aarch64) yet | ||
FROM balenalib/raspberry-pi2-debian-node:latest-buster | ||
|
||
ENV container docker | ||
ENV INITSYSTEM on | ||
ENV APT_KEY_DONT_WARN_ON_DANGEROUS_USAGE=DontWarn | ||
|
||
RUN apt-get update -qq \ | ||
&& apt-get install -y -qq --no-install-recommends systemd systemd-sysv git wget python python-pip python3 python3-pip apt-utils jq virt-what \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
RUN git clone https://github.com/bats-core/bats-core.git && \ | ||
cd bats-core && \ | ||
./install.sh /usr/local | ||
|
||
# We never want these to run in a container | ||
# Feel free to edit the list but this is the one we used | ||
RUN systemctl mask \ | ||
dev-hugepages.mount \ | ||
sys-fs-fuse-connections.mount \ | ||
sys-kernel-config.mount \ | ||
display-manager.service \ | ||
[email protected] \ | ||
systemd-logind.service \ | ||
systemd-remount-fs.service \ | ||
getty.target \ | ||
graphical.target | ||
|
||
WORKDIR / | ||
COPY docker-tests/entry.sh /usr/bin/entry.sh | ||
COPY docker-tests/resin.service /etc/systemd/system/resin.service | ||
|
||
RUN systemctl enable /etc/systemd/system/resin.service | ||
|
||
RUN git clone https://github.com/gdraheim/docker-systemctl-replacement | ||
RUN cp docker-systemctl-replacement/files/docker/systemctl.py /bin/systemctl | ||
|
||
ENTRYPOINT ["/usr/bin/entry.sh"] | ||
|
||
RUN adduser openhabian --gecos "Openhabian,,," --disabled-password | ||
RUN echo "openhabian:openhabian" | chpasswd | ||
RUN /bin/echo -n "Running on " && /usr/bin/arch | ||
|
||
COPY . /opt/openhabian/ | ||
COPY build-image/openhabian.conf /etc/openhabian.conf | ||
|
||
WORKDIR /opt/openhabian/ | ||
COPY docker-tests/start.sh ./ | ||
|
||
VOLUME ["/sys/fs/cgroup"] | ||
STOPSIGNAL 37 | ||
|
||
CMD ["bash", "start.sh"] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.