ubuntu core - How to format writable directory when snap is installed? - Ask Ubuntu


we have several daemons starting via snap. of daemons looking specific directory's data. 1 of apps mongo. unfortunately data directory empty db folder not exist.

apps:    app1:     command: app1 --path "$snap_data/app1     daemon: simple    mongodb:     command: mongod --dbpath "$snap_data/db/"     daemon: simple     plugs: [network-bind] 

how can force directory created before mongodb daemon starts?

the correct way handle command run script instead of mongod directly. script should format directory , exec mongo.


Comments

Popular posts from this blog

crash - Windows Rundll32 (child process of DllHost) is crashing. How can I even identify it? - Super User

debian - Kali Linux - Debootstrap error Failed to determine codename for the release - Super User

networking - Slave steals IP meant for bonded interface - Ask Ubuntu