Github action for deploying a new version of an html block to metablock cloud.
It is a docker action wrapping metablock ship from the
metablock python client: the bundle
directory of a static site is zipped and shipped to the block, in either the
stage or prod environment.
It deploys html blocks only. Other block types are not shipped this way, and block configuration is handled by the sibling metablock-ingress action.
- uses: quantmind/metablock-web@v5
env:
METABLOCK_API_TOKEN: ${{ secrets.METABLOCK_API_TOKEN }}
with:
block: my-block-id
org: my-org-id
env: prod
bundle: dist- token: Metablock API token, you need to create one on the metablock admin. Alternatively set the
METABLOCK_API_TOKENenvironment variable. - block: Metablock Block ID. Alternatively set the
METABLOCK_BLOCK_IDenvironment variable. - org: Metablock organization id the request acts within. Alternatively set the
METABLOCK_ORG_IDenvironment variable. Required by the API for org-owned blocks. - bundle: filesystem location of the bundle to deploy, defaults to
./dist. - env: environment to deploy to, either
stageorprod, defaults tostage. Alternatively set theMETABLOCK_ENVenvironment variable. - name: optional deployment name. Alternatively set the
METABLOCK_NAMEenvironment variable.
Check the build.yml manifest file for an
example where pushes to a branch are deployed to stage and a merge to main
to prod.
Bump VERSION, add the matching section to
docs/release-notes.md and run make release — see
release.instructions.md.