Skip to content

[Amplify] Build previews only if there are changes in the docs folder#531

Merged
dgarcia360 merged 2 commits intoscylladb:masterfrom
dgarcia360:limit-previews-docs-folder
Aug 5, 2022
Merged

[Amplify] Build previews only if there are changes in the docs folder#531
dgarcia360 merged 2 commits intoscylladb:masterfrom
dgarcia360:limit-previews-docs-folder

Conversation

@dgarcia360
Copy link
Copy Markdown
Collaborator

@dgarcia360 dgarcia360 commented Jul 26, 2022

Closes #477

Adds instructions to trigger pull requests previews only when there are updates within the docs/ folder.

How it works

The workflow provisions an instance and checks if there are differences between the docs folder of the pull-request and the one in the master branch. If not, skips the build and publication steps.

Limitations

  • The workflow still runs to provision the instance and make the diff, but takes 1:40 minutes instead of 4:30 minutes in the scylla/scylla-docs project.

image

  • AWS Amplify posts a message on the GitHub issue, even if the build & deploy process is not triggered:

image

image

Unfortunately, the tool does not offer an option to disable this message. However, we can open an issue on the amplify repo, hoping AWS adds this option in the future or try to delete the message with a custom GitHub Action: #540

Next steps

@dgarcia360 dgarcia360 changed the title limit preview docs folder [Amplify] Build previews only if there are changes in the docs folder Jul 26, 2022
Copy link
Copy Markdown
Collaborator

@annastuchlik annastuchlik left a comment

Choose a reason for hiding this comment

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

LGTM

@dgarcia360 dgarcia360 merged commit a53f4c1 into scylladb:master Aug 5, 2022
@dgarcia360 dgarcia360 deleted the limit-previews-docs-folder branch August 5, 2022 10:43
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.

[Amplify] Build previews only if there are changes in the docs folder

2 participants