Browse Source

apt: Remove /var/lib/apt/lists before update

When divingbell-apt is managing the apt sources list, remove the
contents of /var/lib/apt/lists before running apt-get update.

Change-Id: I379af0b1a887bc81bc76f57289f35bae64e146c6
changes/25/780425/1
Phil Sphicas 6 months ago
parent
commit
d657f7968c
  1. 1
      divingbell/templates/bin/_apt.sh.tpl

1
divingbell/templates/bin/_apt.sh.tpl

@ -85,6 +85,7 @@ rm -rf /etc/apt/sources.list.d/*
mv /etc/apt/trusted.gpg.d/divingbell_temp.gpg /etc/apt/trusted.gpg.d/divingbell.gpg
rm -f /etc/apt/trusted.gpg
find /etc/apt/trusted.gpg.d/ -type f ! -name 'divingbell.gpg' -exec rm {{ "{}" }} \;
rm -rf /var/lib/apt/lists/*
DEBIAN_FRONTEND=noninteractive apt-get update
{{- end }}
{{- if hasKey .Values.conf.apt "packages" }}

Loading…
Cancel
Save