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

Add automated Schema File publish action #1858

Conversation

tigrannajaryan
Copy link
Member

The action should be triggered manually after every spec release
and will copy/update schema files from this repository to the
website repository so that they become available publicly.

The publish-schemas action after manual triggering will create a PR
in https://github.com/open-telemetry/opentelemetry.io repo, and the
PR needs to be approved and merged manually.

This is similar to how we publish doc updates from language repos
to the website repo.

Resolves open-telemetry/opentelemetry.io#577
Resolves #1693

@tigrannajaryan
Copy link
Member Author

@open-telemetry/docs-approvers please review.

The action should be triggered manually after every spec release
and will copy/update schema files from this repository to the
website repository so that they become available publicly.

The publish-schemas action after manual triggering will create a PR
in https://github.com/open-telemetry/opentelemetry.io repo, and the
PR needs to be approved and merged manually.

This is similar to how we publish doc updates from language repos
to the website repo.

Resolves open-telemetry/opentelemetry.io#577
Resolves open-telemetry#1693
@tigrannajaryan tigrannajaryan force-pushed the feature/tigran/schema-publish-action branch from 2af3b9e to 1f37e9c Compare August 10, 2021 12:53
SOURCE_PATH: schemas
run: |
TARGET_DIR=$(mktemp -d)
export GITHUB_TOKEN=$API_TOKEN_GITHUB
Copy link
Member

Choose a reason for hiding this comment

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

@austinlparker are you ok with the token reuse here?

git clone "https://[email protected]/$DESTINATION_REPO.git" "$TARGET_DIR"
rsync -av --delete "$SOURCE_PATH/" "$TARGET_DIR/$DESTINATION_PATH/"
cd "$TARGET_DIR"
git checkout -b docs-$GITHUB_REPOSITORY-$GITHUB_SHA
Copy link
Member

Choose a reason for hiding this comment

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

GITHUB_SHA this is SHA of specs repo, not protos, correct?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, I think so. (This is code is copied from Java repo, I didn't write it, I believe is @austinlparker the author).

@tigrannajaryan tigrannajaryan requested a review from a team August 11, 2021 11:07
@carlosalberto
Copy link
Contributor

@austinlparker Is on paternity leave, so we need to proceed without him. Anybody we could poke for the time being? Maybe @tedsuo ? Else let's just go ahead and merge it.

@carlosalberto
Copy link
Contributor

@SergeyKanzhelev @tigrannajaryan Let's merge this? I think it deserves a run ;)

@github-actions
Copy link

This PR was marked stale due to lack of activity. It will be closed in 7 days.

@github-actions github-actions bot added the Stale label Aug 26, 2021
@tigrannajaryan
Copy link
Member Author

@SergeyKanzhelev @tigrannajaryan Let's merge this? I think it deserves a run ;)

Yes, I think we need to merge it. If anything goes wrong with it I can take a look after it is merged. It needs to be run manually anyway so won't affect CI.

@SergeyKanzhelev
Copy link
Member

Assuming Austin is fine with the token reuse.

@SergeyKanzhelev SergeyKanzhelev merged commit bb9e014 into open-telemetry:main Aug 30, 2021
@tigrannajaryan tigrannajaryan deleted the feature/tigran/schema-publish-action branch August 31, 2021 12:33
carlosalberto pushed a commit to carlosalberto/opentelemetry-specification that referenced this pull request Oct 31, 2024
* Add automated Schema File publish action

The action should be triggered manually after every spec release
and will copy/update schema files from this repository to the
website repository so that they become available publicly.

The publish-schemas action after manual triggering will create a PR
in https://github.com/open-telemetry/opentelemetry.io repo, and the
PR needs to be approved and merged manually.

This is similar to how we publish doc updates from language repos
to the website repo.

Resolves open-telemetry/opentelemetry.io#577
Resolves open-telemetry#1693

* Make branch name and commit message more relevant

Co-authored-by: Sergey Kanzhelev <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
4 participants