# Detect a deploy

**URL:** https://discourse.nodered.org/t/detect-a-deploy/58260
**Category:** General
**Created:** [13 February 2022 13:07 UTC](https://discourse.nodered.org/t/detect-a-deploy/58260 "2022-02-13T13:07:16Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![biros](https://avatars.discourse-cdn.com/v4/letter/b/e47c2d/32.png) [@biros](https://discourse.nodered.org/u/biros)
#### Post date: [13 February 2022 13:07 UTC](https://discourse.nodered.org/t/detect-a-deploy/58260/1 "2022-02-13T13:07:16Z")

</div>

hello,  
is there a method to detect (trigger a node or change a variable, etc) whenever the deploy is pressed?  
i am using "modified nodes" option, but i'd like to work with that event in a different node.

---

<div class="post-metadata">

### Author: ![zenofmud](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/zenofmud/32/316_2.png) [@zenofmud](https://discourse.nodered.org/u/zenofmud)
#### Post date: [13 February 2022 13:43 UTC](https://discourse.nodered.org/t/detect-a-deploy/58260/2 "2022-02-13T13:43:10Z")

</div>

Look at the options in the `injects node

---

<div class="post-metadata">

### Author: ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)
#### Post date: [13 February 2022 14:26 UTC](https://discourse.nodered.org/t/detect-a-deploy/58260/3 "2022-02-13T14:26:04Z")

</div>

I think that @biros means that he wants to trigger a message any time that any Deploy occurs, not just when the Inject node is deployed.

---

<div class="post-metadata">

### Author: ![biros](https://avatars.discourse-cdn.com/v4/letter/b/e47c2d/32.png) [@biros](https://discourse.nodered.org/u/biros)
#### Post date: [13 February 2022 14:48 UTC](https://discourse.nodered.org/t/detect-a-deploy/58260/4 "2022-02-13T14:48:00Z")

</div>

Thanks @Colin, that's exactly what I'd like to do. The inject node's "Inject once" feature does not cover the scenario when only the modified node(s) are deployed (and that inject node was already deployed in a previous cycle).

---

<div class="post-metadata">

### Author: ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)
#### Post date: [13 February 2022 15:00 UTC](https://discourse.nodered.org/t/detect-a-deploy/58260/5 "2022-02-13T15:00:18Z")

</div>

I have to ask why you want to do that.

---

<div class="post-metadata">

### Author: ![biros](https://avatars.discourse-cdn.com/v4/letter/b/e47c2d/32.png) [@biros](https://discourse.nodered.org/u/biros)
#### Post date: [13 February 2022 15:08 UTC](https://discourse.nodered.org/t/detect-a-deploy/58260/6 "2022-02-13T15:08:08Z")

</div>

node-red-contrib-generic-ble starts scanning every time I deploy something, even if the deployed nodes have nothing to do with it. The scan stops after a few minutes, but I'd like to inject a "stop scan" command right after something is deployed, to stop the scanning before a 3 seconds mark (energy efficiency and other radio related "issues").

---

<div class="post-metadata">

### Author: ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)
#### Post date: [13 February 2022 15:10 UTC](https://discourse.nodered.org/t/detect-a-deploy/58260/7 "2022-02-13T15:10:42Z")

</div>

So you are trying to work around an apparent bug in the ble node. Have you reported it?  
Sorry, I don't know how to do what you want.

---

<div class="post-metadata">

### Author: ![biros](https://avatars.discourse-cdn.com/v4/letter/b/e47c2d/32.png) [@biros](https://discourse.nodered.org/u/biros)
#### Post date: [13 February 2022 15:28 UTC](https://discourse.nodered.org/t/detect-a-deploy/58260/8 "2022-02-13T15:28:16Z")

</div>

yes, thats what i'm trying to do, didn't approached the thing as a bug, just wanted to do something with it.  
no probs, thanks anyway.

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)
#### Post date: [14 April 2022 15:28 UTC](https://discourse.nodered.org/t/detect-a-deploy/58260/9 "2022-04-14T15:28:32Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
