-
Notifications
You must be signed in to change notification settings - Fork 524
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1290 from zmrow/cdrom
Add a systemd mount unit for CD-ROM devices
- Loading branch information
Showing
3 changed files
with
27 additions
and
1 deletion.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
[Unit] | ||
Description=CD-ROM mount (/media/cdrom) | ||
# Only run this unit if /dev/cdrom exists and is tracked via systemd. (systemd | ||
# ships with a udev rule to tag and symlink the first suspected cdrom device to | ||
# /dev/cdrom) | ||
Requires=dev-cdrom.device | ||
After=dev-cdrom.device | ||
DefaultDependencies=no | ||
Conflicts=umount.target | ||
Before=local-fs.target umount.target | ||
|
||
[Mount] | ||
What=/dev/cdrom | ||
Where=/media/cdrom | ||
Type=iso9660 | ||
Options=defaults,noexec | ||
|
||
[Install] | ||
# This dependency ensures that systemd attempts to run this unit if the device | ||
# exists. | ||
WantedBy=dev-cdrom.device |
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