Skip to content
You're viewing an older version of this GitHub Action. Do you want to see the latest version instead?
check

GitHub Action

ZEIT Now Deployment

v1

ZEIT Now Deployment

check

ZEIT Now Deployment

This action make a deployment with github actions instead of ZEIT Now builder

Installation

Copy and paste the following snippet into your .yml file.

              

- name: ZEIT Now Deployment

uses: amondnet/now-deployment@v1

Learn more about this action in amondnet/now-deployment

Choose a version

ZEIT Now Deployment

ZEIT Now is a cloud platform for static sites and Serverless Functions

This action make a deployment with github actions instead of ZEIT Now builder.

  • Deploy to ZEIT now.
  • Comment on pull request.
  • Comment on commit.
  • Create Deployment on github.

Result

preview

pull request example

commit

Inputs

zeit-token

required ZEIT now token.

zeit-team-id

This is required if your deployment is made on team project. example: team_asdf1234

github-token

required This is required to comment on pull request.

now-args

This is optional args for now cli. Example: --prod

Outputs

preview-url

The url of deployment preview.

Example Usage

{
  "name": "zeit-now-deployment",
  "version": 2,
  "scope": "amond",
  "public": false,
  "github": {
    "enabled": false
  },
  "builds": [
    { "src": "./public/**", "use": "@now/static" }
  ],
  "routes": [
    { "src": "/(.*)", "dest": "public/$1" }
  ]
}
  • This is a complete .github/workflow/deploy.yml example.
name: deploy website
on: [pull_request]
jobs:
  deploy:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v1
      - uses: amondnet/now-deployment@v1
        with:
          github-token: ${{ secrets.GITHUB_TOKEN }}
          zeit-token: ${{ secrets.ZEIT_TOKEN }}
          zeit-team-id: team_XXXXXXXXXXX
          now-args: '--prod'