Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot enable webone.service in systemd #20

Closed
mzryz opened this issue Jan 29, 2021 · 4 comments
Closed

Cannot enable webone.service in systemd #20

mzryz opened this issue Jan 29, 2021 · 4 comments

Comments

@mzryz
Copy link

@mzryz mzryz commented Jan 29, 2021

Hi, I'm struggling to get WebOne to start automatically, using Rapsbian headless.

I try: sudo systemctl enable webone
Created symlink /etc/systemd/system/default.target.wants/webone.service → /etc/systemd/system/webone.service.


test the proxy, nothing.. doesn't seem to be running in htop either...
Load WebOne normally from the command line, proxy is working...

Any ideas? Cheers

@atauenis
Copy link
Owner

@atauenis atauenis commented Jan 29, 2021

What displays on sudo service webone status?
Does sudo service webone start starts the proxy manually? If does, probably need to re-run systemctl disable webone & systemctl enable webone.

@atauenis
Copy link
Owner

@atauenis atauenis commented Feb 1, 2021

Checked on a fresh Debian 10 x86_64 installation, yes, the bug presents (strange that it hasn't appear on Debian 11 test box):

atauenis@test:~$ sudo service webone status
● webone.service - WebOne HTTP Proxy Server
   Loaded: loaded (/etc/systemd/system/webone.service; disabled; vendor preset: enabled)
   Active: inactive (dead)
     Docs: https://github.com/atauenis/webone/wiki/
atauenis@test:~$ sudo nano /etc/WebOne/webone.conf
atauenis@test:~$ sudo systemctl enable webone
Created symlink /etc/systemd/system/default.target.wants/webone.service → /etc/systemd/system/webone.service.
atauenis@test:~$ sudo service webone start
atauenis@test:~$ sudo service webone status
● webone.service - WebOne HTTP Proxy Server
   Loaded: loaded (/etc/systemd/system/webone.service; enabled; vendor preset: enabled)
   Active: inactive (dead)
     Docs: https://github.com/atauenis/webone/wiki/

Feb 01 22:02:39 test systemd[1]: Started WebOne HTTP Proxy Server.
Feb 01 22:02:39 test WebOne[25741]: WebOne HTTP Proxy Server 0.10.4.0
Feb 01 22:02:39 test WebOne[25741]: (C) https://github.com/atauenis/webone
Feb 01 22:02:39 test WebOne[25741]: Using configuration file /etc/WebOne/webone.conf.
Feb 01 22:02:39 test WebOne[25741]: Cannot use log file /var/log/webone.log: Access to the path '/var/log/webone.log' is denied.
Feb 01 22:02:39 test WebOne[25741]: Error: log file is not available, please fix the problem. Exiting.
Feb 01 22:02:39 test systemd[1]: webone.service: Succeeded.
atauenis@test:~$

Trying to fix the service by running commands from postinst script by hand:

atauenis@test:~$ sudo touch /var/log/webone.log
atauenis@test:~$ sudo chmod 666 /var/log/webone.log
atauenis@test:~$ sudo service webone start
atauenis@test:~$ sudo service webone status
● webone.service - WebOne HTTP Proxy Server
   Loaded: loaded (/etc/systemd/system/webone.service; enabled; vendor preset: enabled)
   Active: active (running) since Mon 2021-02-01 22:04:51 MSK; 3s ago
     Docs: https://github.com/atauenis/webone/wiki/
 Main PID: 25785 (WebOne)
    Tasks: 12 (limit: 4915)
   Memory: 9.5M
   CGroup: /system.slice/webone.service
           └─25785 /usr/local/bin/WebOne --daemon

Feb 01 22:04:51 test systemd[1]: Started WebOne HTTP Proxy Server.
Feb 01 22:04:51 test WebOne[25785]: WebOne HTTP Proxy Server 0.10.4.0
Feb 01 22:04:51 test WebOne[25785]: (C) https://github.com/atauenis/webone
Feb 01 22:04:52 test WebOne[25785]: Using configuration file /etc/WebOne/webone.conf.
Feb 01 22:04:52 test WebOne[25785]: Using event log file /var/log/webone.log.
Feb 01 22:04:52 test WebOne[25785]: The proxy runs in daemon mode. See all messages in the log file.
atauenis@test:~$

Working.

Seems that there is a bug in post-install script in .deb package.

@atauenis
Copy link
Owner

@atauenis atauenis commented Feb 2, 2021

Re-uploaded Linux binaries of v.0.10.4, so they should not have this bug.

@mzryz
Copy link
Author

@mzryz mzryz commented Feb 6, 2021

Re-uploaded Linux binaries of v.0.10.4, so they should not have this bug.

Thank you for fixing so quickly!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants