With RunCloud you can create and manage your databases using MariaDB, which is a popular and widely used database management system. You can create a separate database user for each database. These users are accounts that have permission to access and modify your database.

Creating A Database User

We need to create a database user before we create a database. To create a database user on RunCloud, follow these steps:

  1. On the RunCloud dashboard, select the server where you want to host your database.
  2. Click on Database in the left sidebar. This will show you all your existing databases.
RunCloud Create a database
  1. Click on Database Users in the sub-menu.
  2. Click on Add New Database User.
Adding a new user on RunCloud
  1. Enter a username for your new database user. It is recommended to use a combination of letters, numbers, and symbols for the username.
Creating database user credentials on RunCloud
  1. Click on Add Database User. This will create a new database user account on your server.

Creating A Database

After you have created a user, you can proceed to create a database.

  1. Click on Databases in the sub-menu.
  2. Click on Add New Database.
Creating a new Database on RunCloud
  1. Enter a name for your new database. It must be at least 5 characters long.
  2. Optionally, choose a collation for your new database. A collation is a set of rules that determines how data is sorted and compared in your database. You can leave this field blank to use the default collation. Refer to our post on database collations to understand how to use this setting.
  3. Assign a database user to your new database. You can choose the database user you just created, or any other existing database user on your server. The assigned database user will have full permissions to access and modify your database.
Making a database and granting permissions to a user on RunCloud.
  1. Click on Save Database.

Your new database will be created and added to your server. You can see the details of your database on the Databases page. You can also manage your database users and databases by clicking on the ellipsis (three dots) icon next to them, and choosing from the available options, such as:

  • Delete: Remove a database user or a database from your server.
  • Assign & Revoke User: Grant access to a database user or remove a database user from a database and revoke their permissions.
RunCloud edit a database settings

After creating the required database and user accounts, you can link this database to your web application. This would allow you to perform automatic backups of your database along with your web application.

To link the database, go to the web application dashboard and click on the “Settings” button on the left. On the settings page, scroll down to the “Linked Databases” section and select your database from the drop-down menu.

Link a database in RunCloud.

After selecting the database, click on the “Update Linked Database” to save the changes.

Note: You can use your new database for any web application you deploy on your server. To do so, you will need to enter the database name, username, password, and host (localhost) when you configure your web application settings.