1 June 2019 Updated 29 August 2019 by Peter
post main image
For this blog I wanted the blog post page to have three 'columns'. Why did I quote the word columns? Because what is a column on a large screen can be a row on a mobile device. Bootstrap uses containers, rows and columns. And of course, a Bootstrap column can show on the screen as a column or a row. Help! When designing a layout we must not think about columns but about screen elements and how we ...
Read more
10 March 2019 Updated 30 August 2019 by Peter
post main image
When using docker we want the size of the docker image to be minimal. Why? Many reasons. Memory footprint is one especially when running many Python Flask websites on an ISPConfig3 server.  Fortunately, from docker 17.05 we can use multistage builds. Using this we reduce our image size from 376MB to 211MB! Below are two images we can use: > docker images python 3.6-alpine 1837080c5e87 5 ...
Read more
9 March 2019 Updated 28 August 2019 by Peter
post main image
By default Alembic does not change the length of string fields, I noticed this after changing a string field from: description = Column(String(150), server_default='') to: description = Column(String(250), server_default='') No changes were made. It appears that column type change detection is off by default, so you can test it first, and can be turned on by adding 'compare_type=True' to the context. ...
Read more
13 February 2019 Updated 31 August 2019 by Peter
post main image
This is a post showing how to run a Flask app on ISPConfig3. Why? I have a VPS on the internet running Debian and ISPConfig3. It is running static sites and PHP sites. But now I also want to run my Flask python apps here. This way I can use the domain management I am used to and do not need an extra server for Python apps. This solution uses Docker to run the Flask app, printing 'Hello world', and ...
Read more