Self-hosting Penpot (II)

So you have decided you want to use Docker for your own instance of Penpot (otherwise read the first part of the article…).

Self-hosting Penpot with Docker

The first step is to decide what kind of machine you want to install Penpot on (local or cloud, operating system, version). This will determine the “flavor” of the Docker version you need.

  • Docker Desktop
    • This is the only option to have Docker on Windows or MacOS. Recently, it’s also been made available in Linux, in the most popular distributions (Debian, Ubuntu and Fedora).
    • Docker Desktop has a graphical control panel (GUI) to manage the service and view the containers, images and volumes. But it needs the command line (Terminal in Linux and Mac, or PowerShell in Windows) to build and run the containers, and execute other operations.
    • It’s better for single computer installations, or if you have a local network with Windows or Mac servers.
    • You can download and install it from here.
    • It should be noted that Docker Desktop is not open source. You can use it for free if you are a particular, non-profit or small business, but you can’t look at the source code or make modifications.

  • Docker Engine
    • This is an app that runs as a background service; you control it via terminal commands.
    • Available only in Linux, all distributions.
    • It’s generally better if you want to serve your Penpot instance over Internet, from a virtual or physical Linux server.
    • To install it, your Linux distribution could have official packages for Docker (see your distribution documentation). Or you can use the packages provided by the Docker company. Check here for instructions.
    • Once installed, you will have a running service on your machine, and you should be able to control it with commands.
    • Important note: for Penpot you need the docker compose V2 plugin (included by default in Docker Desktop). Formerly this was a separate application, but in newer versions it is a plugin for the base docker command. There are still many manuals over the Internet that show the old commands for using it; you should take this into account when reading them. We always recommend using the latest version.

Once you have your Docker system up and running, here is the guide to install Penpot and configure Penpot with Docker. Basically, you need to download the docker-compose file and execute it.

In the end, you will have some containers with Linux inside (even if your host machine is Windows or Mac) for the components of Penpot (frontend, backend and exporter) and also for the PostgreSQL database and the Redis engine. The frontend should be ready and listening to a HTTP port.

It’s now up to you how to connect the machine to the Internet or your local network, to give access to your users, allow it to send emails, and to maintain the application, the database and the disk storage.

5 Likes

Hmm. the last link to “install Penpot and configure Penpot with Docker” links to a localhost URL. Is this correct?

1 Like

Oops… I tested all the links, but of course, in my machine all of them worked well :blush:

Fixed!

Perfect! Thank you for the quick fix.

1 Like