vikunja-api/docs/content/doc/setup/build-from-source.md
Dominik Pschenitschni 36265fcedf feat(docs): document pnpm (#1251)
Co-authored-by: Dominik Pschenitschni <mail@celement.de>
Reviewed-on: https://kolaente.dev/vikunja/api/pulls/1251
Co-authored-by: Dominik Pschenitschni <dpschen@noreply.kolaente.de>
Co-committed-by: Dominik Pschenitschni <dpschen@noreply.kolaente.de>
2022-10-01 15:30:20 +00:00

1.9 KiB

date title draft type menu
2022-09-21:00:00+02:00 Build from sources false doc
sidebar
parent
setup

Build Vikunja from source

To completely build Vikunja from source, you need to build the api and frontend.

{{< table_of_contents >}}

API

The Vikunja API has no other dependencies than go itself. That means compiling it boils down to these steps:

  1. Make sure Go is properly installed on your system. You'll need at least Go 1.17.
  2. Make sure Mage is properly installed on your system.
  3. Clone the repo with git clone https://code.vikunja.io/api and switch into the directory.
  4. Run mage build:build in the source of this repo. This will build a binary in the root of the repo which will be able to run on your system.

Note: Static ressources such as email templates are built into the binary. For these to work, you may need to run mage build:generate before building the vikunja binary. When builing entirely with mage, you dont need to do this, mage build:generate will be run automatically when running mage build:build.

Build for different architectures

To build for other platforms and architectures than the one you're currently on, simply run mage release:release or mage release:{linux|windows|darwin}.

More options are available, please refer to the [magefile docs]({{< ref "../development/mage.md">}}) for more details.

Frontend

The code for the frontend is located at code.vikunja.io/frontend.

  1. Make sure you have pnpm properly installed on your system.
  2. Clone the repo with git clone https://code.vikunja.io/frontend and switch into the directory.
  3. Install all dependencies with pnpm install
  4. Build the frontend with pnpm run build. This will result in a static js bundle in the dist/ folder which you can deploy.