blob: 23e0c663bd63123c83337d90949ad073a225ce11 (
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
|
post_install() {
echo "Creating user and group teamcity..."
getent group teamcity &>/dev/null || groupadd -r teamcity >/dev/null
getent passwd teamcity &>/dev/null || useradd -r -g teamcity -d '/var/lib/teamcity' -s /bin/bash -G teamcity teamcity >/dev/null
chown -R teamcity '/opt/teamcity'
chown -R teamcity '/var/lib/teamcity'
echo "Make sure /usr/lib/jvm/default symlinks to your prefered Java environment."
echo "If you want to use a different Java, set it in /etc/conf.d/teamcity"
echo ""
echo "To start your instance:"
echo " systemctl start teamcity-server"
echo " systemctl start teamcity-agent"
echo
echo "Hint for newcomers: by default, TeamCity operates on port 8111."
}
post_upgrade() {
echo "Make sure /usr/lib/jvm/default symlinks to your prefered Java environment."
echo "If you want to use a different Java, set it in /etc/conf.d/teamcity"
}
post_remove() {
echo "Removing teamcity user and group..."
getent passwd teamcity &>/dev/null && userdel teamcity >/dev/null
getent group teamcity &>/dev/null && groupdel teamcity >/dev/null
}
|