Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright 2020 Quantmind
Copyright 2025 Quantmind

Permission to use, copy, modify, and/or distribute this software for any purpose
with or without fee is hereby granted, provided that the above copyright notice
Expand Down
4 changes: 4 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ inputs:
env:
description: "Metablock environment - can be set via the METABLOCK_ENV env variable"
default: "stage"
name:
description: "Optional deployment name - can be set via the METABLOCK_NAME env variable"
runs:
using: "docker"
image: "Dockerfile"
Expand All @@ -24,3 +26,5 @@ runs:
- ${{ inputs.block }}
- "--env"
- ${{ inputs.env }}
- "--name"
- ${{ inputs.name }}
8 changes: 4 additions & 4 deletions readme.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
# Metablock Action

[![build](https://github.com/quantmind/metablock-action/workflows/build/badge.svg)](https://github.com/quantmind/metablock-action/actions?query=workflow%3Abuild)
[![test](https://github.com/quantmind/metablock-action/workflows/test/badge.svg)](https://github.com/quantmind/metablock-action/actions?query=workflow%3Atest)

Deploy a new version of an html block to metablock cloud.

## Inputs

- **token**: Metablock API token, you need to create one on the metablock admin. Alternatively set the `METABLOCK_API_TOKEN` environment variable.
- **block**: Metablock Block ID. Alternatively set the `METABLOCK_BLOCK_ID` environment variable.
- **bundle**: bundle locatiuon. Alternatively set the `BUNDLE_LOCATION` environment variable, (it defaults to `./dist` if not provided)
- **env**: environment where to deploy, either `stage` or `prod`, (it defaults to `stage` if not provided)
- **bundle**: bundle location. Alternatively set the `BUNDLE_LOCATION` environment variable, (it defaults to `./dist` if not provided)
- **env**: environment where to deploy, either `stage` or `prod`, (it defaults to `stage` if not provided). Can be set via `METABLOCK_ENV` environment variable.
- **name**: optional deployment name

Check the [test.yml](./.github/workflows/test.yml) manifest file for an example where pull requests to master are deployed to `stage` and a merge to `master` to `prod`.
Check the [build.yml](./.github/workflows/build.yml) manifest file for an example where pull requests to master are deployed to `stage` and a merge to `master` to `prod`.