This tutorial shows you how to run Apache OFBiz on Alibaba Cloud with ApsaraDB RDS for MySQL.
You can access all the tutorial resources, including deployment script (Terraform), related source code, sample data, and instruction guidance, from the GitHub project: https://github.com/alibabacloud-howto/opensource_with_apsaradb/tree/main/apache-superset
For more tutorials around Alibaba Cloud Database, please refer to: https://github.com/alibabacloud-howto/database
Apache OFBiz is an open source enterprise resource planning (ERP) system. It provides a suite of enterprise applications that integrates and automates many of the business processes of an enterprise.
To enhance Apache OFBiz with a high availability database, we will show you the steps of deploying and working with Alibaba Cloud ApsaraDB RDS for MySQL database.
By default OFBiz includes and is configured for an embedded Java database called Derby. This is a great database for demos, testing, development, and even small-scale production environments. There are many databases that OFBiz can use, both commercial and open source.
While there are significant production instances of OFBiz running using Oracle, MS SQL Server, and so on, we generally recommend using an open source database such as PostgreSQL or MySQL. The choice of database is an important decision and may have future impacts on your implementation. If you do not have a preferred database choice then we strongly recommend discussing options with an experienced consultant before making a final decision.
In this tutorial, we will show the case of using RDS MySQL high availability edition to replace the Derby for more stable production purpose.
Deployment architecture:
Run the terraform script to initialize the resources (in this tutorial, we use RDS MySQL as backend database of OFBiz, so ECS and RDS MySQL instances are included in the Terraform script). Please specify the necessary information and region to deploy.
After the Terraform script execution finished, the ECS and RDS MySQL instance information are listed as below.
Please log on to ECS with ECS EIP
.
ssh root@<ECS_EIP>
Then execute the following commands to setup the Apache OFBiz.
wget https://raw.githubusercontent.com/alibabacloud-howto/opensource_with_apsaradb/main/apache-ofbiz/setup.sh
sh setup.sh
After the setup script execution finished, go to edit the property host-headers-allowed
in security.properties
file to add the host IP of the ECS:
cd ofbiz-framework
vim framework/security/config/security.properties
Then edit the entityengine_backup.xml
configuration file to set the backend database as RDS MySQL to replace the Derby. Edit with the RDS MySQL connection string and database accounts as shown in the following pictures.
cp framework/entity/config/entityengine.xml framework/entity/config/entityengine_backup.xml
vim framework/entity/config/entityengine.xml
Replace Derby with RDS MySQL in default
, default-no-eca
and test
delegators as follows:
localderby
-> localmysql
localderbyolap
-> localmysqlolap
localderbytenant
-> localmysqltenant
Execute the following command to build and initialize the OFBiz.
./gradlew cleanAll loadAll
Execute the following command to start the OFBiz.
./gradlew ofbiz
OFBiz now started. Please visit the following URL to visit the OFBiz now.
https://<ECS_EIP>:8443/accounting
By default, the administrator account name is admin
, password is ofbiz
.
Deploy and Run Netflix Dispatch on Alibaba Cloud with ApsaraDB RDS for PostgreSQL
ApsaraDB - September 8, 2021
ApsaraDB - September 23, 2021
ApsaraDB - November 21, 2022
Alibaba Clouder - December 18, 2017
H Ohara - May 8, 2024
Alibaba Cloud Indonesia - January 20, 2023
An on-demand database hosting service for MySQL with automated monitoring, backup and disaster recovery capabilities
Learn MoreAlibaba Cloud PolarDB for MySQL is a cloud-native relational database service 100% compatible with MySQL.
Learn MoreA fully-managed Apache Kafka service to help you quickly build data pipelines for your big data analytics.
Learn MoreAnalyticDB for MySQL is a real-time data warehousing service that can process petabytes of data with high concurrency and low latency.
Learn MoreMore Posts by ApsaraDB