Run script, systemctl hook after a UI config change

  • Hi, my use case is quite simple. Before switching to openmediavault I was running a home NAS/media server on ArchLinux.
    I boot without mounting a main storage and then I run a simple script

    Code
    # import map_luks - "expect's" script.
    
    map_luks /dev/mapper/vg0-home home $pass 1> /dev/null 
    mount /home
    systemctl restart transmission smb nmb syncthing@sync.service

    The thing is that I didn't want to start some services without decrypting a given partiton.
    2 questions:

    - do you have a plan to support a similar use case in newer releases

    - how can I achieve a similar behaviour, e.g. by login to a shell and running a custom script that would change coning (decrypt & mount partition) and restart some services.

    • Offizieller Beitrag

    any update regarding this thread?

    I would suggest auto unlocking the correct way using crypttab - https://www.howtoforge.com/aut…ted-drives-with-a-keyfile Then if your services are still starting too soon, add a systemd unit override specifically telling the service to wait for the filesystem.

    omv 7.0.5-1 sandworm | 64 bit | 6.8 proxmox kernel

    plugins :: omvextrasorg 7.0 | kvm 7.0.13 | compose 7.1.6 | k8s 7.1.0-3 | cputemp 7.0.1 | mergerfs 7.0.4


    omv-extras.org plugins source code and issue tracker - github - changelogs


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!