mirror of
https://github.com/matifali/update-coder-template.git
synced 2024-09-20 06:46:04 +08:00
Compare commits
7 commits
e817d90ef0
...
0c62247cae
Author | SHA1 | Date | |
---|---|---|---|
0c62247cae | |||
7819717fc3 | |||
d3f671814f | |||
41bdcde523 | |||
cf7688dc74 | |||
603ab07856 | |||
5a254fcb96 |
|
@ -23,7 +23,6 @@ Update coder templates automatically
|
||||||
| **`dir`** | **Required** The directory of the template that contains `main.tf` file | - |
|
| **`dir`** | **Required** The directory of the template that contains `main.tf` file | - |
|
||||||
| `name` | New version name for the template. | Autogenerated name by Coder |
|
| `name` | New version name for the template. | Autogenerated name by Coder |
|
||||||
| `activate` | Activate the new template version. | `true` |
|
| `activate` | Activate the new template version. | `true` |
|
||||||
| `create` | Creates a new template if it does not exist | `true` |
|
|
||||||
| `message` | Update message (similar to commit messages) | - |
|
| `message` | Update message (similar to commit messages) | - |
|
||||||
| `dry_run` | Dry run mode. | `false` |
|
| `dry_run` | Dry run mode. | `false` |
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
name: Update Coder Template
|
name: Update Coder Template
|
||||||
description: An action to deploy changes to your coder template automatically
|
description: An action to deploy changes to your coder template automatically
|
||||||
author: "Muhammad Atif Ali <matifali@live.com>"
|
author: "Muhammad Atif Ali <me@matifali.dev>"
|
||||||
|
|
||||||
branding:
|
branding:
|
||||||
icon: arrow-up-circle
|
icon: arrow-up-circle
|
||||||
|
@ -30,10 +30,6 @@ inputs:
|
||||||
description: "update message"
|
description: "update message"
|
||||||
required: false
|
required: false
|
||||||
default: "Updated via update-coder-template action"
|
default: "Updated via update-coder-template action"
|
||||||
create:
|
|
||||||
description: "Creates a new template if it does not exist"
|
|
||||||
required: false
|
|
||||||
default: "true"
|
|
||||||
dry_run:
|
dry_run:
|
||||||
description: "Dry run"
|
description: "Dry run"
|
||||||
required: false
|
required: false
|
||||||
|
@ -57,5 +53,4 @@ runs:
|
||||||
CODER_TEMPLATE_VERSION_NAME: ${{ inputs.name }}
|
CODER_TEMPLATE_VERSION_NAME: ${{ inputs.name }}
|
||||||
CODER_TEMPLATE_ACTIVATE: ${{ inputs.activate }}
|
CODER_TEMPLATE_ACTIVATE: ${{ inputs.activate }}
|
||||||
CODER_TEMPLATE_MESSAGE: ${{ inputs.message }}
|
CODER_TEMPLATE_MESSAGE: ${{ inputs.message }}
|
||||||
CODER_TEMPLATE_CREATE: ${{ inputs.create }}
|
|
||||||
CODER_TEMPLATE_DRY_RUN: ${{ inputs.dry_run }}
|
CODER_TEMPLATE_DRY_RUN: ${{ inputs.dry_run }}
|
||||||
|
|
|
@ -19,11 +19,6 @@ if [ -n "${CODER_TEMPLATE_MESSAGE}" ]; then
|
||||||
push_command+=" --message \"${CODER_TEMPLATE_MESSAGE}\""
|
push_command+=" --message \"${CODER_TEMPLATE_MESSAGE}\""
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Append --create flag to the push command if CODER_TEMPLATE_CREATE is true
|
|
||||||
if [ "${CODER_TEMPLATE_CREATE}" = "true" ]; then
|
|
||||||
push_command+=" --create"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Add version to the push command if specified
|
# Add version to the push command if specified
|
||||||
if [ -n "${CODER_TEMPLATE_VERSION_NAME}" ]; then
|
if [ -n "${CODER_TEMPLATE_VERSION_NAME}" ]; then
|
||||||
push_command+=" --name ${CODER_TEMPLATE_VERSION_NAME}"
|
push_command+=" --name ${CODER_TEMPLATE_VERSION_NAME}"
|
||||||
|
|
Loading…
Reference in a new issue