-
Notifications
You must be signed in to change notification settings - Fork 60
Improve examplary YAML file and correct typos #83
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
Conversation
Thanks a lot @jakobarendt . Is this permissions setting to be required in the YAML workflow file new ? I was sure this was working without it. Can we link to a blog post or related doc on this ? This is Github specific and it would help to send users to the correct reference so that they know what they are configuring. Thank you |
Yes, to my knowledge, a permission is required when using the Quarto To be honest, I have not (yet) published anything on the topic. I basically discovered it while debugging unsuccessful workflow runs during the setup of my master's thesis repo. The corresponding log file of the run, after which I accounted for all other potential sources of failure, gave (at least to me) an indication in L62 and L63 that it is an issue of unsufficient permissions:
To me, this need for a write permission also seems intuitive as the workflow run needs to render and commit the content files to the |
@mcanouil and @t-kalinowski might be good reviewers for my suggestions since they contributed to the guide page about publishing with GitHub pages. On the guide page, the examplary YAMLs already contain the changes that I propose. @mcanouil wrote a paragraph about setting permissions in the repository's settings and @t-kalinowski specifically added the permissions to the examplary YAMLs. |
To check more thoroughly the required permissions, we can use https://github.com/GitHubSecurityLab/actions-permissions. To note, Quarto documentation on publishing to GitHub Pages needs some update, see: |
The related "epic": |
@jakobarendt we'll review this in parallel to as we'll work on the documentation to have consistency. |
Thank you |
For GitHub pages, the
publish
action needs write access to the contents of the repository. This can be achieved via changing the settings for actions workflows in the repository's settings from the default read only to write. However, this change in settings then holds for all workflow YAML-files of the repository.Alternatively, one can set such permissions for each job in the workflow YAML-files individually. For the examplary YAML file, I propose this approach, as it prevents giving permissions to other GitHub Actions workflow jobs unintendedly. Additionally, I modify the documentation to account for the change in the examplary workflow YAML-file.
The second commit records some changes to the main README.md that correct typos and improve relative links.
Cheers,
Jakob