mirror of
https://git.coolaj86.com/coolaj86/gitea-installer.sh.git
synced 2024-12-21 13:55:27 +00:00
Add option to specify the version manually. Update docs.
This commit is contained in:
parent
91f4ecd3f8
commit
20fb4b7dfe
@ -14,6 +14,8 @@ You can download and run the installer script:
|
||||
|
||||
`curl -fsSL https://git.coolaj86.com/coolaj86/gitea-installer.sh/raw/branch/master/install.bash | bash`
|
||||
|
||||
You can pick a specific version to install. For example, if you were nostalgic for 1.2.0, you could run `curl -fsSL https://git.coolaj86.com/coolaj86/gitea-installer.sh/raw/branch/master/install.bash | bash -s version 1.2.0`
|
||||
|
||||
## Install Manually
|
||||
|
||||
Or manually install by reading these instructions and following along:
|
||||
@ -82,4 +84,4 @@ You can find more information about customization and templates in the docs and
|
||||
|
||||
# Troubleshooting systemd
|
||||
|
||||
See [Troubleshooting systemd](https://git.coolaj86.com/coolaj86/service-installer.sh/src/master/README.md#troubleshooting-systemd)
|
||||
See [Troubleshooting systemd](https://git.coolaj86.com/coolaj86/service-installer.sh/src/master/README.md#troubleshooting-systemd)
|
||||
|
25
install.bash
Normal file → Executable file
25
install.bash
Normal file → Executable file
@ -6,9 +6,28 @@ VER=$(curl --silent "https://api.github.com/repos/go-gitea/gitea/releases/latest
|
||||
sed -E 's/.*"([^"]+)".*/\1/' | # Pluck JSON value
|
||||
sed 's|[v,]||g' ) # Remove v
|
||||
|
||||
# wget -O install-gitea.bash https://git.coolaj86.com/coolaj86/gitea-installer/raw/master/install.bash; bash install-gitea.bash
|
||||
# or
|
||||
# wget -O - https://git.coolaj86.com/coolaj86/gitea-installer/raw/master/install.bash | bash
|
||||
while [[ $# -gt 0 ]]
|
||||
do
|
||||
key="$1"
|
||||
|
||||
case $key in
|
||||
-v|version)
|
||||
VER="$2"
|
||||
shift # past argument
|
||||
;;
|
||||
*)
|
||||
# unknown option
|
||||
if test -z "${unknown}"
|
||||
then
|
||||
unknown=$1
|
||||
else
|
||||
echo "Unknown Option"
|
||||
exit 1
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
shift # past argument or value
|
||||
done
|
||||
|
||||
# Create a 'gitea' user and group with the home /opt/gitea, no password (because it's a system user) and no GECOS
|
||||
sudo adduser gitea --home /opt/gitea --disabled-password --gecos ''
|
||||
|
Loading…
Reference in New Issue
Block a user