Skip to content

Releases: Azure/draft

v0.0.28

14 Feb 21:28
3a9a1b2
Compare
Choose a tag to compare

BREAKING changes to IMAGE variable

Added

  • New, optional disablePrompt property on Builder Variables in draft config (#180):
    • Default Value: false
    • Variables with disablePrompt: true will not be prompted for when running draft interactive commands
    • Variables with disablePrompt: true can still be supplied via flags (draft create --var TAG=latest) or draft config files
    • Example Usage:
        # draft.yaml
        variables:
        - name: "TAG"
          description: "the tag of the image to be built"
          disablePrompt: true #  New optional field that is used to disable the prompt for this variable
        ...
      
  • For all draft substitutions, draft will now error if unsubstituted variables are found in the final output (#175)

Changed

  • BREAKING the IMAGE variable no longer can include an image tag. The TAG variable should be used instead (#176)
  • BREAKING the imageKey variable on the helm deployment type has been renamed to image to be consistent with the supplied starter workflows (#176)
    • Re-running draft create will update existing files to follow the new convention

v0.0.27

09 Dec 20:14
98c4848
Compare
Choose a tag to compare

Added

  • New displayName and variables.exampeValues properties in draft.yaml
      # draft.yaml
      language: swift
      displayName: Swift # Add a display name for the selected resource (language/deploymentType/addon)
      variables:
      - name: "VERSION"
        description: "the version of swift used by the application"
        exampleValues: ["5.5","5.4"] #  New optional field that is used to populate draft info, and which could be used in the cli for suggestions in the future.
        variableDefaults:
      - name: "VERSION"
        value: 5.5
  • Added --dry-run and --dry-run-file flags to create command
    • --dry-run enables dry run mode in which no files are written to disk, prints the dry run summary to stdout
    • --dry-run-file specifies a file to write the dry run summary in json format (requires --dry-run flag)
    # Example dry run output
    {
      "variables": {
        "APPNAME": "testapp",
        "BUILDERVERSION": "null",
        "IMAGENAME": "testapp",
        "LANGUAGE": "gomodule",  # Note that this variable is in addition to the draft config variables
        "NAMESPACE": "default",
        "PORT": "1323",
        "SERVICEPORT": "80",
        "VERSION": "1.18"
      },
      "filesToWrite": [
        "langtest/.dockerignore",
        "langtest/Dockerfile",
        "langtest/charts/.helmignore",
        "langtest/charts/Chart.yaml",
        "langtest/charts/production.yaml",
        "langtest/charts/templates/_helpers.tpl",
        "langtest/charts/templates/deployment.yaml",
        "langtest/charts/templates/namespace.yaml",
        "langtest/charts/templates/service.yaml",
        "langtest/charts/values.yaml"
      ]
    }

Changed

  • BREAKING - info command output format includes additional information for supported languages with the following format changes:
    • keys are now camelCase
    • supportedLanguages is now an array of objects, enriched with displayName and exampleValues
    # Example of the new info command output format
    {
      # keys are now camelCase, so supported_languages is now supportedLanguages
      "supportedLanguages": [
        {
          "name": "javascript",
          "displayName": "JavaScript", # new field
          "exampleValues": {           # new field
            "VERSION": [
              "14.0",
              "16.0"
            ]
          }
        },
        ...
      ],
     # keys are now camelCase, so supported_deployment_types is now supportedDeploymentTypes
     "supportedDeploymentTypes": [
        "helm",
        ...
      ]
    }

v0.0.26

17 Nov 06:18
7a5311e
Compare
Choose a tag to compare

Added

  • The new draft info command from #157 prints supported language and field information in json format.
  • An integration test was added for the installation shell script to better ensure that the script works as expected.

Fixed

  • File path output for root locations had a bug with string-formatted paths. The path.Join method has been substituted to fix this.

Changed

  • Remaining uses of the viper library have been migrated to gopkg.in/yaml.v3 for consistency.
  • Unused files in the web package have been removed.
  • Minor reorganization across the config and addons packages to reduce the number of exported functions and types.

v0.0.25

05 Oct 18:36
eb7e383
Compare
Choose a tag to compare
  • add IMAGENAME and NAMESPACE variables to the deployment to allow deeper customization

    • The NAMESPACE defaults to the default namespace

    • The IMAGENAME defaults to the APPNAME valu e

  • Add new referenceVar field to variableDefaults type

    • The value of the referenceVar input will be copied as the default
    • A referenceVar has higher precedence when defaulting compared to a static variableDefault value field
    • variableDefaults are processed in order, so a variableDefault can only use a referenceVar that is listed before it in the draft.yaml variables
# valid draft.yaml
variables:       # variables are named in the order they will be prompted
  - name: "FIRST"
    description: "the first variable"
  - name: "SECOND"
    description: "the second variable"
variableDefaults:
  - name: "SECOND"       # "default the value of SECOND  to the value of FIRST"
    referenceVar: "FIRST" # valid config since SECOND comes after FIRST in the `variables` section


# INVALID draft.yaml
variables: 
  - name: "FIRST"
    description: "the first variable"
  - name: "SECOND"
    description: "the second variable"
variableDefaults:
  - name: "FIRST"                  # "default the value of FIRST  to the value of SECOND"
    referenceVar: "SECOND" # SECOND will always be empty when FIRST is being prompted, so the default will be the empty string

v0.0.24

28 Sep 19:19
bb19713
Compare
Choose a tag to compare

add --variable flag to draft update command

builderVariables can be supplied to the update command using the new --variable flag
this allows non-interactive use of the update command

added integration tests for update command for webapp_routing addon that creates an ingress using the non-interactive flags mode

v0.0.23

24 Aug 17:49
55390d1
Compare
Choose a tag to compare

refactored to include the parametric update command that allows arbitrary addon template/CRD support
draft update -a addon_name

moved templates embedded filesystems to use a go import path within the template module for easy importing draft as a dependency

v0.0.22

14 Jul 17:42
259023d
Compare
Choose a tag to compare
fixing dockerfile/deployment only creation with skip-file-detection (…

v0.0.21

15 Jun 21:21
b7fa007
Compare
Choose a tag to compare
Split stdout and stderr in logrus (#108)

* split stdout and stderr

* delete extra line

v0.0.20

24 May 07:27
a0a2852
Compare
Choose a tag to compare
fixed manifest image pull + kustomize selector (#93)

* fix manifest image pull

* fixing kustomize too

v0.0.19

24 May 01:26
4ce5792
Compare
Choose a tag to compare
update starter workflows (#91)

Co-authored-by: imiller31 <imiller31@users.noreply.github.com>