Skip to main content

DB::MYSQL

Establish connection to MySQL Database.

Syntax

resources:
<resource-id>:
type: DB::MYSQL
props:
host: <host>
port: <port>
dbName: <database-name>
username: <username>
password: <password>

Properties

PropertyDescriptionType
<resource-id>Unique identifier for the resourcestring
typeType of the resourcestring
propsProperties specific to this resource. Refer to props section for more details.object

props

PropertyDescriptionRequired
hostHostname or IP address of the database servertrue
portPort number of the database servertrue
dbNameName of the database to connect totrue
usernameUsername for the database authenticationtrue
passwordPassword for the database authenticationtrue

Example

resources:
mysqlDb:
type: DB::MYSQL
props:
username: admin
password: password123
host: localhost
port: 3306
dbName: db_name