Please find steps involved in installing TeamCity on Ubuntu server with MySQL:
Here below are the steps:
Java Installation
sudo apt-get update
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java8-installer -y
Teamcity Installation
First download the teamcity latest version.
sudo wget https://download.jetbrains.com/teamcity/TeamCity-2017.2.3.tar.gz
tar xfz TeamCity-2017.2.3.tar.gz
sudo mkdir /opt/jetbrains
sudo mv TeamCity/ /opt/jetbrains
sudo useradd teamcity
sudo vi /etc/init.d/teamcity
#!/bin/sh
# /etc/init.d/teamcity - startup script for teamcity
export TEAMCITY_DATA_PATH="/opt/jetbrains/TeamCity/.BuildServer"
export TEAMCITY_SERVER_OPTS=-Djava.awt.headless=true # Configure TeamCity for use on a headless OS.
case $1 in
start)
start-stop-daemon --start -c teamcity --exec /opt/jetbrains/TeamCity/bin/runAll.sh start
;;
stop)
start-stop-daemon --start -c teamcity --exec /opt/jetbrains/TeamCity/bin/runAll.sh stop
;;
esac
exit 0
sudo update-rc.d teamcity enable
sudo update-rc.d teamcity defaults
sudo chmod +x /etc/init.d/teamcity
sudo apt-get remove insserv -y
sudo apt install procps
sudo update-rc.d teamcity defaults
sudo chown -R ubuntu:ubuntu /opt/jetbrains/TeamCity
sudo service teamcity start
Open browser and access teamcity home page
http://server_ip:8111/
Click on Proceed
Now stop the Teamcity server
sudo service teamcity status
sudo service teamcity stop
MySQL Installation
TeamCity needs a database to run. You have options to choose Postgres, MySQL or any database.
Let us try with MySQL.
sudo apt-get install mysql-server -y
enter a password for default user root and repeat the password
sudo mysql -u root -p
Now execute all the commands:
create database teamcity character set UTF8 collate utf8_bin;
Use teamcity;
create user 'teamcityuser'@'localhost' identified by 'password';
grant all privileges on teamcity.* to 'teamcityuser'@'localhost';
type exit to come out
Download MySQL JDBC driver
sudo wget http://dev.mysql.com/get/Downloads/Connector-J/mysql-connector-java-5.1.31.tar.gz -O mysql-connector.tar.gz
sudo tar zxvf mysql-connector.tar.gz
cd mysql-connector-java-5.1.31/
sudo mv mysql-connector-java-5.1.31-bin.jar /opt/jetbrains/TeamCity/.BuildServer/lib/jdbc/
cd /opt/jetbrains/TeamCity/.BuildServer/lib/jdbc
mv ? mysql-connector-java-5.1.31-bin.jar
sudo chown -R teamcity:teamcity /opt/jetbrains/TeamCity
sudo chown teamcity:teamcity /opt/jetbrains/TeamCity/.BuildServer/lib/jdbc/mysql-connector-java-5.1.31-bin.jar
sudo service teamcity start
Open browser, type http://serverip:8111/
Click proceed and select MySQL as database type
Click on Proceed
enter database name as teamcity
user as teamcityuser
password as password
leave host as it is
Click on Proceed
Agree the License agreement
Hands on DevSecOps Coaching that is provided on AWS and Azure Cloud platforms. Contact Coach AK at devops.coaching@gmail.com for more info. You can also reach out to Coach AK at +1(469) 733-5248
Subscribe to:
Post Comments (Atom)
DevSecOps Bootcamp Dec 2024 Schedule | DevSecOps & AWS Azure Cloud Coaching by Coach AK | DevSecOps and Cloud Computing Online Classes
Lot of new topics covered like GitHub Actions, GitHub Advanced Security, Helm, Prometheus and Grafana..) The DevOps requirements in the IT m...
-
Let us learn how to create and configure a Self-Hosted Agent in Azure DevOps (ADO). What is an Agent? An agent is computing infrastructure w...
-
(More New Topics..New CICD tool GitHub Actions, Helm, GitHub Advanced Security included ) Here is the coaching model: Total 12 weeks of c...
-
What is Amazon EKS Amazon EKS is a fully managed container orchestration service. EKS allows you to quickly deploy a production ready Kubern...
No comments:
Post a Comment