Files
ansible-adguardhome/molecule/default/Dockerfile.j2
Jim Myhrberg 8ed2be2b5a feat: Add support for installing latest version
This works by looking up the latest GitHub release, and using the git
tag of that release as the version.
2020-01-11 23:42:39 +00:00

38 lines
1.2 KiB
Django/Jinja

# Molecule managed
{% if item.registry is defined %}
FROM {{ item.registry.url }}/{{ item.image }}
{% else %}
FROM {{ item.image }}
{% endif %}
RUN if [ $(command -v apt-get) ]; then \
apt-get update && \
apt-get install -y python python-pip sudo bash ca-certificates \
net-tools && \
apt-get clean; \
elif [ $(command -v dnf) ]; then \
dnf makecache && \
dnf --assumeyes install \
sudo python3 python3-pip *python-devel python*-dnf bash \
net-tools && \
dnf clean all; \
elif [ $(command -v yum) ]; then \
yum makecache fast && \
yum install -y python3 python3-pip sudo yum-plugin-ovl bash \
net-tools && \
sed -i 's/plugins=0/plugins=1/g' /etc/yum.conf && \
yum clean all; \
elif [ $(command -v zypper) ]; then \
zypper refresh && \
zypper install -y python sudo bash python-xml && \
zypper clean -a; \
elif [ $(command -v apk) ]; then \
apk update && \
apk add --no-cache python sudo bash ca-certificates; \
elif [ $(command -v xbps-install) ]; then \
xbps-install -Syu && \
xbps-install -y python sudo bash ca-certificates && \
xbps-remove -O; \
fi