Skip to content

docs: document per-frequency shell script MIME types#6891

Open
Ahmedaltu wants to merge 5 commits into
canonical:mainfrom
Ahmedaltu:docs/per-script-frequencies-v2
Open

docs: document per-frequency shell script MIME types#6891
Ahmedaltu wants to merge 5 commits into
canonical:mainfrom
Ahmedaltu:docs/per-script-frequencies-v2

Conversation

@Ahmedaltu
Copy link
Copy Markdown

Add a dedicated subsection to the MIME multi-part archive documentation
explaining the three per-frequency shell script MIME types:

  • text/x-shellscript-per-boot — runs every boot
  • text/x-shellscript-per-instance — runs once per instance
  • text/x-shellscript-per-once — runs exactly once ever

Includes on-disk script directories and pointers to the handler
(cloudinit/handlers/shell_script_by_frequency.py) and the relevant
modules.

Fixes #6283

Add a dedicated subsection explaining text/x-shellscript-per-boot,
text/x-shellscript-per-instance, and text/x-shellscript-per-once
content types, including their execution frequency, on-disk script
directories, and pointers to the handler and modules.

Fixes canonical#6283

Signed-off-by: Ahmed Al-Tuwaijari <altuwaijari.ahmed@gmail.com>
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds documentation to the MIME multi-part archive user-data format explaining the three per-frequency shell script MIME content types and where those scripts land on disk, with pointers to the relevant cloud-init modules/handler.

Changes:

  • Document text/x-shellscript-per-boot, text/x-shellscript-per-instance, and text/x-shellscript-per-once semantics in the MIME docs.
  • Document the corresponding on-disk script directories under /var/lib/cloud/scripts/.
  • Link the behavior to the cc_scripts_per_* modules and cloudinit/handlers/shell_script_by_frequency.py.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread doc/rtd/explanation/format/mime.rst Outdated
Comment thread doc/rtd/explanation/format/mime.rst Outdated
Comment on lines +80 to +85
Per-frequency shell scripts
---------------------------

Cloud-init supports three MIME content types for controlling how often a
shell script runs:

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Good point. The issue also requested rows in the content-type table and a multipart example. I can add those in a follow-up commit if the maintainers consider it in scope for this PR, or open a separate PR for those additions.

Comment thread doc/rtd/explanation/format/mime.rst Outdated
Ahmedaltu and others added 3 commits May 26, 2026 22:26
…only

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Ahmed Al-Tuwaijari <altuwaijari.ahmed@gmail.com>
Comment thread doc/rtd/explanation/format/mime.rst Outdated
Comment thread doc/rtd/explanation/format/mime.rst Outdated
Signed-off-by: Ahmed Al-Tuwaijari <altuwaijari.ahmed@gmail.com>
@Ahmedaltu Ahmedaltu requested a review from holmanb May 27, 2026 21:42
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.

[docs]: x-shellscript-per-boot is not properly documented

3 participants