Skip to content

Conversation

@gjtorikian
Copy link

It can be useful to allow for the deployment ID to be provide as input, in case a deployment was not triggered by a deployment event. For example, if I wanted to autodeploy on every push to production, I could create a Deployment via the API like this:

name: Deploy to Heroku

on:
  push:
    branches:
      - production

jobs:
  deploy:
    name: Heroku Deploy
    runs-on: ubuntu-latest
    steps:
      - name: Check out this repo
        uses: actions/checkout@v2

      - uses: altinukshini/deployment-action@releases/v1
        name: Create GitHub deployment
        if: github.event_name == 'push'
        id: deployment
        with:
          token: "${{ github.token }}"
          environment: production

      - name: "deployment pending"
        uses: "deliverybot/deployment-status@v1"
        with:
          state: "pending"
          token: "${{ github.token }}"
          deployment_id: ${{ steps.deployment.outputs.deployment_id }}

@arobert-attraqt
Copy link

Is it possible to allow this? It would be useful for deployments that are triggered outside the deployment context.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants