Set up a development environment for Mainsail
At this point you should have already forked Mainsail into your repositories. If that is not the case, go ahead and fork Mainsail now.
.env.development.local.examplefile and omit the
.exampleat the end. The file is located in the root directory of the Mainsail project.
Now edit the
.env.development.localfile to reflect your printers network configuration.
Example: If the IP of your printer is
192.168.1.10, modify it like this:
# hostname or ip from the moonraker instance
For Moonraker, you need to add localhost:8080 to the
cors_domainssection inside the
Port 8080 is the default port
npmwill serve the development server on.
Make sure you run node >= 16
Open your preferred terminal application and navigate into the Mainsail root directory. Run the following command to install all required modules and dependencies:
Afterwards run the following command to start a local development server:
npm run serve
Once the server is up and running, you can access Mainsail on
To use our Virtual-Klipper-Printer project, it is required to have Docker installed. Below are some general resources on how to get Docker.