Overwriting config files
Ryan Schmidt
ryandesign at macports.org
Fri Aug 17 01:54:55 PDT 2007
On Aug 17, 2007, at 02:47, Anders F Björklund wrote:
> Ryan Schmidt wrote:
>
>> Brian Matzon wrote:
>>
>>> I have had some issues lately with upgrades overwriting config
>>> files (postfix, apache2).
>>> Should I create a ticket for these issues, or is this being fixed
>>> in this ticket:
>>> I noticed this ticket: http://trac.macports.org/projects/macports/
>>> ticket/2365
>>
>> That ticket is 3 years old and is for general MacPorts
>> functionality to support non-volatile default config files. Since
>> it's so old, I doubt anything is being done with it at the moment.
>> I'm also not convinced any functionality needs to be added to
>> MacPorts base to support this.
>
> The ticket mentions the need to have install/uninstall scripts
> (i.e. not do it in activate/deactivate since that only works with
> images), and that functionality is needed in order for the *.sample
> approach to be useful. It's another old ticket, though: http://
> trac.macports.org/projects/macports/ticket/1068
I don't see how #1068 is related to Brian's request. Don't see why
install/uninstall scripts are necessary for anything.
> For the configuration files, it would be a great benefit to the
> packaging targets if there was a way to specify which ones are
> conffiles. Probably something like "destroot.conffiles", similar to
> the existing "destroot.keepdirs". This would signify that the files
> in question are *not* to be overwritten...
Don't see why that's necessary. I think we're doing just fine with
individual portfiles installing their sample conf files with *.sample
or *.default names.
> So all these Tickets are related (#777 is another one), and the
> implementation of these missing features should be taken to the
> macports-dev list. So to me, it seems that at least two new pieces
> of functionality are needed to be added to the MacPorts base in
> order to support this ?
#777 seems to be a "nice to have" rather than a requirement:
http://trac.macports.org/projects/macports/ticket/777
"If a port installs a foo.cf.sample it might want to copy
foo.cf.sample to foo.cf iff foo.cf doesn't exist. This is probably
common enough that the port author shouldn't be forced to write an on-
install foo.cf.sample [ ! -f foo.cf ] && cp foo.cf.sample foo.cf"
I don't understand what functionality requested by Brian cannot be
met by MacPorts 1.5.2 as it is today.
More information about the macports-users
mailing list