[Kimchi-devel] [PATCH v2] Create empty files on rpm build
Kevin Zander
klzander at linux.vnet.ibm.com
Mon Apr 13 22:13:12 UTC 2015
On Mon, 2015-04-13 at 17:19 -0300, Aline Manera wrote:
>
>
> On 13/04/2015 17:00, Crístian Viana wrote:
>
> > I tested this patch on Fedora 21 and, after removing Kimchi, some
> > files were still left on the system.
> >
> >
> > I installed the RPM, started the Kimchi server, stopped the server
> > and then I removed the RPM. Here's the final output of my tests:
>
> Yeap! I talked to Ramon about that.
> Those 2 cert files are created automatically according to the user
> configuration, ie, if the user provides them Kimchi will not generate
> those files.
> So they may exist or not on package removal.
>
> >
> >
> > [kimchi at localhost ~]$ ls /etc/kimchi/
> > distros.d kimchi-cert.pem kimchi.conf kimchi-key.pem
> > nginx.conf.in nginx_kimchi.conf
> > [kimchi at localhost ~]$ sudo yum remove kimchi
> > [...]
> > [kimchi at localhost ~]$ ls /etc/kimchi/
> >
> > kimchi-cert.pem kimchi-key.pem
> > [kimchi at localhost ~]$
Why not use a %preun/%postun script in the spec file? Test for the
existence of files that Kimchi can generate and remove accordingly.
More information about the Kimchi-devel
mailing list