Giter Club home page Giter Club logo

Comments (7)

tommybo-entur avatar tommybo-entur commented on July 22, 2024 2

A little late response, but it's just like any other job in a workflow:

workflows:
  "Verify component":
    jobs:
      -test
      -integration-test
      - slack/approval-notification:
          webhook: https://MYHOOK
          message: "Deploy pending approval: https://circleci.com/workflow-run/$CIRCLE_WORKFLOW_ID"
          requires:
            - test
            - integration-test

from circleci-orbs.

jkzilla avatar jkzilla commented on July 22, 2024 1

Hi @stig - I just tried this out yesterday with the hello-build orb - Can you post your config minus any sensitive information such as slack user ID? Not sure if this helps but posting just in case:


orbs:
    hello: circleci/[email protected] # uses the circleci/buildpack-deps Docker image
    slack: circleci/[email protected]
workflows:
    "Hello Workflow":
        jobs:
          - hello/hello-build
          - slack/approval-notification:
              mentions: 'U<this is your slack user ID>M'
              webhook: $SLACK_WEBHOOK```

from circleci-orbs.

stig avatar stig commented on July 22, 2024

@jkzilla thank you for your comment. I can see how that works, because neither of the two jobs depends on anything. I want to make the approval notification only trigger if hello-build passes, and I cannot see how to do that.

from circleci-orbs.

stig avatar stig commented on July 22, 2024

@tommybo-entur thank you. I'll give that a try. It is not at all clear from my reading of the documentation that it will work, because requires: is not listed as a key you can use, and there are no examples in the documentation. (At least there were none when I created this ticket 😄 )

from circleci-orbs.

felicianotech avatar felicianotech commented on July 22, 2024

Hi @stig,

@tommybo-entur example should work. requires is a standard CircleCI workflows key. It's not specific to orbs but to any CircleCI job. https://circleci.com/docs/2.0/configuration-reference/#workflows

Could you let us know if it works for you?

from circleci-orbs.

stig avatar stig commented on July 22, 2024

@felicianotech it does work! 🎉

Could this be documented? It's not clear to me that it would work, since slack/status and slack/notify jobs/commands do not accept standard arguments (like name:, command:, when: etc.)

from circleci-orbs.

KyleTryon avatar KyleTryon commented on July 22, 2024

Hello all,

Closing this old issue as the slack orb can be found here: https://github.com/CircleCI-Public/slack-orb/issues

We will soon be considering large scale changes to the slack orb to increase the amount of customizability and improving the documentation. More to come soon.

from circleci-orbs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.