Number Plate Recognition - OpenALPR

Hey All,

Thought i would show this, but it’s still work in progress,

I know there is some native openalpr integration but i have created a separate solution that allows me to split up my workloads.

In the below repo is a container that runs the latest openalpr lib and will monitor a video stream and recognise number plates. When it recognises one that is in an array it will call the HA API Locally and fire a script called script.anpr. For me this script opens my drive way gates.

Feel free to take a look;



Hi Sam,

Is there any way to get this to work on Hassio which is currently running on Virtual box?
I’m interested in having some sort of ANPR solution to open my garage doors when I approach the house.



Can you not get Docker running? on your virtual box? Doesn’t mater if its a Linux or Windows OS as long as docker runs, That’s the easiest way. There is an issue with one of the libraries running direct on a windows guest.

Someone has docker running on Virtual box here;


Have it working in docker that has alpine as base image.

#Adding of dependencies
echo “” >>/etc/apk/repositories && echo -e “\n” >> /etc/apk/repositoriesapk --no-cache add --virtual .build-deps ca-certificates wget git gcc g++ cmake make curl-dev leptonica-dev log4cplus-dev opencv-dev tesseract-ocr-dev libexecinfo-dev
#Cloning and making of directories
cd /srv && git clone && cd openalpr/src && mkdir build && cd build && sed -i.bak ‘s/backtrace/0;///’ …/daemon.cpp
cmake -DCMAKE_INSTALL_PREFIX:PATH=/usr -DCMAKE_INSTALL_SYSCONFDIR:PATH=/etc … && make -j8 && make install

as for using it, openalpr config does not work but a workaround from gavinwoolley here makes it usable. OpenALPR local not working

If you need help editing config etc just reach out.

Hi Sam,

Is it possible to run this container twice? As I have two cams on two different driveways. Can you help me with that?


can you generate pull request and ill merge it

Hey Paul,

Yer don’t see why not. Just run two instances with different container names. edit the stream url in each.

Hey Sam,

When I try to build the docker container I get an error wich I cant seem to fix. Googled it and tried a lot like installing skbuild or reinstalling python but the error doesn’t disappear, any tips?

I enter this code:

docker build -t openalpr

And at step 11/19 I get this error?

Step 11/19 : RUN pip3 install opencv-python
 ---> Running in d78171be5a4b
Collecting opencv-python
  Downloading (88.3MB)
    Complete output from command python egg_info:
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/tmp/pip-build-lvbbiguj/opencv-python/", line 10, in <module>
        import skbuild
    ModuleNotFoundError: No module named 'skbuild'

Command "python egg_info" failed with error code 1 in /tmp/pip-build-lvbbiguj/opencv-python/
The command '/bin/sh -c pip3 install opencv-python' returned a non-zero code: 1

Other containers run without problems. Any thoughts?