Modified the 'Type=oneshot' to 'Type=simple' in the systemd service file
Summary
Modified the 'Type=oneshot' to 'Type=simple' in the systemd service file
When the process is started using 'systemctl start' or 'systemctl restart', the status remains stuck at
'activating'
because the oneshot type does not indicate to systemd that the process has started successfully.
Changing the type to simple ensures that systemd recognizes the process as running once it is launched.
Hello @1kjnv,
Thanks for your pull request! A Core Committer will review your pull request soon. For code contributions, you can learn more about the review process here.
Per the Mattermost Contribution Guide, we need to add you to the list of approved contributors for the Mattermost project.
Please help complete the Mattermost contribution license agreement?
Once you have signed the CLA, please comment with /check-cla and confirm that the CLA check is green.
This is a standard procedure for many open source projects.
Please let us know if you have any questions.
We are very happy to have you join our growing community! If you're not yet a member, please consider joining our Contributors community channel to meet other contributors and discuss new opportunities with the core team.
/check-cla
Newest code from 1kjnv has been published to preview environment for Git SHA d85ab97a5b582b9e6872129df7962a27a841bf8d
I think we want to keep oneshot as we want to wait for the service to have actually started, the option "simple" does not wait even if there was a failure.
Here is a reference that describes the difference between them https://stackoverflow.com/a/39050387
@enahum I'd like to change 'oneshot' to 'simple' for the following reasons:
- mattermost-push-proxy is a long-running process that is meant to keep running
- the system is stuck in the
'activating'state because systemd is expecting the process to exit cleanly(as it should with'oneshot'), but it doesn't. - this can cause issues in automation workflows because
'oneshot'tells systemd to wait until the process exits before marking the service as 'started'. But, with'oneshot', your service never exits so systemd will wait forever(or until timeout). And, CLI commands likesystemctl restartoransible, shell scripts, etc., that depend on systemctl completing will hang until timeout or manual interruption (CTRL+C) - it may also break automated restart and recovery flows
@stylianosrigas any input on this?
@enahum @stylianosrigas reminder!
This PR has been automatically labelled "stale" because it hasn't had recent activity. A core team member will check in on the status of the PR to help with questions. Thank you for your contribution!