Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FR-14304 - Trigger Oauth pipeline after publish #1059

Merged
merged 11 commits into from
Nov 26, 2023

Conversation

rotemzif1
Copy link
Contributor

@rotemzif1 rotemzif1 commented Nov 26, 2023

This PR introduces a new workflow for triggering oauth service pipeline of opening a PR that updating frontegg, on our publish flow. (Oauth workflow - https://github.com/frontegg/oauth-service/actions/workflows/update-react-dependency.yaml)

This PR includes 4 files:

  1. Publish.yaml - the actual necessary flow which was fully tested
  2. pre-release - copy-paste of the workflow just for testing on an alpha to make sure that also waiting for npm registery is working ok. It will be removed right after.
  3. push.yaml - Guy asked me to change the version of the scripts
  4. waiting for npm registry - code that was copied from admin box, to make sure that npm has been done publishing the new version before we are trying to bump it in oauth service.

This PR will be pushed the same way to trigger dashboard service as well.

@rotemzif1 rotemzif1 force-pushed the FR-14304-trigger-oauth branch from fff6a97 to 76486b5 Compare November 26, 2023 13:27
Copy link
Contributor

@yuvalotem1 yuvalotem1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Amazing!

@rotemzif1 rotemzif1 merged commit 10cf80e into master Nov 26, 2023
1 check passed
@rotemzif1 rotemzif1 deleted the FR-14304-trigger-oauth branch November 26, 2023 13:45
}

if (!allPackagesIndexed) {
timeout--;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we can improve the timeout logic. I think we can define how many time to run it regardless of the timeout var

@@ -99,6 +99,34 @@ jobs:
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }}
- name : Wait until NPM registry finished indexing the new version
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it should be part of the consumer / run it in parallel with the next pipeline steps - it shouldn't be a blocker.. (unless it's very fast)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Its a great idea, if we go with this direction I suggest we think together how to do it and provide it also in admin box, this is the same logic when we publish and then do something that is holding up until the version is live

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can u add a ticket? in the pipeline effort epic

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.

4 participants