From 8c330c52c336f5b5d921c0da13278bc171e5b8a7 Mon Sep 17 00:00:00 2001 From: aptalca Date: Tue, 29 Jun 2021 11:37:56 -0400 Subject: [PATCH] standardize apt-get, update formatting --- root/etc/cont-init.d/95-apt-get | 5 +++++ root/etc/cont-init.d/95-tshoot-config | 25 ++++++++++++------------- 2 files changed, 17 insertions(+), 13 deletions(-) create mode 100644 root/etc/cont-init.d/95-apt-get diff --git a/root/etc/cont-init.d/95-apt-get b/root/etc/cont-init.d/95-apt-get new file mode 100644 index 0000000..4797eca --- /dev/null +++ b/root/etc/cont-init.d/95-apt-get @@ -0,0 +1,5 @@ +#!/usr/bin/with-contenv bash + +if [ -f /usr/bin/apt ]; then + apt-get update +fi \ No newline at end of file diff --git a/root/etc/cont-init.d/95-tshoot-config b/root/etc/cont-init.d/95-tshoot-config index 64ca25b..db9afcd 100644 --- a/root/etc/cont-init.d/95-tshoot-config +++ b/root/etc/cont-init.d/95-tshoot-config @@ -1,17 +1,16 @@ #!/usr/bin/with-contenv bash - ## Ubuntu - if [ -f /usr/bin/apt ]; then - apt-get update +## Ubuntu +if [ -f /usr/bin/apt ]; then apt-get install --no-install-recommends -y \ - dnsutils \ - net-tools \ - iputils-ping \ - traceroute - fi - # Alpine - if [ -f /sbin/apk ]; then + dnsutils \ + net-tools \ + iputils-ping \ + traceroute +fi +# Alpine +if [ -f /sbin/apk ]; then apk add --no-cache \ - bind-tools \ - net-tools - fi + bind-tools \ + net-tools +fi