You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This parameter simply tells Semaphore to cancel any running pipeline if a new push is done.
This can avoid having newer pushes wait for available resources to be run through the pipeline.
What to do
Here are two options you can pick from.
Auto cancel for all branches
This one is simple. You only need to had the following entry at the root of the semaphore.yml file. Just after the agent block.
auto_cancel:
queued:
when: "true" # enable auto-cancel for branches, tags and pull-requests
Master and releases branches might require to be built for every push or merge so that releasables are available.
To have such a conditional you can use the following added at the root of the semaphore.yml file.
You only need to had the following entry at the root of the semaphore.yml file. Just after the agent block.
There are cases where you might not want that included, and that's fine. Keep in mind that even
if you don't mind every push waiting it also potentially means other pushes from other team members are waiting for resources.
"...with great power there must also come -- great responsibility!"
The text was updated successfully, but these errors were encountered:
Following some usage statistics we have dug into some configuration tweaks for Semaphore 2.
We noticed that this project has no
auto_cancel
option set for its pipeline.This parameter simply tells Semaphore to cancel any running pipeline if a new push is done.
This can avoid having newer pushes wait for available resources to be run through the pipeline.
What to do
Here are two options you can pick from.
Auto cancel for all branches
This one is simple. You only need to had the following entry at the root of the
semaphore.yml
file. Just after theagent
block.Do like @Flokkie97 : https://github.com/nedap/hera/blob/7b81b51e4abb6603cad7d1de8e8ba2bd3735a4da/.semaphore/semaphore.yml#L17-L19
Auto cancel but not for master
Master and releases branches might require to be built for every push or merge so that releasables are available.
To have such a conditional you can use the following added at the root of the semaphore.yml file.
You only need to had the following entry at the root of the
semaphore.yml
file. Just after theagent
block.Do like @Flokkie97 (yes, he changed his mind) : https://github.com/nedap/hera/blob/master/.semaphore/semaphore.yml#L17-L19
Wrap up
There are cases where you might not want that included, and that's fine. Keep in mind that even
if you don't mind every push waiting it also potentially means other pushes from other team members are waiting for resources.
The text was updated successfully, but these errors were encountered: