If you are searching for easy and open source software for automation service then Rundeck might be a best option. It is very useful to create simple to complex tasks on a local machine or in a remote machine. Rundeck comes with command line tools, WebApi and command line tools. Rundeck is available in commercial and community edition.
Rundeck is built around the concept of managing servers in a computer network using a single centralized management server. The administrative tasks can be performed by using a web interface.
In this article, we will learn how to install Rundeck on Ubuntu 20.04.
Before performing the installation, update and upgrade the Ubuntu system to its latest index repository.
$ sudo apt update
$ sudo apt upgrade
Rundeck is a Java based application and to run the application we need a java 8 or java 11. Install JDK 11 using the following command
$ sudo apt install openjdk-11-jre
$ java –version
Rundeck can be installed with database MySQL/MariaDB, MS SQL, PostgreSQL and Oracle to store the data. In this example, we are going to use MariaDB.
Install dependency and MariaDB packages using the command below.
$ sudo apt install software-properties-common mariadb-server mariadb-client
Enable and start mariadb service
$ sudo systemctl enable mariadb.service
$ sudo systemctl status mariadb.service
Once the MySQL/MariaDB is installed, run the following command to secure the database system.
$ sudo mysql_secure_installation
Now create a database and database user for Rundeck.
$ mysql -u root -p
MariaDB [(none)]> CREATE DATABASE rundeck_db;
MariaDB [(none)]> CREATE USER 'rundeck_user'@'localhost' IDENTIFIED BY 'my-strong-password';
MariaDB [(none)]> GRANT ALL PRIVILEGES ON *.* TO 'rundeck_user'@'localhost' WITH GRANT OPTION;
MariaDB [(none)]> FLUSH PRIVILEGES;
MariaDB [(none)]> exit
Replace my-strong-password with your database password which will be used by the Rundeck application.
The Rundeck application package is not available in Ubuntu 20.04 by default. We need to Create a repository file and append the following content in the file.
$ sudo nano /etc/apt/sources.list.d/rundeck.list
deb https://packages.rundeck.com/pagerduty/rundeck/any/ any main
deb-src https://packages.rundeck.com/pagerduty/rundeck/any/ any main
Save the file and exit.
Once the repository file is created, run the following command to import the repo signing key.
$ curl -L https://packages.rundeck.com/pagerduty/rundeck/gpgkey | sudo apt-key add -
Update the Ubuntu system to reflect the changes
$ sudo apt update
Now install rundeck using the following command.
$ sudo apt install rundeck
Once the installation is completed, some configuration files need to be changed. Edit the file rundeck-config.properties using any text editor and make the following changes.
$ sudo nano /etc/rundeck/rundeck-config.properties
grails.serverURL=http://RUNDECK_SERVER_IP:4440
dataSource.driverClassName = org.mariadb.jdbc.Driver
dataSource.url = jdbc:mysql://localhost/rundeck_db?autoReconnect=true&useSSL=false
dataSource.username = rundeck_user
dataSource.password = my_strong_password
Replace the following things with your environment.
Enable and start the rundeck service as:
$ sudo systemctl enable rundeckd.service
$ sudo systemctl start rundeckd.service
If ufw is running on the ubuntu system, we need to allow the rundeck port for incoming traffic. Run the following command to open the rundeck port.
$ sudo ufw allow 4440/tcp
http://rundeck_server_ip:4440
Use the following credentials
Username: admin
Password : admin
Dashboard after login
In this article, we learned how to install Rundeck on Ubuntu 20.04 for task automations. Also we covered how to allow the port in the firewall and access Rundeck webui in the browser.
Karim Buzdar holds a degree in telecommunication engineering and holds several sysadmin certifications including CCNA RS, SCP, and ACE. As an IT engineer and technical author, he writes for various websites.
One of the most critical gaps in traditional Large Language Models (LLMs) is that they…
Canonical is continuously hiring new talent. Being a remote- first company, Canonical’s new joiners receive…
What is patching automation? With increasing numbers of vulnerabilities, there is a growing risk of…
Wouldn’t it be wonderful to wake up one day with a desire to explore AI…
Ubuntu and Ubuntu Pro supports Microsoft’s Azure Cobalt 100 Virtual Machines (VMs), powered by their…
Welcome to the Ubuntu Weekly Newsletter, Issue 870 for the week of December 8 –…