PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Sunday, October 9, 2022

[FIXED] When multiple workflows run simultaneously in Git Action, can I make them run one at a time?

 October 09, 2022     continuous-integration, fastlane, github-actions, testflight     No comments   

Issue

I'm building CI/CD using Git Action (uploading to TestFlight) I designed the logic of using FastLane to bring the latest build number and then + 1.

The problem occurs with the latest Build Number when multiple workflow runs simultaneously.

This is because multiple workflows import the same number from TestFlight before the latest Build number is updated.

To do this, I want workflow to run one at a time.

Is there a way?


Solution

You can use Consecutive Workflow Action

jobs:
  consecutiveness:
    runs-on: ubuntu-latest
    steps:
    - uses: mktcode/consecutive-workflow-action@e2e008186aa210faacd68ec30f6ac236f7e2f435
      with:
        token: ${{ secrets.GITHUB_TOKEN }}

  # your other jobs
  something:
    runs-on: ubuntu-latest
    needs: [ consecutiveness ]
    steps:
    # ...

GITHUB_TOKEN is needed to avoid rate limitation issues when performing API calls (to check the previous workflow run). Make sure you read the security note in the repository’s Readme.



Answered By - Krzysztof Madej
Answer Checked By - Senaida (PHPFixing Volunteer)
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © PHPFixing