DatabaseArgs

data class DatabaseArgs(val charset: Output<String>? = null, val collation: Output<String>? = null, val name: Output<String>? = null, val resourceGroupName: Output<String>? = null, val serverName: Output<String>? = null) : ConvertibleToJava<DatabaseArgs>

Manages a MariaDB Database within a MariaDB Server

Example Usage

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azure.core.ResourceGroup;
import com.pulumi.azure.core.ResourceGroupArgs;
import com.pulumi.azure.mariadb.Server;
import com.pulumi.azure.mariadb.ServerArgs;
import com.pulumi.azure.mariadb.Database;
import com.pulumi.azure.mariadb.DatabaseArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var exampleResourceGroup = new ResourceGroup("exampleResourceGroup", ResourceGroupArgs.builder()
.location("West Europe")
.build());
var exampleServer = new Server("exampleServer", ServerArgs.builder()
.location(exampleResourceGroup.location())
.resourceGroupName(exampleResourceGroup.name())
.skuName("B_Gen5_2")
.storageMb(51200)
.backupRetentionDays(7)
.geoRedundantBackupEnabled(false)
.administratorLogin("acctestun")
.administratorLoginPassword("H@Sh1CoR3!")
.version("10.2")
.sslEnforcementEnabled(true)
.build());
var exampleDatabase = new Database("exampleDatabase", DatabaseArgs.builder()
.resourceGroupName(exampleResourceGroup.name())
.serverName(exampleServer.name())
.charset("utf8mb4")
.collation("utf8mb4_unicode_520_ci")
.build());
}
}

Import

MariaDB Database's can be imported using the resource id, e.g.

$ pulumi import azure:mariadb/database:Database database1 /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mygroup1/providers/Microsoft.DBforMariaDB/servers/server1/databases/database1

Constructors

Link copied to clipboard
fun DatabaseArgs(charset: Output<String>? = null, collation: Output<String>? = null, name: Output<String>? = null, resourceGroupName: Output<String>? = null, serverName: Output<String>? = null)

Functions

Link copied to clipboard
open override fun toJava(): DatabaseArgs

Properties

Link copied to clipboard
val charset: Output<String>? = null

Specifies the Charset for the MariaDB Database, which needs to be a valid MariaDB Charset. Changing this forces a new resource to be created.

Link copied to clipboard
val collation: Output<String>? = null

Specifies the Collation for the MariaDB Database, which needs to be a valid MariaDB Collation. Changing this forces a new resource to be created.

Link copied to clipboard
val name: Output<String>? = null

Specifies the name of the MariaDB Database, which needs to be a valid MariaDB identifier. Changing this forces a new resource to be created.

Link copied to clipboard
val resourceGroupName: Output<String>? = null

The name of the resource group in which the MariaDB Server exists. Changing this forces a new resource to be created.

Link copied to clipboard
val serverName: Output<String>? = null

Specifies the name of the MariaDB Server. Changing this forces a new resource to be created.