{
  "repo": "tidbcloud/ecosystem-service",
  "binary": "migrate",
  "binary_path": "cmd/migrate/main.go",
  "dependencies": {
    "CLI RunMigrate": {
      "infrastructure": {
        "docker": {
          "conditions": [
            "Always"
          ],
          "operations": [
            {
              "operation": "Start a temporary mysql:5.7 container for schema migration rehearsal",
              "trigger": "migrate CLI invocation",
              "implementation": "dockertest.NewPool(); pool.RunWithOptions(...)"
            }
          ]
        },
        "mysql": {
          "conditions": [
            "Always"
          ],
          "operations": [
            {
              "operation": "Connect to temporary MySQL and run migration SQL generation",
              "trigger": "After dockertest container is ready",
              "implementation": "gormutil.Connect(connCfg); migrate.NewMigrator(db)"
            }
          ]
        }
      },
      "services": []
    }
  }
}
