Back to Flyway

Flyway Token Setting

documentation/Reference/Configuration/Flyway Namespace/Flyway Token Setting.md

latest1.3 KB
Original Source

Description

A personal access token (PAT) to be used in conjunction with the email configuration parameter. This is used to license Flyway to access Teams or Enterprise features.

You should treat the token like a password and it should not be stored directly in your code repository. Use of a secrets manager or environment variable are much safer solutions.

Type

String

Default

<i>none</i>

Usage

Flyway Desktop

Not needed in conjunction with Flyway Desktop as Flyway Desktop will handle auth.

Command-line

bash
./flyway -email="[email protected]" -token="1234ABCD"

TOML

properties
[flyway]
email = "[email protected]"
token = "1234ABCD"

Environment Variable

properties
[email protected]
FLYWAY_TOKEN=1234ABCD

Maven

xml
<configuration>
  <pluginConfiguration>
    <email>[email protected]</email>
    <token>1234ABCD</token>
  </pluginConfiguration>
</configuration>

API

java
Flyway flyway = Flyway.configure().load();
flyway.getConfigurationExtension(PATTokenConfigurationExtension.class)
        .setEmail("[email protected]");
flyway.getConfigurationExtension(PATTokenConfigurationExtension.class)
        .setToken("1234ABCD");