Skip to content

Commit

Permalink
fedora-spec: the db and id must be owned
Browse files Browse the repository at this point in the history
Both conf.db and system-id.conf needs to be owned, so
spec now list them in the %files section.  However,
they are not shipped with the rpm (%ghost)

Signed-off-by: Flavio Leitner <fbl@redhat.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
  • Loading branch information
fleitner authored and blp committed Nov 6, 2014
1 parent c1aadf4 commit 1c9564e
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions rhel/openvswitch-fedora.spec.in
Expand Up @@ -93,7 +93,7 @@ make %{?_smp_mflags}
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT
install -d -m 755 $RPM_BUILD_ROOT/etc
install -d -m 755 $RPM_BUILD_ROOT/etc/openvswitch
install -d -m 0755 $RPM_BUILD_ROOT%{_sysconfdir}/openvswitch
install -p -D -m 0644 rhel/usr_lib_systemd_system_openvswitch.service \
$RPM_BUILD_ROOT%{_unitdir}/openvswitch.service
install -p -D -m 0644 rhel/usr_lib_systemd_system_openvswitch-nonetwork.service \
Expand Down Expand Up @@ -136,6 +136,9 @@ install -d -m 0755 $RPM_BUILD_ROOT%{_includedir}/openflow
install -p -D -m 0644 include/openflow/*.h \
-t $RPM_BUILD_ROOT%{_includedir}/openflow

touch $RPM_BUILD_ROOT%{_sysconfdir}/openvswitch/conf.db
touch $RPM_BUILD_ROOT%{_sysconfdir}/openvswitch/system-id.conf

%check
%if %{with check}
if make check TESTSUITEFLAGS='%{_smp_mflags}' ||
Expand Down Expand Up @@ -194,7 +197,10 @@ systemctl start openvswitch.service

%files
%defattr(-,root,root)
%config /etc/sysconfig/openvswitch
%dir %{_sysconfdir}/openvswitch
%config %ghost %{_sysconfdir}/openvswitch/conf.db
%config %ghost %{_sysconfdir}/openvswitch/system-id.conf
%config(noreplace) %{_sysconfdir}/sysconfig/openvswitch
%config /etc/logrotate.d/openvswitch
%{_unitdir}/openvswitch.service
%{_unitdir}/openvswitch-nonetwork.service
Expand Down Expand Up @@ -243,7 +249,6 @@ systemctl start openvswitch.service
/var/lib/openvswitch
/var/log/openvswitch
/usr/share/openvswitch/scripts/ovs-ctl
%exclude /etc/openvswitch
%exclude /usr/bin/ovs-benchmark
%exclude /usr/bin/ovs-parse-backtrace
%exclude /usr/bin/ovs-pcap
Expand Down

0 comments on commit 1c9564e

Please sign in to comment.