Dev Environment Setup
Last updated
Last updated
The QMK Compile API consists of a few movings parts:
QMK Compiler Worker
QMK Compiler API
To get these working together you'll need to install Redis and Minio along with QMK Compiler's dependencies.
We use to decouple compiling the firmware from the webserver. It also handles administrative tasks like cleaning up old firmware hexes. Installing and administering Redis in a production environment is beyond the scope of this document.
For development purposes, you can simply install and run redis with the default configuration.
On macOS you can use to install redis. You only have to do this once.
If you have experience setting up Redis on a system not listed, please submit a PR with instructions so that others may benefit from your experience.
Minio is a scalable object storage server with an API compatible with Amazon's S3. For development purposes you can run a single instance with no special configuration.
Once you've installed Minio you can use bin/start_minio
to start an instance of minio configured for the QMK Compiler development environment. You'll want to do this in a separate terminal from the other services as Minio is very chatty.
QMK Compiler needs the zip and unzip binaries to be available. These are probably already on your system but if not you will need to install them.
There are two repositories you'll need to clone to work on QMK Compiler. Make sure to put them in the same directory so they can find each other.
While it is possible to install the dependencies system wide you will keep your development environment cleaner if you develop inside a virtualenv. We've provided a script to make this setup easy:
Once you have setup your virtualenv follow the instructions for activating it. You need to make sure it is active before you run the server.
First start Minio:
In another terminal start the backend and worker:
Finally, use the test_compile
script to submit a compile job:
The version of redis in the repositories is most likely outdated.
On macOS you can use to install Minio. You only have to do this once.
From :
QMK Compiler is written in . It was developed against 3.6 but should work on any release after 3.5. Your computer probably has Python already, but if not .