Script not running in a new notebook

Hello guys, I didn’t have the time to setup my new BrewPi spark 3 and still using my old Arduino Uno Rev C.
The notebook in which I was running the web interface stops working and I installed a new one with Debian “Jessie”, the old one was running Debian “Wheezy” with no problems using the Legacy branch and Arduino code v0.2.10.

After setting up the new notebook, I wasn’t able to start the script and I’m having several errors:

brewpi@brewpi:~$ sudo -u brewpi python /home/brewpi/
Jun 24 2018 19:24:55 Opening serial port
Jun 24 2018 19:24:55 Notification: Script started for beer ‘My First BrewPi Run’
Jun 24 2018 19:25:05 Checking software version on controller…
Jun 24 2018 19:25:05 Found BrewPi v0.2.10 build unknown, running on an Arduino Uno with a revC shield on port /dev/ttyACM0

Traceback (most recent call last):
File “/home/brewpi/”, line 415, in
File “/home/brewpi/”, line 287, in startBeer
File “/home/brewpi/”, line 256, in setFiles
File “/usr/lib/python2.7/”, line 157, in makedirs
mkdir(name, mode)
OSError: [Errno 13] Permission denied: ‘/var/www/html/data/My First BrewPi Run/’
Exception in thread Thread-1 (most likely raised during interpreter shutdown):
Traceback (most recent call last):
File “/usr/lib/python2.7/”, line 810, in __bootstrap_inner
File “/usr/lib/python2.7/”, line 763, in run
File “/home/brewpi/”, line 81, in __listenThread
File “/usr/local/lib/python2.7/dist-packages/serial/”, line 590, in inWaiting
File “/usr/local/lib/python2.7/dist-packages/serial/”, line 467, in in_waiting
<type ‘exceptions.AttributeError’>: ‘NoneType’ object has no attribute ‘ioctl’

And in Device Configuration --> Device List web interface:
Error while receiving device configuration: SyntaxError: Unexpected token C in JSON at position 0

I reinstalled the notebook twice with no luck, at this point seems that Jessie doesn’t work with BrewPi, but on the other hand, I could run it when I tested my new BrewPi Spark 3 in a VM in my MAC, so I’m a bit confused what is going wrong here.

Thanks in advance.

I think I found the root cause of this.
I installed it using the automated script, and seems that not all the permissions are properly granted.
The dialout permission is not granted thru the automated script, I realized it when in a try, I followed the manual installation procedure in which the permissions are mentioned.
The solution was as simple as “sudo usermod -a -G dialout user” command.
Also upgraded Debian 9 (stretch) latest stable release and works with no issues.