openLuup: Windows Subsystem for Linux (WSL)
-
Windows Subsystem for Linux (WSL) is a compatibility layer for running Linux binary executables natively on Windows 10.
This is one way to run openLuup under Windows without having to worry whether any of your plugins require a Unix/Linux environment – this way, they actually get one.
Many flavours of Linux are available for WSL from the Microsoft Store – my favourite, to date, is Alpine WSL, which is a tiny (~8 Mb) and lightweight WSL distro based on musl, uses busybox, and just contains the most important things to be functional.
Here's a rough guide to getting openLuup going under Alpine WSL
- Enable WSL on via the Windows control panel
- Install the Alpine WSL app from the Microsoft Store
- Start the Alpine application
- Install Lua and some libraries:
Alpine comes with a really full set of Lua libraries available for install. You need to be
su
to install them:# apk add curl # apk add lua5.1 # apk add lua5.1-md5 # apk add lua5.1-cjson # apk add lua5.1-filesystem # apk add lua5.1-bitop # apk add lua5.1-sec
- You need to make the file system permanent:
$ cd /mnt/c/ $ mkdir cmh-ludl $ cd cmh-ludl
- Now get and install openLuup and AltUI:
$ wget https://github.com/akbooer/openLuup/raw/master/Utilities/openLuup_install.lua $ lua5.1 openLuup_install.lua
When finished (it won't yet return to the command prompt)
- access openLuup via the URL:
IP:3480/openLuup
- Update to latest version (Plugins page, type
development
in Update box) - Install VeraBridge (Device Table > Create D_VeraBridge.xml / I_VeraBridge.xml)
- Add IP of Vera to VeraBridge attributes
- Reload
- VeraBridge device > Actions > GetVeraFiles (wait ~2 minutes)
- Reload
Simple!
-
Windows Subsystem for Linux (WSL) is a compatibility layer for running Linux binary executables natively on Windows 10.
This is one way to run openLuup under Windows without having to worry whether any of your plugins require a Unix/Linux environment – this way, they actually get one.
Many flavours of Linux are available for WSL from the Microsoft Store – my favourite, to date, is Alpine WSL, which is a tiny (~8 Mb) and lightweight WSL distro based on musl, uses busybox, and just contains the most important things to be functional.
Here's a rough guide to getting openLuup going under Alpine WSL
- Enable WSL on via the Windows control panel
- Install the Alpine WSL app from the Microsoft Store
- Start the Alpine application
- Install Lua and some libraries:
Alpine comes with a really full set of Lua libraries available for install. You need to be
su
to install them:# apk add curl # apk add lua5.1 # apk add lua5.1-md5 # apk add lua5.1-cjson # apk add lua5.1-filesystem # apk add lua5.1-bitop # apk add lua5.1-sec
- You need to make the file system permanent:
$ cd /mnt/c/ $ mkdir cmh-ludl $ cd cmh-ludl
- Now get and install openLuup and AltUI:
$ wget https://github.com/akbooer/openLuup/raw/master/Utilities/openLuup_install.lua $ lua5.1 openLuup_install.lua
When finished (it won't yet return to the command prompt)
- access openLuup via the URL:
IP:3480/openLuup
- Update to latest version (Plugins page, type
development
in Update box) - Install VeraBridge (Device Table > Create D_VeraBridge.xml / I_VeraBridge.xml)
- Add IP of Vera to VeraBridge attributes
- Reload
- VeraBridge device > Actions > GetVeraFiles (wait ~2 minutes)
- Reload
Simple!
@akbooer
Great! Pretty simple, thank you for the instructions!Already had WSL enabled, although an older version.
I downloaded & installed the Alpine WSL from the windows store.
Starting the app presented the terminal window.
Trying to install the packages . . .
$ apk add [package name] gives a permission denied errorIf I su and then install the packages from the # prompt, they install.
Following the rest of the steps from a $ prompt work as you instructed, including manually adding the vera bridge and updating openLuup to your development branch.
openLuup runs great, but GetVeraFiles always download zero byte png files in the /icons folder (ongoing problem for me on all of my recent openLuup installs) A "permissions" problem? Even though I never change any permissions unless instructed in your install instructions.
Love the local access to the cmh-ludl tree!
Again, thanks
DCMChrissy -
@akbooer
Great! Pretty simple, thank you for the instructions!Already had WSL enabled, although an older version.
I downloaded & installed the Alpine WSL from the windows store.
Starting the app presented the terminal window.
Trying to install the packages . . .
$ apk add [package name] gives a permission denied errorIf I su and then install the packages from the # prompt, they install.
Following the rest of the steps from a $ prompt work as you instructed, including manually adding the vera bridge and updating openLuup to your development branch.
openLuup runs great, but GetVeraFiles always download zero byte png files in the /icons folder (ongoing problem for me on all of my recent openLuup installs) A "permissions" problem? Even though I never change any permissions unless instructed in your install instructions.
Love the local access to the cmh-ludl tree!
Again, thanks
DCMChrissy@dcmchrissy said in openLuup: Windows Subsystem for Linux (WSL):
openLuup runs great, but GetVeraFiles always download zero byte png files in the /icons folder (ongoing problem for me on all of my recent openLuup installs) A "permissions" problem? Even though I never change any permissions unless instructed in your install instructions.
This issue has been fixed in the latest development version (v20.12.10), so update to that from the plugins page and try again. (It is possibly worthwhile deleting the existing zero-bytes files first.)
Yes, the
su
approach seems to work (I must have been su when I tried this – I have changed my original post accordingly, thanks)Thanks for trying this out!