Install Panoramax backend
The Panoramax API (backend) can be installed in several different ways:
- as a Python package, manually or via PyPI
- βοΈ using a Platform as a Service host like Scalingo
- manually deployed as a simple Docker container
- with a fully integrated Docker compose file
- Kubernetes Helm chart
The manual approach offers a high-level of customization whereas the Docker Compose/Scalingo approaches are more plug & play.
Note
A Panoramax instance always needs an up and running database, as seen in database setup documentation. Some recipes below embed the database, but some don't π
As a Python package
Panoramax API best runs with a recent Linux server and needs at least Python 3.11
Install
System dependencies
You first need to install some system dependencies:
python3(>= 3.11)pipvirtualenvgit(optional, only needed if you want to install Panoramax backend from source)gcclibffi-dev
Install Panoramax backend
For this, you also need to install first git.
Then you can do:
# Enable Python environment
python3 -m venv env
source ./env/bin/activate
# Install Python dependencies
pip install geovisio
Info
If you use this method, and use the flask command instead of the panoramax_backend command, you will need to pass the --app geovisio parameter to the flask commands (or add FLASK_APP=geovisio to your environment variables)
Scalingo / Platform as a Service
The Panoramax API can be easily deployed on Platform as a Service (PaaS) services, which might reduce the maintenence workload to operate a Panoramax instance.
Some users have had success deploying Panoramax on Scalingo. All necessary settings should be defined as environment variables. General documentation for deploying applications on Scalingo is available on their website.
Docker
You just need an up-to-date Docker version. The image is panoramax/api and are tagged by versions.
There are 2 particular tags:
latestis the latest released versiondevelopis the rolling release for on the edge features
Tip
The repository was geovisio/api before being moved to panoramax/api. It you still you geovisio/api, make sure to update the Docker image name to get the lastest versions.
GitLab container registry
For bleeding-edge tagged images, you can also find Docker images tagged by git describe for every commit on the develop branch (kept 90 days) on our GitLag registry.
Docker Compose
You just need an up to date Docker version. The Docker compose provided in this repository will install all needed components, including the database.
Each Docker compose files in the repository is a demo of a way to setup Panoramax API, but since Panoramax API is quite flexible, not all possibilities are covered.
Warning
The Docker compose files provided in this repository are more meant as examples, and will likely need to be updated to fit your production workflow.
You will likely need to at least handle SSL/HTTPS and ποΈ data backup.
Feel free to copy the Docker compose file that better suits your needs and adapt it.
-
Minimal example
Back-end + database
-
Complete instance
Front-end + back-end + database + authentication server
-
With OSM authentication
Complete instance + OpenStreetMap-based login
-
With Keycloak authentication
Complete instance + custom account login
This does not include a blurring API by default
If a blurring API is needed, the docker-compose-blurring.yml file can be used alongside it with:
For linux users, you also need to use the docker-compose-full-linux.yml file
Due to difference in networking between mac/windows and linux, the docker-compose-full.yml file is not able to use the host networking by default.
To use host networking, you need to use the docker-compose-full-linux.yml file.
Kubernetes
There is a work-in-progress Kubernetes Helm chart to deploy Panoramax on Kubernetes.
Note
The Helm chart is still in development. Any help and feedback is welcome.
Check the documentation for more details on how to configure the Kubernetes cluster and deploy the chart.