Can't get gogs going as a service

Newest gogs build running on Ubuntu 16.04

Tried with both init.d and systemd and neither seem to work. I don’t see any errors in any logs but it fails to start. Running the command to manually start it works perfect.

Gogs is in /home/git/gogs and runs under the user git which is in the example scripts. I’m not seeing any reason for it to not work. Any ideas?

Edit: Figured it out. The gogs directory needed to be chown’d to the user git

## RaspBerry ##
Raspbian GNU/Linux 10 \n \l
Linux gw1 4.19.97-v7+ #1294 SMP Thu Jan 30 13:15:58 GMT 2020 armv7l GNU/Linux

I have the same issue though my working directories are different than the default ones.
I have already chown’d using git:git all the directories that Gogs has or should have access to but still nothing…
I enabled the logs verbosity but nothing

Anyway to get more details on why the start fails?

As eskimo if I start it manually everything is fine.

I use SQLite

Thanks Alex

Edit: I figured it out

I had to review the following options

in /usr/local/src/gogs/scripts/systemd/gogs.service I had to comment out ProtectSystem=full


1 Like

Just arrived to the same conclusion and wondered if someone else ran into the same issue / solution! :+1: