As, the whole stack involves Docker related commands to be run, we can by default check if Docker is running or not before execution logic of the command.
╭─devarshi@Devarshis-MacBook-Air.local ~/Downloads
╰─➤ fm create erp --frappe-branch version-15-beta --apps erpnext:version-15-beta --apps hrms:version-15-beta 130 ↵
✅ Sites directory doesn't exists! Created at -> /Users/devarshi/frappe
{'USERID': 501, 'USERGROUP': 20, 'APPS_LIST': 'erpnext:version-15-beta,hrms:version-15-beta', 'FRAPPE_BRANCH':
'version-15-beta', 'DEVELOPER_MODE': True, 'ADMIN_PASS': 'admin', 'DB_NAME': 'erp-localhost', 'SITENAME': 'erp.localhost'}
✅ Stopped all sites !
Stopping all other sites !
⢿ Pulling Docker ImagesCannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?
❌ NoneNone
Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?
❌ NoneNone
Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?
⡿ Starting Site❌ NoneCannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?
⡿ Started site
╭─devarshi@Devarshis-MacBook-Air.local ~/Downloads
╰─➤ fm create erp --frappe-branch version-15-beta --apps erpnext:version-15-beta --apps hrms:version-15-beta
{'USERID': 501, 'USERGROUP': 20, 'APPS_LIST': 'erpnext:version-15-beta,hrms:version-15-beta', 'FRAPPE_BRANCH':
'version-15-beta', 'DEVELOPER_MODE': True, 'ADMIN_PASS': 'admin', 'DB_NAME': 'erp-localhost', 'SITENAME': 'erp.localhost'}
⣷ Working❌ Site erp.localhost already exists! Aborting! -> /Users/devarshi/frappe/erp.localhost
As, the whole stack involves Docker related commands to be run, we can by default check if Docker is running or not before execution logic of the command.