-
Notifications
You must be signed in to change notification settings - Fork 9
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 upload_build_to_apps_cdn
action
#636
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The CDN-specific parameters were never supposed to be wrapped inside an `attrs` array
To avoid confusion, as those request parameters are top-level parameters for our customized API CDN endpoint, not sub-keys supposed to be nested under the `attrs` parameter of the official WP API
- Remove unnecessary comments - Reduce valid post status values - Improve description to provide valid values for parameters
Generated by 🚫 Danger |
AliSoftware
commented
Mar 4, 2025
lib/fastlane/plugin/wpmreleasetoolkit/actions/common/upload_build_to_apps_cdn.rb
Outdated
Show resolved
Hide resolved
Recently added to the API
Amongst other things, this allows to also return the post_id, and the post page URL (aka the page presenting the build we just uploaded).
dangermattic
reviewed
Mar 6, 2025
lib/fastlane/plugin/wpmreleasetoolkit/actions/common/upload_build_to_apps_cdn.rb
Outdated
Show resolved
Hide resolved
beb2940
to
2e22fcf
Compare
twstokes
reviewed
Mar 10, 2025
lib/fastlane/plugin/wpmreleasetoolkit/actions/common/upload_build_to_apps_cdn.rb
Outdated
Show resolved
Hide resolved
lib/fastlane/plugin/wpmreleasetoolkit/actions/common/upload_build_to_apps_cdn.rb
Outdated
Show resolved
Hide resolved
lib/fastlane/plugin/wpmreleasetoolkit/actions/common/upload_build_to_apps_cdn.rb
Outdated
Show resolved
Hide resolved
lib/fastlane/plugin/wpmreleasetoolkit/actions/common/upload_build_to_apps_cdn.rb
Outdated
Show resolved
Hide resolved
lib/fastlane/plugin/wpmreleasetoolkit/actions/common/upload_build_to_apps_cdn.rb
Show resolved
Hide resolved
Co-authored-by: Tanner Stokes <[email protected]>
twstokes
approved these changes
Mar 11, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM @AliSoftware - testing succeeded and produced this page. 🚀
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What does it do?
Implements https://github.com/Automattic/apps-infra-plans/issues/189
This adds a new
upload_build_to_apps_cdn
action in ourrelease-toolkit
to allow us to easily upload builds to our Apps CDN, as documented in PCYsg-15tP-p2Manual Testing
In addition to the unit tests, this can also be tested manually (as a kind of manual integration test) with the following steps:
demo.png.zip
, we don't really need a real binary/build in practice for this testing.12546
cd
into this repo and checked out this PR's branch, call the following command—replacing the API token and file path with the appropriate valuesThe build available in pgbvBD-8l-p2 is an example of me testing the action with the above manual steps.
Alternatively, you can test the same by calling the action directly from a
Fastfile
of a test project (e.g. AutoProxxy):Gemfile
to pointfastlane-plugin-wpmreleasetoolkit
to this PR's branch instead of a versionbundle install
Fastfile
to either add a dummy test lane that'd call the new action, or to replace the existing call toappcenter_upload
in an existing lane with the call to the newupload_build_to_apps_cdn
action, providing the proper arguments. Be sure to not provide the api token as part of the parameters, since it's a secretexport WPCOM_API_TOKEN={copy api token from secret store here}
in your Terminal, then runbundle exec fastlane {yourtestlane}
to test the action in… action.Checklist before requesting a review
bundle exec rubocop
to test for code style violations and recommendations.specs/*_spec.rb
) if applicable.bundle exec rspec
to run the whole test suite and ensure all your tests pass.CHANGELOG.md
file to describe your changes under the appropriate existing###
subsection of the existing## Trunk
section.If applicable, add an entry in theMIGRATION.md
file to describe how the changes will affect the migration from the previous major version and what the clients will need to change and consider.