Skip to content

Commit

Permalink
Workaround ostree remount bug
Browse files Browse the repository at this point in the history
  • Loading branch information
khuedoan committed Jun 20, 2021
1 parent b916233 commit a2734f6
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions metal/roles/pxe-server/templates/http/ignition/ignition.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,36 @@ systemd:
# iSCSI for Longhorn distributed block storage
- name: iscsid.service
enabled: true
# TODO (bug) ostree-remount bug workaround
- name: ostree-remount.service
enabled: true
contents: |
[Unit]
Description=OSTree Remount OS/ Bind Mounts
Documentation=man:ostree(1)
DefaultDependencies=no
ConditionKernelCommandLine=ostree
OnFailure=emergency.target
Conflicts=umount.target
# Run after core mounts
After=-.mount var.mount
After=systemd-remount-fs.service
# But we run *before* most other core bootup services that need write access to /etc and /var
Before=local-fs.target umount.target
Before=systemd-random-seed.service plymouth-read-write.service systemd-journal-flush.service
Before=systemd-tmpfiles-setup.service

[Service]
Type=oneshot
RemainAfterExit=yes
ExecStartPre=/usr/bin/sleep 10
ExecStart=/usr/lib/ostree/ostree-remount
StandardInput=null
StandardOutput=journal
StandardError=journal+console

[Install]
WantedBy=local-fs.target
{% if item == "metal0" %}
# Terraform state backend
- name: tfstate.service
Expand Down

0 comments on commit a2734f6

Please sign in to comment.