Bug 1269928

Summary: Reccomended Method of Changing Cockpit Port Results in Two Instances
Product: [Fedora] Fedora Reporter: Dominic Robinson <development-K9RvgheM1OmXW9pm>
Component: cockpitAssignee: Stef Walter <stefw>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 22CC: development-K9RvgheM1OmXW9pm, stefw
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-10-19 09:39:31 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Dominic Robinson 2015-10-08 13:52:21 UTC
Description of problem:
It is necessary for some users to be able to change the port cockpit listens on if it interferes with other running services. The recommended method of doing this is detailed within the documentation: http://files.cockpit-project.org/guide/latest/listen.html#listen-systemd

This method is mean't to override the behaviour of the default cockpit.socket service. However this method results in dual instances of cockpit i.e. cockpit listens on the default port 9090 and also the newly specified one.

It is possible to achieve the desired effect by modifying the packaged systemd file here: /usr/lib/systemd/system/cockpit.service - this works but is ofcourse overwritten by package updates, which is ofcourse very inconvenient.


Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1. $ mkdir /etc/systemd/system/cockpit.socket.d/
   $ cat << EOF > /etc/systemd/system/cockpit.socket.d/listen.conf
     [Socket]
     ListenStream=9095
     EOF
   $ sudo systemctl daemon-reload
   $ sudo systemctl restart cockpit.socket
2. Browse to http://localhost:9090 - Confirm cockpit loads
3. Browse to http://localhost:9095 - Confirm cockpit loads

Actual results:
As above cockpit is listening on both ports and subsequently does not help with clearing ports for other services.

Expected results:
Cockpit should listen only on 9095 (based on the steps above).

Additional info:
Additionally when updating cockpit no rpmsave files are generated if you modify the core service /usr/lib/systemd/system/cockpit.service