mirror of https://github.com/go-gitea/gitea
Git with a cup of tea, painless self-hosted git service
Mirror for internal git.with.parts use
https://git.with.parts
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
549 B
23 lines
549 B
#!/bin/bash
|
|
|
|
if ! env | grep -q root; then
|
|
echo "
|
|
+----------------------------------------+
|
|
| You are not running gitea as root. |
|
|
| This is required for the snap package. |
|
|
| Please re-run as root. |
|
|
+----------------------------------------+
|
|
"
|
|
$SNAP/gitea/gitea --help
|
|
exit 1
|
|
fi
|
|
|
|
# Set usernames for gitea
|
|
export USERNAME=root
|
|
export USER=root
|
|
|
|
export GITEA_WORK_DIR=$(snapctl get gitea.snap.workdir)
|
|
export GITEA_CUSTOM=$(snapctl get gitea.snap.custom)
|
|
|
|
$SNAP/bin/gconfig save
|
|
cd $SNAP/gitea; ./gitea $@
|
|
|