Microstack install on Fedora 33

Hi all,

Has anyone successfully installed and run microstack snap on Fedora 33 or any Fedora version?

I can install no problem with sudo snap install microstack --devmode --beta but running init fails.

$ sudo microstack init --auto --control
[sudo] password for philroche: 
WARNING: cgroup v2 is not fully supported yet, proceeding with partial confinement
2021-09-03 15:01:07,105 - microstack_init - INFO - Configuring clustering ...
2021-09-03 15:01:07,223 - microstack_init - INFO - Setting up as a control node.
2021-09-03 15:01:09,831 - microstack_init - INFO - Configuring networking ...
Traceback (most recent call last):
  File "/snap/microstack/233/bin/microstack", line 11, in <module>
    load_entry_point('microstack==0.0.1', 'console_scripts', 'microstack')()
  File "/snap/microstack/233/lib/python3.8/site-packages/microstack/main.py", line 44, in main
    cmd()
  File "/snap/microstack/233/lib/python3.8/site-packages/init/main.py", line 60, in wrapper
    return func(*args, **kwargs)
  File "/snap/microstack/233/lib/python3.8/site-packages/init/main.py", line 227, in init
    question.ask()
  File "/snap/microstack/233/lib/python3.8/site-packages/init/questions/question.py", line 210, in ask
    self.yes(awr)
  File "/snap/microstack/233/lib/python3.8/site-packages/init/questions/__init__.py", line 188, in yes
    enable('ovsdb-server')
  File "/snap/microstack/233/lib/python3.8/site-packages/init/shell.py", line 162, in enable
    check('snapctl', 'start', 'microstack.{}'.format(service), '--enable')
  File "/snap/microstack/233/lib/python3.8/site-packages/init/shell.py", line 69, in check
    raise subprocess.CalledProcessError(proc.returncode, " ".join(args))
subprocess.CalledProcessError: Command 'snapctl start microstack.ovsdb-server --enable' returned non-zero exit status 1.

And the error in journalctl -xe is:

Sep 03 15:01:10 brick snapd[2148]: taskrunner.go:271: [change 185 "Run service command \"start\" for services [\"ovsdb-server\"] of snap \"microstack\"" task] failed: [start snap.microstack.ovsdb-server.service] failed with exit status 1: Job for snap.microstack.ovsdb-server.service failed because the control proces>
Sep 03 15:01:10 brick snapd[2148]: See "systemctl status snap.microstack.ovsdb-server.service" and "journalctl -xe" for details.

and

Sep 03 15:03:33 brick microstack.ovsdb-server[41446]: /snap/microstack/233/usr/local/share/openvswitch/scripts/ovs-ctl: 122: /etc/init.d/functions: Syntax error: "(" unexpected (expecting "done")

From what I can figure out this is because ovs-ctl is run with /bin/sh

$ head -n 1 /snap/microstack/233/usr/local/share/openvswitch/scripts/ovs-ctl
#! /bin/sh

but inside the snap /bin/sh is a symlink to dash

$ sudo snap run --shell microstack
WARNING: cgroup v2 is not fully supported yet, proceeding with partial confinement
bash-5.0# ls -al /bin/sh
lrwxrwxrwx. 1 root root 4 Jul 18  2019 /bin/sh -> dash
bash-5.0# 

And sourcing /etc/init.d/functions with dash shell does indeed result in Syntax error: "(" unexpected (expecting "done").

Is there a way around this? Perhaps to change /bin/sh -> bash to support Fedora?

To me this looks like an issue with snap services on Fedora rather than specific to microstack. Happy to file bug/issue elsewhere if this is not the right place.

Thanks,

Phil