apt not respecting Ignore-Files-Silently directive

Asked by Todd Taft

I have a configuration management system that stores a backup copy of files that it updates with a suffix based upon the date that the file is updated (.YYYY-MM-DD)

In Ubuntu 20.04, I have added a file 00ignore to the /etc/apt/apt.conf directory.

The contents of the file are one line:
Dir::Ignore-Files-Silently:: "\.[12][0-9][0-9][0-9]-[01][0-9]-[0-3][0-9]$";

The system appears to read the file, but doesn't seem to process it, as apt and related programs still spit out warnings.

# apt-config dump |grep Ignore
Dir::Ignore-Files-Silently "";
Dir::Ignore-Files-Silently:: "~$";
Dir::Ignore-Files-Silently:: "\.disabled$";
Dir::Ignore-Files-Silently:: "\.bak$";
Dir::Ignore-Files-Silently:: "\.dpkg-[a-z]+$";
Dir::Ignore-Files-Silently:: "\.ucf-[a-z]+$";
Dir::Ignore-Files-Silently:: "\.save$";
Dir::Ignore-Files-Silently:: "\.orig$";
Dir::Ignore-Files-Silently:: "\.distUpgrade$";
Dir::Ignore-Files-Silently:: "\.[12][0-9][0-9][0-9]-[01][0-9]-[0-3][0-9]$";
N: Ignoring file '99unclet-override.2021-06-15' in directory '/etc/apt/apt.conf.d/' as it has an invalid filename extension
N: Ignoring file '00unclet.2021-06-18' in directory '/etc/apt/apt.conf.d/' as it has an invalid filename extension

Note: aptitude does not display this warning, although many other apt-related programs do (e.g. apt, apt-get, apt-config).

Question information

Language:
English Edit question
Status:
Expired
For:
Ubuntu apt Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
actionparsnip (andrew-woodhead666) said :
#1

Wouldn't it be neater to have a subdirectory for these files and making apt ignore the new folder entirely... Would this not be easier?

Revision history for this message
Todd Taft (taft) said :
#2

That would require re-writing a significant component of my configuration management system just to deal with one application (apt), so, no, it's not particularly easy.

Revision history for this message
actionparsnip (andrew-woodhead666) said :
#3

Ah I see

Revision history for this message
Launchpad Janitor (janitor) said :
#4

This question was expired because it remained in the 'Open' state without activity for the last 15 days.