Installation
Prerequisites
Download zip with application for your OS and extract it.
Windows
- Put
SmartHomeApi.WebApi.exe
into directory where you want SmartHomeApi to run, for exampleC:\SmartHomeApi
. - Run
SmartHomeApi.WebApi.exe
. Messageappsettings.json not found so run installer
will appear and then SmartHomeApi will lead you through simple initial configuration workflow. - After configuration you can either select
Exit CLI and run SmartHomeApi
orGenerate install/uninstall service scripts
.Scripts
directory will contain Readme and two.bat
files for installing SmartHomeApi as Windows service and for uninstalling. - Run
InstallWindowsService.bat
inC:\SmartHomeApi\Scripts
directory with Administrator privileges. SmartHomeApi will be installed as Windows service and started.
info
In case if you skipped Generate install/uninstall service scripts
and exited SmartHomeApi you always can enter CLI mode running SmartHomeApi with cli
parameter and generate scripts later.
Linux
This instruction is for Ubuntu, for other systems it can be different.
- Open terminal.
- Execute
sudo nautilus
. - Create
SmartHomeApi
directory inbin/
directory. - Put
SmartHomeApi.WebApi
intobin/SmartHomeApi
directory. - Right click on
SmartHomeApi.WebApi
, then Properties -> Permissions and checkAllow executing file as program
. - Open another terminal. Run
cd /
in order to get root directory, then executecd bin/SmartHomeApi
and thensudo ./SmartHomeApi.WebApi
. Messageappsettings.json not found so run installer
will appear and then SmartHomeApi will lead you through simple initial configuration workflow. - After configuration you can select
Generate install/uninstall service scripts
.Scripts
directory will contain Readme andsmarthomeapi.service
file for installing SmartHomeApi as daemon. - Copy
smarthomeapi.service
to/etc/systemd/system
directory. - Open terminal and execute "sudo systemctl daemon-reload".
- Execute "sudo systemctl start smarthomeapi".
- Execute "sudo systemctl enable smarthomeapi" if you want a service to be launched at system startup.
info
In case if you skipped Generate install/uninstall service scripts
and exited SmartHomeApi you always can enter CLI mode running SmartHomeApi with cli
parameter and generate scripts later.