summarylogtreecommitdiffstats
path: root/gitea.install
blob: 08c702f5b133200fa7849ff1ab90e8abe039cf0b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
post_upgrade() {
    if [ $(vercmp $2 1.6.1-1) -lt 0 ] ; then
        cat << EOF

gitea now uses its own user/group instead of the git ones.
Ownership of /var/lib/gitea tree has been changed accordingly.
You need to update your /etc/gitea/app.ini file to change the
RUN_USER variable at the top.

Next step is fixing the SSH configuration. If you have:
    AllowUsers git
in /etc/ssh/sshd_config, you need to change that to gitea.
Then restart sshd.service.
You will need to tell all your users that they have to change
git@ to gitea@ in their repos clones using git remote set-url.

If you use a PostgreSQL DB upon Unix socket, you need to fix
your [database] configuration and switch USER to gitea.
Then, you need to change it also in /var/lib/data/pg_hba.conf.
Finally, as postgres user, run psql and inside it type:
    ALTER USER git RENAME TO gitea;
    \q
Then restart postgresql.service.

In all cases, you then need to reload systemd units and
restart gitea.service.

EOF
    fi
}