Page MenuHomeFreeBSD

devel/gogs: Changed user from gogs to git; Moved ini file under /usr/local/etc
ClosedPublic

Authored by yuri on Dec 12 2017, 11:50 PM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Dec 11, 9:59 PM
Unknown Object (File)
Sun, Dec 8, 2:48 PM
Unknown Object (File)
Sun, Dec 8, 2:48 PM
Unknown Object (File)
Sun, Dec 8, 2:48 PM
Unknown Object (File)
Sun, Dec 8, 2:48 PM
Unknown Object (File)
Sun, Dec 8, 2:48 PM
Unknown Object (File)
Sun, Dec 8, 2:48 PM
Unknown Object (File)
Sun, Dec 8, 2:22 PM

Diff Detail

Repository
rP FreeBSD ports repository
Lint
No Lint Coverage
Unit
No Test Coverage
Build Status
Buildable 13530
Build 13754: arc lint + arc unit

Event Timeline

I think this needs an UPDATING entry.

Why change the user and group this runs with? Was it not working before? These things must be explained now, because they will have to be in the commit message.

Also, if a user or a group are no longer used, you have to remove them from UIDs and GIDs.

In D13469#281623, @mat wrote:

Why change the user and group this runs with? Was it not working before? These things must be explained now, because they will have to be in the commit message.

Also, if a user or a group are no longer used, you have to remove them from UIDs and GIDs.

I asked the person who requested the change to explain it here. It works perfectly well with the user gogs, as far as I know.

This comment was removed by yuri.

I feel like I'm a broken record on this, but maybe, just maybe, the squeaky wheel will get the grease?

I have been saying this since I first was aware of this port before it was even added to the ports tree. I even thought I got through, but somehow my words fell on forgetful, if not deaf, ears.

https://lists.freebsd.org/pipermail/freebsd-ports/2016-February/102137.html
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=205283#c54

As I have said before, having this "gogs" user rather than "git" is a POLA violation: https://en.wikipedia.org/wiki/Principle_of_least_astonishment

Let me illustrate:

  1. devel/py-gitosis: What is the suggested by upstream documentation default user to run as? git What user does the FreeBSD port use? git
  1. devel/gitolite: What is the suggested by upstream documentation default user to run as? git What user does the FreeBSD port use? git
  1. devel/gitolite2: What is the suggested by upstream documentation default user to run as? git What user does the FreeBSD port use? git
  1. www/gitlab: What is the suggested by upstream documentation default user to run as? git What user does the FreeBSD port use? git
  1. www/gitea: What is the suggested by upstream documentation default user to run as? git What user does the FreeBSD port use? git

Maybe you see where I'm going with this?

  1. devel/gogs: What is the suggested by upstream documentation default user to run as? git What user does the FreeBSD port use? gogs

Well that's certainly different! You might even say it is surprising or astonishing which, of course, means that it violates the Principle of Least Astonishment/Surprise.

So why does the port use the *gogs* user anyway?

As far as I can tell, the only reasons I can see:

  1. To isolate Gogs from those other systems.

    But as I already argued in emails and the original ticket, that is more likely a custom case and not likely to occur in the usual case. The evidence that all of the other software in this class also defaults to git supports the case that the isolation would be a custom case and the port should just use the default git user so normal users are not surprised.
  1. The change was forgotten before the port added to the tree.

    This one seems to be the main reason because in the original ticket, Yuri said he would change the user to git, but that did not happen. Just because that didn't happen doesn't mean that we should not fix it with this change.

The sooner we make this change, the fewer people will install Gogs and then wonder why it is using the gogs user rather than the git user.

The sooner we make this change, the fewer people will install Gogs and then wonder why it is using the gogs user rather than the git user.

Gogs only works through the web interface. How will users be practically disadvantaged by the user name used on the server? What will give them a clue short of inspecting the user name?

I'm the one who missed Douglas comment in the original PR, my apologies. Nevertheless I think we should change the user to "git" to keep this port in sync with other ports.
It'll require an entry in the UPDATING and some manual labour from the user, but it would be better to do this sooner than later to minimize the fallout.

Gogs does not only work through the web interface, just like the rest of the software in the class it is also exposed through SSH and as such, SSH links would be gogs@[host]:[user]/[repo] rather than the normal git@[host]:[user]/[repo] that users would expect.

Some fixed by the maintainer.

dmgk retitled this revision from devel/gogs: Changed user from gogs to git; Moved ini file under /etc to devel/gogs: Changed user from gogs to git; Moved ini file under /usr/local/etc.Dec 13 2017, 10:44 PM

Go for it. Should the UPDATING entry advise people to remove the old gogs user/group? If so, please add that text when you commit it.

This revision is now accepted and ready to land.Dec 18 2017, 9:49 PM

Go for it. Should the UPDATING entry advise people to remove the old gogs user/group? If so, please add that text when you commit it.

The patch actually updates UIDs/GUIDs - deletes user/group.

In D13469#283032, @yuri wrote:

Go for it. Should the UPDATING entry advise people to remove the old gogs user/group? If so, please add that text when you commit it.

The patch actually updates UIDs/GUIDs - deletes user/group.

Right, but prior users will still have gogs user/group on their system, which should be deleted with pw userdel/groupdel, no?

In D13469#283032, @yuri wrote:

Go for it. Should the UPDATING entry advise people to remove the old gogs user/group? If so, please add that text when you commit it.

The patch actually updates UIDs/GUIDs - deletes user/group.

Right, but prior users will still have gogs user/group on their system, which should be deleted with pw userdel/groupdel, no?

Yes, you are right, I will add this to the message.

Thank you!

This revision was automatically updated to reflect the committed changes.