create

Note: This is a Liquibase Pro feature, so you need a Liquibase Pro License Key to use it.

The create subcommand allows you to create a new YAML checks package file. Learn more about Checks packages here: Quality Checks Packages. It is available in Liquibase 4.25.0 and later.

Uses

Using the create subcommand alongside the checks command creates a new yaml checks package file. This checks package file contains any Quality Check you would like to include so that you can run a bundle of checks at once rather than one at a time.

Note: To view a list of available checks, run liquibase checks show.

Syntax

  1. To create a checks package, you must have at least one checks settings file. You can create one by running any quality check command and following the prompt instructions:
  2. liquibase checks show

    When successful, Liquibase displays the following message along with the output of the command you ran:

    liquibase.checks-settings.conf successfully created!
  3. Run the checks create command to create a new YAML checks package file. For example:
  4. liquibase checks create --package-contents=liquibase.checks-settings.conf --package-name=liquibase.package.conf --package-file=security-checks.pkg

    This results in:

    • A package file called security-checks.pkg
    • A package object inside the file called liquibase.package.conf
    • The contents of the package object, a checks settings file called liquibase.checks-settings.conf.

Parameters

Global parameters

Attribute Definition Requirement

--license-key=<string>

Your Liquibase Pro license key

Required

Command parameters

Attribute Description Requirement

--package-name=<string>

The name of the checks package object inside the file to be created.

Required

--package-contents=<string>

The file(s) or directory to include in the checks package object

Required

--package-file=<string>

The file name of the YAML file to create. Default: liquibase.checks-package.yaml

Optional

Global parameters

Attribute Definition Requirement

globalArgs: { license-key: "<string>" }

Your Liquibase Pro license key

Required

Command parameters

Attribute Description Requirement

cmdArgs: { package-name: "<string>" }

The name of the checks package object inside the file to be created.

Required

cmdArgs: { package-contents: "<string>" }

The file(s) or directory to include in the checks package object

Required

cmdArgs: { package-file: "<string>" }

The file name of the YAML file to create. Default: liquibase.checks-package.yaml

Optional

Global parameters

Attribute Definition Requirement

liquibase.licenseKey: <string>

Your Liquibase Pro license key

Required

Command parameters

Attribute Description Requirement

liquibase.command.packageName: <string>

liquibase.command.<cmdName>.packageName: <string>

The name of the checks package object inside the file to be created.

Required

liquibase.command.packageContents: <string>

liquibase.command.<cmdName>.packageContents: <string>

The file(s) or directory to include in the checks package object

Required

liquibase.command.packageFile: <string>

liquibase.command.<cmdName>.packageFile: <string>

The file name of the YAML file to create. Default: liquibase.checks-package.yaml

Optional

Global parameters

Attribute Definition Requirement

JAVA_OPTS=-Dliquibase.licenseKey=<string>

Your Liquibase Pro license key

Required

Command parameters

Attribute Description Requirement

JAVA_OPTS=-Dliquibase.command.packageName=<string>

JAVA_OPTS=-Dliquibase.command.<cmdName>.packageName=<string>

The name of the checks package object inside the file to be created.

Required

JAVA_OPTS=-Dliquibase.command.packageContents=<string>

JAVA_OPTS=-Dliquibase.command.<cmdName>.packageContents=<string>

The file(s) or directory to include in the checks package object

Required

JAVA_OPTS=-Dliquibase.command.packageFile=<string>

JAVA_OPTS=-Dliquibase.command.<cmdName>.packageFile=<string>

The file name of the YAML file to create. Default: liquibase.checks-package.yaml

Optional

Global parameters

Attribute Definition Requirement

LIQUIBASE_LICENSE_KEY=<string>

Your Liquibase Pro license key

Required

Command parameters

Attribute Description Requirement

LIQUIBASE_COMMAND_PACKAGE_NAME=<string>

LIQUIBASE_COMMAND_<CMDNAME>_PACKAGE_NAME=<string>

The name of the checks package object inside the file to be created.

Required

LIQUIBASE_COMMAND_PACKAGE_CONTENTS=<string>

LIQUIBASE_COMMAND_<CMDNAME>_PACKAGE_CONTENTS=<string>

The file(s) or directory to include in the checks package object

Required

LIQUIBASE_COMMAND_PACKAGE_FILE=<string>

LIQUIBASE_COMMAND_<CMDNAME>_PACKAGE_FILE=<string>

The file name of the YAML file to create. Default: liquibase.checks-package.yaml

Optional

Output

INFO: SUCCESS! 'security-checks.pkg' was created, and the specified file at 'liquibase.checks-settings.conf' were added to new checks package named 'liquibase.package.conf'. Use this checks package with 'liquibase checks show --checks-settings-file=security-checks.pkg --checks-packages=liquibase.package.conf'
Liquibase command 'checks create' was executed successfully.

Related links