[
https://issues.apache.org/jira/browse/TS-624?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13004279#comment-13004279
]
Eric Connell commented on TS-624:
---------------------------------
I have a fix for this... although it isn't the most elegant thing in the world.
Automake doesn't support this behavior and most packages that want something
like this tend to make their default config with a ".default" or ".example"
tagged on the end.
The problem with trafficserver is that there are a lot of config files which
makes the initial renaming of everything tedious. To fix this I've modified
all of the files that get installed in $(sysconfdir) with a ".default"
extension tagged on it and then wrote an install-exec-hook in the Makefile.am
that checks to see if the actual config file name for each "default" file
exists or not. If it doesn't exist, it copies over the default file to a new
file without the ".default" extension. If the config file already exists, it
leaves it alone.
Because we're renaming a lot of files, it's hard to write just a patch for
this. To begin with, you'll need to run the following commands in a bash shell:
{code}
cd proxy/config
for f in *.config ; do mv $f $f.default; done
mv stats.config.xml stats.config.xml.default
mv plugin.db plugin.db.default
mv mgr.cnf mgr.cnf.default
{code}
Then patch configure.ac and proxy/config/Makefile.am with the attached patch.
Run autoreconf to regenerate Makefile.in and it should be ready to go.
> make install should not overwrite etc/trafficserver/*
> -----------------------------------------------------
>
> Key: TS-624
> URL: https://issues.apache.org/jira/browse/TS-624
> Project: Traffic Server
> Issue Type: Improvement
> Components: Build
> Affects Versions: 2.1.4
> Reporter: Billy Vierra
> Priority: Critical
> Fix For: 2.1.7
>
>
> This makes it so that upgrades require you to backup the config files and
> copy then over after the make install.
> By default make install should not copy config files. There should be an
> additional option to install the config files.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira