- Using "Wants=csr.service" in csr-OOO.socket is replaced by putting csr.service in multi-user.target.wants.
- Using "After=csr.service" in csr-OOO.socket is not requires because there is an explicit dependency between socket and service.
- All four sockets are required for csr.service. So, "Requires=OOO.socket" must be in csr.service.
- "Sockets=" in the csr.service is replaced by "Requires=OOO.socket". ("Sockets=" includes "After=" and "Wants=")
Change-Id: If6303fcf17f16c70b4c5b67cca897f0c650b4b85
%install_service sockets.target.wants %{service_name}-cs.socket
%install_service sockets.target.wants %{service_name}-wp.socket
%install_service sockets.target.wants %{service_name}-admin.socket
+%install_service multi-user.target.wants %{service_name}.service
%install_service ../user/sockets.target.wants %{service_name}-popup.socket
%install_service ../system/user-sockets@.target.wants %{service_name}-popup@.socket
%{bin_dir}/%{service_name}-server
%{bin_dir}/%{service_name}-popup
%{_unitdir}/%{service_name}.service
+%{_unitdir}/multi-user.target.wants/%{service_name}.service
%{_unitdir}/sockets.target.wants/%{service_name}-cs.socket
%{_unitdir}/sockets.target.wants/%{service_name}-wp.socket
%{_unitdir}/sockets.target.wants/%{service_name}-admin.socket
[Unit]
Description=Csr admin socket
-Wants=@SERVICE_NAME@.service
-Before=@SERVICE_NAME@.service
[Socket]
ListenStream=/tmp/.@SERVICE_NAME@-admin.socket
[Unit]
Description=Csr content screening socket
-Wants=@SERVICE_NAME@.service
-Before=@SERVICE_NAME@.service
[Socket]
ListenStream=/tmp/.@SERVICE_NAME@-cs.socket
[Unit]
Description=Csr web protection socket
-Wants=@SERVICE_NAME@.service
-Before=@SERVICE_NAME@.service
[Socket]
ListenStream=/tmp/.@SERVICE_NAME@-wp.socket
SecureBits=keep-caps
Capabilities=cap_dac_override,cap_fowner=i
ExecStart=@BIN_DIR@/@SERVICE_NAME@-server
-Sockets=@SERVICE_NAME@-cs.socket
-Sockets=@SERVICE_NAME@-wp.socket
-Sockets=@SERVICE_NAME@-admin.socket