How to install liquibase | Database DevOps
To install Liquibase on RHEL (Red Hat Enterprise Linux), follow these steps:
- Install Java: Liquibase requires Java to run. If you don’t have it already installed, you can install it using the following command:
sudo yum install java
2. Download Liquibase: Download the latest version of Liquibase from the official website: https://www.liquibase.org/download
wget https://github.com/liquibase/liquibase/releases/download/v4.5.0/liquibase-4.5.0.tar.gz
3. Extract Liquibase: Extract the downloaded file using the following command:
tar -xvzf liquibase-4.5.0.tar.gz
4. Move the extracted files to a desired location: Move the extracted files to a directory of your choice. For example:
sudo mv liquibase /opt/
5. Set up Liquibase: Set up Liquibase by creating a new file called “liquibase.sh” in the “/etc/profile.d/” directory and adding the following content to it:
export PATH=$PATH:/opt/liquibase/
6. Make the “liquibase.sh” file executable:
sudo chmod +x /etc/profile.d/liquibase.sh
7. Reload the environment: Reload the environment to apply the changes made in the “/etc/profile.d/” directory:
source /etc/profile.d/liquibase.sh
8. Verify the installation: Verify the installation by running the following command:
liquibase --version
That’s it! You have successfully installed Liquibase on RHEL.