Compare commits

..

No commits in common. "main" and "v0.22.1" have entirely different histories.

939 changed files with 11306 additions and 135571 deletions

View File

@ -1,15 +1,9 @@
files/
dist/
logs/
docs/
Dockerfile
docker-manifest.tmpl
docker-manifest-unstable.tmpl
*.db
*.zip
# Frontend
/frontend/node_modules/
/frontend/.direnv
/frontend/dist

File diff suppressed because it is too large Load Diff

3
.envrc
View File

@ -1,3 +0,0 @@
source_url "https://raw.githubusercontent.com/cachix/devenv/95f329d49a8a5289d31e0982652f7058a189bfca/direnvrc" "sha256-d+8cBpDfDBj41inrADaJt+bDWhOktwslgoP5YiGJ1v0="
use devenv

View File

@ -5,7 +5,7 @@ body:
- type: markdown
attributes:
value: |
NOTE: If your issue is a security concern, please send an email to security@vikunja.io instead of opening a public issue. [More information about our security policy](https://vikunja.io/contact/#security).
NOTE: If your issue is a security concern, please send an email to security@vikunja.io instead of opening a public issue.
- type: markdown
attributes:
value: |
@ -24,10 +24,17 @@ body:
description: |
Please provide a description of your issue here, with a URL if you were able to reproduce the issue (see below).
- type: input
id: version
id: frontend-version
attributes:
label: Vikunja Version
description: Vikunja version (or commit reference) of your instance
label: Vikunja Frontend Version
description: Vikunja frontend version (or commit reference) of your instance
validations:
required: true
- type: input
id: api-version
attributes:
label: Vikunja API Version
description: Vikunja API version (or commit reference) of your instance
validations:
required: true
- type: input
@ -40,7 +47,6 @@ body:
attributes:
label: Can you reproduce the bug on the Vikunja demo site?
options:
- "Please select"
- "Yes"
- "No"
validations:

View File

@ -1,5 +1,8 @@
blank_issues_enabled: false
contact_links:
- name: Frontend issues
url: https://code.vikunja.io/frontend/issues
about: This is the API repo. Please open frontend-related bug reports and discussions in the frontend repo. Not sure if you issue is frontend or api? Ask in Matrix or the forum first.
- name: Forum
url: https://community.vikunja.io/
about: Feature Requests, Questions, configuration or deployment problems should be discussed in the forum.

View File

@ -16,7 +16,7 @@ jobs:
with:
pr-comment: 'Hi! Thank you for your contribution.
This repo is only a mirror and unfortunately we can''t accept PRs made here. Please re-submit your changes to [our Gitea instance](https://kolaente.dev/vikunja/vikunja/pulls).
This repo is only a mirror and unfortunately we can''t accept PRs made here. Please re-submit your changes to [our Gitea instance](https://kolaente.dev/vikunja/api/pulls).
Also check out the [contribution guidelines](https://vikunja.io/docs/development/#pull-requests).

11
.gitignore vendored
View File

@ -28,14 +28,3 @@ vendor/
os-packages/
mage_output_file.go
mage-static
.DS_Store
# Devenv
.devenv*
devenv.local.nix
# direnv
.direnv
# pre-commit
.pre-commit-config.yaml

View File

@ -4,22 +4,20 @@ run:
linters:
enable:
- gosimple
- staticcheck
- unused
- megacheck
- govet
- gocritic
- gocyclo
- err113
- goerr113
- goheader
- gofmt
- goimports
- revive
- misspell
disable:
- scopelint # Obsolete, using exportloopref instead
- durationcheck
- goconst
- musttag
presets:
- bugs
- unused
@ -56,7 +54,7 @@ issues:
- path: pkg/migration/*
linters:
- exhaustive
- err113
- goerr113
- path: pkg/models/task_collection_filter\.go
linters:
- exhaustive
@ -66,11 +64,11 @@ issues:
- gosec
- path: pkg/modules/dump/*
linters:
- err113
- goerr113
- path: pkg/
text: "do not define dynamic errors, use wrapped static errors instead:"
text: "err113: do not define dynamic errors, use wrapped static errors instead:"
linters:
- err113
- goerr113
- text: "commentFormatting: put a space between `//` and comment text"
linters:
- gocritic
@ -101,21 +99,3 @@ issues:
- path: pkg/modules/migration/ticktick/ticktick_test.go
linters:
- testifylint
- path: pkg/migration/*
text: "parameter 'tx' seems to be unused, consider removing or renaming it as"
linters:
- revive
- path: pkg/models/typesense.go
text: 'structtag: struct field Position repeats json tag "position" also at'
linters:
- govet
- path: pkg/cmd/user.go
text: 'G115: integer overflow conversion uintptr -> int'
linters:
- gosec
- text: 'G115: integer overflow conversion int64 -> uint64'
linters:
- gosec
- text: 'G115: integer overflow conversion int -> uint64'
linters:
- gosec

View File

@ -1,15 +0,0 @@
{
"recommendations": [
"codezombiech.gitignore",
"dbaeumer.vscode-eslint",
"editorconfig.editorconfig",
"vue.volar",
"lokalise.i18n-ally",
"mgmcdermott.vscode-language-babel",
"mikestead.dotenv",
"Syler.sass-indented",
"vitest.explorer",
"mkhl.direnv",
"golang.Go"
]
}

31
.vscode/settings.json vendored
View File

@ -1,34 +1,5 @@
{
"go.testEnvVars": {
"VIKUNJA_SERVICE_ROOTPATH": "${workspaceRoot}"
},
"editor.formatOnSave": false,
"editor.codeActionsOnSave": {
"source.fixAll": "explicit"
},
"eslint.format.enable": true,
"[javascript]": {
"editor.defaultFormatter": "dbaeumer.vscode-eslint"
},
"[typescript]": {
"editor.defaultFormatter": "dbaeumer.vscode-eslint"
},
// https://eslint.vuejs.org/user-guide/#editor-integrations
"eslint.validate": [
"javascript",
"javascriptreact",
"vue"
],
// disable vetur in case it's installed
"vetur.validation.template": false,
// i18n ally
"i18n-ally.localesPaths": [
"frontend/src/i18n/lang"
],
"i18n-ally.sortKeys": true,
"i18n-ally.keepFulfilled": true,
"i18n-ally.keystyle": "nested"
}
}

File diff suppressed because it is too large Load Diff

View File

@ -1,30 +1,19 @@
# syntax=docker/dockerfile:1
FROM --platform=$BUILDPLATFORM node:22.11.0-alpine AS frontendbuilder
# ┬─┐┬ ┐o┬ ┬─┐
# │─││ │││ │ │
# ┘─┘┘─┘┘┘─┘┘─┘
WORKDIR /build
ENV PNPM_CACHE_FOLDER=.cache/pnpm/
ENV PUPPETEER_SKIP_DOWNLOAD=true
ENV CYPRESS_INSTALL_BINARY=0
COPY frontend/ ./
RUN corepack enable && \
pnpm install && \
pnpm run build
FROM --platform=$BUILDPLATFORM ghcr.io/techknowlogick/xgo:go-1.23.x AS apibuilder
FROM --platform=$BUILDPLATFORM techknowlogick/xgo:go-1.21.x AS builder
RUN go install github.com/magefile/mage@latest && \
mv /go/bin/mage /usr/local/go/bin
WORKDIR /go/src/code.vikunja.io/api
COPY . ./
COPY --from=frontendbuilder /build/dist ./frontend/dist
ARG TARGETOS TARGETARCH TARGETVARIANT
ENV GOPROXY=https://goproxy.kolaente.de
ENV GOPROXY https://goproxy.kolaente.de
RUN export PATH=$PATH:$GOPATH/bin && \
mage build:clean && \
mage release:xgo "${TARGETOS}/${TARGETARCH}/${TARGETVARIANT}"
@ -34,24 +23,22 @@ RUN export PATH=$PATH:$GOPATH/bin && \
# ┘└┘┘─┘┘└┘┘└┘┴─┘┘└┘
# The actual image
FROM scratch
LABEL org.opencontainers.image.authors='maintainers@vikunja.io'
LABEL org.opencontainers.image.url='https://vikunja.io'
LABEL org.opencontainers.image.documentation='https://vikunja.io/docs'
LABEL org.opencontainers.image.source='https://code.vikunja.io/vikunja'
LABEL org.opencontainers.image.licenses='AGPLv3'
LABEL org.opencontainers.image.title='Vikunja'
# Note: I wanted to use the scratch image here, but unfortunatly the go-sqlite bindings require cgo and
# because of this, the container would not start when I compiled the image without cgo.
FROM alpine:3.19 AS runner
LABEL maintainer="maintainers@vikunja.io"
WORKDIR /app/vikunja
ENTRYPOINT [ "/app/vikunja/vikunja" ]
ENTRYPOINT [ "/sbin/tini", "-g", "--", "/entrypoint.sh" ]
EXPOSE 3456
USER 1000
ENV VIKUNJA_SERVICE_ROOTPATH=/app/vikunja/
ENV VIKUNJA_DATABASE_PATH=/db/vikunja.db
ENV PUID 1000
ENV PGID 1000
COPY --from=apibuilder /build/vikunja-* vikunja
COPY --from=apibuilder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
HEALTHCHECK --interval=5s --timeout=30s --start-period=10s --retries=3 \
CMD [ "/app/vikunja/vikunja", "healthcheck" ]
RUN apk --update --no-cache add tzdata tini shadow && \
addgroup vikunja && \
adduser -s /bin/sh -D -G vikunja vikunja -h /app/vikunja -H
COPY docker/entrypoint.sh /entrypoint.sh
RUN chmod 0755 /entrypoint.sh && mkdir files
COPY --from=builder /build/vikunja-* vikunja

View File

@ -1,19 +1,16 @@
<img src="https://vikunja.io/images/vikunja-logo.svg" alt="" style="display: block;width: 50%;margin: 0 auto;" width="50%"/>
[![Build Status](https://drone.kolaente.de/api/badges/vikunja/vikunjaa/status.svg)](https://drone.kolaente.de/vikunja/vikunja)
[![Build Status](https://drone.kolaente.de/api/badges/vikunja/api/status.svg)](https://drone.kolaente.de/vikunja/api)
[![License: AGPL v3](https://img.shields.io/badge/License-AGPL%20v3-blue.svg)](LICENSE)
[![Install](https://img.shields.io/badge/download-v0.24.5-brightgreen.svg)](https://vikunja.io/docs/installing)
[![Docker Pulls](https://img.shields.io/docker/pulls/vikunja/vikunja.svg)](https://hub.docker.com/r/vikunja/vikunja/)
[![Download](https://img.shields.io/badge/download-v0.22.1-brightgreen.svg)](https://dl.vikunja.io)
[![Docker Pulls](https://img.shields.io/docker/pulls/vikunja/api.svg)](https://hub.docker.com/r/vikunja/api/)
[![Swagger Docs](https://img.shields.io/badge/swagger-docs-brightgreen.svg)](https://try.vikunja.io/api/v1/docs)
[![Go Report Card](https://goreportcard.com/badge/kolaente.dev/vikunja/vikunja)](https://goreportcard.com/report/kolaente.dev/vikunja/vikunja)
[![Go Report Card](https://goreportcard.com/badge/kolaente.dev/vikunja/api)](https://goreportcard.com/report/kolaente.dev/vikunja/api)
# Vikunja
# Vikunja API
> The Todo-app to organize your life.
If Vikunja is useful to you, please consider [buying me a coffee](https://www.buymeacoffee.com/kolaente), [sponsoring me on GitHub](https://github.com/sponsors/kolaente) or buying [a sticker pack](https://vikunja.cloud/stickers).
I'm also offering [a hosted version of Vikunja](https://vikunja.cloud/) if you want a hassle-free solution for yourself or your team.
# Table of contents
* [Security Reports](#security-reports)
@ -29,7 +26,7 @@ If you find any security-related issues you don't want to disclose publicly, ple
## Features
See [the features page](https://vikunja.io/features/) on our website for a more exhaustive list or
See [the features page](https://vikunja.io/features/) on our website for a more exaustive list or
try it on [try.vikunja.io](https://try.vikunja.io)!
## Docs
@ -46,9 +43,12 @@ All docs can be found on [the Vikunja home page](https://vikunja.io/docs/).
See [the roadmap](https://my.vikunja.cloud/share/QFyzYEmEYfSyQfTOmIRSwLUpkFjboaBqQCnaPmWd/auth) (hosted on Vikunja!) for more!
* [ ] [Mobile apps](https://code.vikunja.io/app) (separate repo) *In Progress*
* [ ] [Webapp](https://code.vikunja.io/frontend) (separate repo) *In Progress*
## Contributing
Please check out the contribuition guidelines on [the website](https://vikunja.io/docs/development/).
Fork -> Push -> Pull-Request. Also see the [dev docs](https://vikunja.io/docs/development/) for more info.
## License

View File

@ -17,7 +17,6 @@ body = """
{% raw %} {% endraw %}- **BREAKING**: {{commit.breaking_description}}
{%- endif -%}
{%- endfor -%}
{% raw %}\n{% endraw %}\
{%- for commit in commits %}
{%- if commit.scope -%}
{% else -%}
@ -57,3 +56,4 @@ commit_parsers = [
{ body = ".*security", group = "Security"},
{ message = ".*", group = "Other", default_scope = "other"}, # Everything that's not a conventional commit goes into the "Other" category
]

View File

@ -1,839 +0,0 @@
{
"children": [
{
"key": "service",
"children": [
{
"key": "JWTSecret",
"default_value": "\u003cjwt-secret\u003e",
"comment": "This token is used to verify issued JWT tokens.\nDefault is a random token which will be generated at each startup of Vikunja.\n(This means all already issued tokens will be invalid once you restart Vikunja)"
},
{
"key": "jwtttl",
"default_value": "259200",
"comment": "The duration of the issued JWT tokens in seconds.\nThe default is 259200 seconds (3 Days)."
},
{
"key": "jwtttllong",
"default_value": "2592000",
"comment": "The duration of the \"remember me\" time in seconds. When the login request is made with\nthe long param set, the token returned will be valid for this period.\nThe default is 2592000 seconds (30 Days)."
},
{
"key": "interface",
"default_value": ":3456",
"comment": "The interface on which to run the webserver"
},
{
"key": "unixsocket",
"default_value": "",
"comment": "Path to Unix socket. If set, it will be created and used instead of tcp"
},
{
"key": "unixsocketmode",
"default_value": "",
"comment": "Permission bits for the Unix socket. Note that octal values must be prefixed by \"0o\", e.g. 0o660"
},
{
"key": "publicurl",
"default_value": "",
"comment": "The public facing URL where your users can reach Vikunja. Used in emails and for the communication between api and frontend."
},
{
"key": "rootpath",
"default_value": "\u003crootpath\u003e",
"comment": "The base path on the file system where the binary and assets are.\nVikunja will also look in this path for a config file, so you could provide only this variable to point to a folder\nwith a config file which will then be used."
},
{
"key": "maxitemsperpage",
"default_value": "50",
"comment": "The max number of items which can be returned per page"
},
{
"key": "enablecaldav",
"default_value": "true",
"comment": "Enable the caldav endpoint, see the docs for more details"
},
{
"key": "motd",
"default_value": "",
"comment": "Set the motd message, available from the /info endpoint"
},
{
"key": "enablelinksharing",
"default_value": "true",
"comment": "Enable sharing of project via a link"
},
{
"key": "enableregistration",
"default_value": "true",
"comment": "Whether to let new users registering themselves or not"
},
{
"key": "enabletaskattachments",
"default_value": "true",
"comment": "Whether to enable task attachments or not"
},
{
"key": "timezone",
"default_value": "GMT",
"comment": "The time zone all timestamps are in. Please note that time zones have to use [the official tz database names](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones). UTC or GMT offsets won't work."
},
{
"key": "enabletaskcomments",
"default_value": "true",
"comment": "Whether task comments should be enabled or not"
},
{
"key": "enabletotp",
"default_value": "true",
"comment": "Whether totp is enabled. In most cases you want to leave that enabled."
},
{
"key": "testingtoken",
"default_value": "",
"comment": "If not empty, this will enable `/test/{table}` endpoints which allow to put any content in the database.\nUsed to reset the db before frontend tests. Because this is quite a dangerous feature allowing for lots of harm,\neach request made to this endpoint needs to provide an `Authorization: \u003ctoken\u003e` header with the token from below. \u003cbr/\u003e\n**You should never use this unless you know exactly what you're doing**"
},
{
"key": "enableemailreminders",
"default_value": "true",
"comment": "If enabled, Vikunja will send an email to everyone who is either assigned to a task or created it when a task reminder\nis due."
},
{
"key": "enableuserdeletion",
"default_value": "true",
"comment": "If true, will allow users to request the complete deletion of their account. When using external authentication methods\nit may be required to coordinate with them in order to delete the account. This setting will not affect the cli commands\nfor user deletion."
},
{
"key": "maxavatarsize",
"default_value": "1024",
"comment": "The maximum size clients will be able to request for user avatars.\nIf clients request a size bigger than this, it will be changed on the fly."
},
{
"key": "demomode",
"default_value": "false",
"comment": "If set to true, the frontend will show a big red warning not to use this instance for real data as it will be cleared out.\nYou probably don't need to set this value, it was created specifically for usage on [try](https://try.vikunja.io)."
},
{
"key": "allowiconchanges",
"default_value": "true",
"comment": "Allow changing the logo and other icons based on various occasions throughout the year."
},
{
"key": "customlogourl",
"default_value": "",
"comment": "Allow using a custom logo via external URL."
},
{
"key": "enablepublicteams",
"default_value": "false",
"comment": "Enables the public team feature. If enabled, it is possible to configure teams to be public, which makes them\ndiscoverable when sharing a project, therefore not only showing teams the user is member of."
},
{
"key": "bcryptrounds",
"default_value": "11",
"comment": "The number of bcrypt rounds to use during registration. Each increment of this number doubles the computational cost. You probably don't need to change this value."
},
{
"key": "enableopenidteamusersearch",
"default_value": "false",
"comment": "If enabled, users will only find other users who are part of an existing team when they are searching for a user by their partial name. The other existing team may be created from openid. It is still possible to add users to teams with their exact email address even when this is enabled."
}
]
},
{
"key": "sentry",
"children": [
{
"key": "enabled",
"default_value": "false",
"comment": "If set to true, enables anonymous error tracking of api errors via Sentry. This allows us to gather more\ninformation about errors in order to debug and fix it."
},
{
"key": "dsn",
"default_value": "https://440eedc957d545a795c17bbaf477497c@o1047380.ingest.sentry.io/4504254983634944",
"comment": "Configure the Sentry dsn used for api error tracking. Only used when Sentry is enabled for the api."
},
{
"key": "frontendenabled",
"default_value": "false",
"comment": "If set to true, enables anonymous error tracking of frontend errors via Sentry. This allows us to gather more\ninformation about errors in order to debug and fix it."
},
{
"key": "frontenddsn",
"default_value": "https://85694a2d757547cbbc90cd4b55c5a18d@o1047380.ingest.sentry.io/6024480",
"comment": "Configure the Sentry dsn used for frontend error tracking. Only used when Sentry is enabled for the frontend."
}
]
},
{
"key": "database",
"children": [
{
"key": "type",
"default_value": "sqlite",
"comment": "Database type to use. Supported values are mysql, postgres and sqlite. Vikunja is able to run with MySQL 8.0+, Mariadb 10.2+, PostgreSQL 12+, and sqlite."
},
{
"key": "user",
"default_value": "vikunja",
"comment": "Database user which is used to connect to the database."
},
{
"key": "password",
"default_value": "",
"comment": "Database password"
},
{
"key": "host",
"default_value": "localhost",
"comment": "Database host"
},
{
"key": "database",
"default_value": "vikunja",
"comment": "Database to use"
},
{
"key": "path",
"default_value": "./vikunja.db",
"comment": "When using sqlite, this is the path where to store the data"
},
{
"key": "maxopenconnections",
"default_value": "100",
"comment": "Sets the max open connections to the database. Only used when using mysql and postgres."
},
{
"key": "maxidleconnections",
"default_value": "50",
"comment": "Sets the maximum number of idle connections to the db."
},
{
"key": "maxconnectionlifetime",
"default_value": "10000",
"comment": "The maximum lifetime of a single db connection in milliseconds."
},
{
"key": "sslmode",
"default_value": "disable",
"comment": "Secure connection mode. Only used with postgres.\n(see https://pkg.go.dev/github.com/lib/pq?tab=doc#hdr-Connection_String_Parameters)"
},
{
"key": "sslcert",
"default_value": "",
"comment": "The path to the client cert. Only used with postgres."
},
{
"key": "sslkey",
"default_value": "",
"comment": "The path to the client key. Only used with postgres."
},
{
"key": "sslrootcert",
"default_value": "",
"comment": "The path to the ca cert. Only used with postgres."
},
{
"key": "tls",
"default_value": "false",
"comment": "Enable SSL/TLS for mysql connections. Options: false, true, skip-verify, preferred"
}
]
},
{
"key": "typesense",
"children": [
{
"key": "enabled",
"default_value": "false",
"comment": "Whether to enable the Typesense integration. If true, all tasks will be synced to the configured Typesense\ninstance and all search and filtering will run through Typesense instead of only through the database.\nTypesense allows fast fulltext search including fuzzy matching support. It may return different results than\nwhat you'd get with a database-only search."
},
{
"key": "url",
"default_value": "",
"comment": "The url to the Typesense instance you want to use. Can be hosted locally or in Typesense Cloud as long\nas Vikunja is able to reach it."
},
{
"key": "apikey",
"default_value": "",
"comment": "The Typesense API key you want to use."
}
]
},
{
"key": "redis",
"children": [
{
"key": "enabled",
"default_value": "false",
"comment": "Whether to enable redis or not"
},
{
"key": "host",
"default_value": "localhost:6379",
"comment": "The host of the redis server including its port."
},
{
"key": "password",
"default_value": "",
"comment": "The password used to authenticate against the redis server"
},
{
"key": "db",
"default_value": "0",
"comment": "0 means default database"
}
]
},
{
"key": "cors",
"children": [
{
"key": "enable",
"default_value": "false",
"comment": "Whether to enable or disable cors headers.\nNote: If you want to put the frontend and the api on separate domains or ports, you will need to enable this.\nOtherwise the frontend won't be able to make requests to the api through the browser."
},
{
"key": "origins",
"comment": "A list of origins which may access the api. These need to include the protocol (`http://` or `https://`) and port, if any.",
"children": [
{
"default_value": "*"
}
]
},
{
"key": "maxage",
"default_value": "0",
"comment": "How long (in seconds) the results of a preflight request can be cached."
}
]
},
{
"key": "mailer",
"children": [
{
"key": "enabled",
"default_value": "false",
"comment": "Whether to enable the mailer or not. If it is disabled, all users are enabled right away and password reset is not possible."
},
{
"key": "host",
"default_value": "",
"comment": "SMTP Host"
},
{
"key": "port",
"default_value": "587",
"comment": "SMTP Host port.\n**NOTE:** If you're unable to send mail and the only error you see in the logs is an `EOF`, try setting the port to `25`."
},
{
"key": "authtype",
"default_value": "plain",
"comment": "SMTP Auth Type. Can be either `plain`, `login` or `cram-md5`."
},
{
"key": "username",
"default_value": "user",
"comment": "SMTP username"
},
{
"key": "password",
"default_value": "",
"comment": "SMTP password"
},
{
"key": "skiptlsverify",
"default_value": "false",
"comment": "Whether to skip verification of the tls certificate on the server"
},
{
"key": "fromemail",
"default_value": "mail@vikunja",
"comment": "The default from address when sending emails"
},
{
"key": "queuelength",
"default_value": "100",
"comment": "The length of the mail queue."
},
{
"key": "queuetimeout",
"default_value": "30",
"comment": "The timeout in seconds after which the current open connection to the mailserver will be closed."
},
{
"key": "forcessl",
"default_value": "false",
"comment": "By default, Vikunja will try to connect with starttls, use this option to force it to use ssl."
}
]
},
{
"key": "log",
"children": [
{
"key": "path",
"default_value": "\u003crootpath\u003elogs",
"comment": "A folder where all the logfiles should go."
},
{
"key": "enabled",
"default_value": "true",
"comment": "Whether to show any logging at all or none"
},
{
"key": "standard",
"default_value": "stdout",
"comment": "Where the normal log should go. Possible values are stdout, stderr, file or off to disable standard logging."
},
{
"key": "level",
"default_value": "INFO",
"comment": "Change the log level. Possible values (case-insensitive) are CRITICAL, ERROR, WARNING, NOTICE, INFO, DEBUG."
},
{
"key": "database",
"default_value": "off",
"comment": "Whether or not to log database queries. Useful for debugging. Possible values are stdout, stderr, file or off to disable database logging."
},
{
"key": "databaselevel",
"default_value": "WARNING",
"comment": "The log level for database log messages. Possible values (case-insensitive) are CRITICAL, ERROR, WARNING, NOTICE, INFO, DEBUG."
},
{
"key": "http",
"default_value": "stdout",
"comment": "Whether to log http requests or not. Possible values are stdout, stderr, file or off to disable http logging."
},
{
"key": "echo",
"default_value": "off",
"comment": "Echo has its own logging which usually is unnecessary, which is why it is disabled by default. Possible values are stdout, stderr, file or off to disable standard logging."
},
{
"key": "events",
"default_value": "off",
"comment": "Whether or not to log events. Useful for debugging. Possible values are stdout, stderr, file or off to disable events logging."
},
{
"key": "eventslevel",
"default_value": "info",
"comment": "The log level for event log messages. Possible values (case-insensitive) are ERROR, INFO, DEBUG."
},
{
"key": "mail",
"default_value": "off",
"comment": "Whether or not to log mail log messages. This will not log mail contents. Possible values are stdout, stderr, file or off to disable mail-related logging."
},
{
"key": "maillevel",
"default_value": "info",
"comment": "The log level for mail log messages. Possible values (case-insensitive) are ERROR, WARNING, INFO, DEBUG."
}
]
},
{
"key": "ratelimit",
"children": [
{
"key": "enabled",
"default_value": "false",
"comment": "whether or not to enable the rate limit"
},
{
"key": "kind",
"default_value": "user",
"comment": "The kind on which rates are based. Can be either \"user\" for a rate limit per user or \"ip\" for an ip-based rate limit."
},
{
"key": "period",
"default_value": "60",
"comment": "The time period in seconds for the limit"
},
{
"key": "limit",
"default_value": "100",
"comment": "The max number of requests a user is allowed to do in the configured time period"
},
{
"key": "store",
"default_value": "keyvalue",
"comment": "The store where the limit counter for each user is stored.\nPossible values are \"keyvalue\", \"memory\" or \"redis\".\nWhen choosing \"keyvalue\" this setting follows the one configured in the \"keyvalue\" section."
},
{
"key": "noauthlimit",
"default_value": "10",
"comment": "The number of requests a user can make from the same IP to all unauthenticated routes (login, register,\npassword confirmation, email verification, password reset request) per minute. This limit cannot be disabled.\nYou should only change this if you know what you're doing."
}
]
},
{
"key": "files",
"children": [
{
"key": "basepath",
"default_value": "./files",
"comment": "The path where files are stored"
},
{
"key": "maxsize",
"default_value": "20MB",
"comment": "The maximum size of a file, as a human-readable string.\nWarning: The max size is limited 2^64-1 bytes due to the underlying datatype"
}
]
},
{
"key": "migration",
"comment": "To use any of the available migrators, you usually need to configure credentials for the appropriate service and enable it. Find instructions below on how to do this for the provided migrators.",
"children": [
{
"key": "todoist",
"children": [
{
"key": "enable",
"default_value": "false",
"comment": "Wheter to enable the Todoist migrator."
},
{
"key": "clientid",
"default_value": "",
"comment": "The client id, required for making requests to the Todoist api\nYou need to register your Vikunja instance at https://developer.todoist.com/appconsole.html to get this."
},
{
"key": "clientsecret",
"default_value": "",
"comment": "The client secret, also required for making requests to the Todoist api. Obtain it at https://developer.todoist.com/appconsole.html after registering your Vikunja instance."
},
{
"key": "redirecturl",
"default_value": "\u003cservice.publicurl\u003e/migrate/todoist",
"comment": "The url where clients are redirected after they authorized Vikunja to access their Todoist items.\nIn Todoist, this is called `OAuth redirect URL` and it needs to match the url you entered when registering\nyour Vikunja instance at the Todoist developer console.\nWhen using the official Vikunja frontend, set this to `\u003cservice.publicurl\u003e/migrate/todoist` (the default value).\nOtherwise, set this to an url which then makes a request to /api/v1/migration/todoist/migrate\nwith the code obtained from the Todoist api."
}
]
},
{
"key": "trello",
"children": [
{
"key": "enable",
"default_value": "false",
"comment": "Whether to enable the Trello migrator."
},
{
"key": "key",
"default_value": "",
"comment": "The client id, required for making requests to the trello api.\nYou need to register your Vikunja instance at https://trello.com/app-key (log in before you visit that link) to get one. Copy the `Personal Key` and set it as the client id. Add your Vikunja domain to the Allowed Origins list."
},
{
"key": "redirecturl",
"default_value": "\u003cfrontend url\u003e/migrate/trello",
"comment": "The url where clients are redirected after they authorized Vikunja to access their trello cards.\nThis needs to match the url you entered when registering your Vikunja instance at trello.\nWhen using the official Vikunja frontend, set this to `\u003cservice.publicurl\u003e/migrate/trello` (the default value).\nOtherwise, set this to an url which then makes a request to /api/v1/migration/trello/migrate\nwith the code obtained from the Trello api."
}
]
},
{
"key": "microsofttodo",
"children": [
{
"key": "enable",
"default_value": "false",
"comment": "Wheter to enable the Microsoft Todo migrator."
},
{
"key": "clientid",
"default_value": "",
"comment": "The client id, required for making requests to the Microsoft graph api.\nSee https://docs.microsoft.com/en-us/azure/active-directory/develop/quickstart-register-app#register-an-application\nfor information about how to register your Vikunja instance."
},
{
"key": "clientsecret",
"default_value": "",
"comment": "The client secret, also required for making requests to the Microsoft graph api"
},
{
"key": "redirecturl",
"default_value": "\u003cfrontend url\u003e/migrate/microsoft-todo",
"comment": "The url where clients are redirected after they authorized Vikunja to access their Microsoft todo tasks.\nThis needs to match the url you entered when registering your Vikunja instance at Microsoft.\nWhen using the official Vikunja frontend, set this to `\u003cservice.publicurl\u003e/migrate/microsoft-todo` (the default value).\nOtherwise, set this to an url which then makes a request to /api/v1/migration/microsoft-todo/migrate\nwith the code obtained from the Microsoft Todo api."
}
]
}
]
},
{
"key": "avatar",
"children": [
{
"key": "gravatarexpiration",
"default_value": "3600",
"comment": "When using gravatar, this is the duration in seconds until a cached gravatar user avatar expires"
}
]
},
{
"key": "backgrounds",
"children": [
{
"key": "enabled",
"default_value": "true",
"comment": "Whether to enable backgrounds for projects at all."
},
{
"key": "providers",
"children": [
{
"key": "upload",
"children": [
{
"key": "enabled",
"default_value": "true",
"comment": "Whether to enable uploaded project backgrounds"
}
]
},
{
"key": "unsplash",
"children": [
{
"key": "enabled",
"default_value": "false",
"comment": "Whether to enable setting backgrounds from unsplash as project backgrounds"
},
{
"key": "accesstoken",
"default_value": "",
"comment": "You need to create an application for your installation at https://unsplash.com/oauth/applications/new\nand set the access token below."
},
{
"key": "applicationid",
"default_value": "",
"comment": "The unsplash application id is only used for pingback and required as per their api guidelines.\nYou can find the Application ID in the dashboard for your API application. It should be a numeric ID.\nIt will only show in the UI if your application has been approved for Enterprise usage, therefore if\nyoure in Demo mode, you can also find the ID in the URL at the end: https://unsplash.com/oauth/applications/:application_id"
}
]
}
]
}
]
},
{
"key": "legal",
"comment": "Legal urls\nWill be shown in the frontend if configured here",
"children": [
{
"key": "imprinturl",
"default_value": ""
},
{
"key": "privacyurl",
"default_value": ""
}
]
},
{
"key": "keyvalue",
"comment": "Key Value Storage settings\nThe Key Value Storage is used for different kinds of things like metrics and a few cache systems.",
"children": [
{
"key": "type",
"default_value": "memory",
"comment": "The type of the storage backend. Can be either \"memory\" or \"redis\". If \"redis\" is chosen it needs to be configured separately."
}
]
},
{
"key": "auth",
"children": [
{
"key": "local",
"comment": "Local authentication will let users log in and register (if enabled) through the db.\nThis is the default auth mechanism and does not require any additional configuration.",
"children": [
{
"key": "enabled",
"default_value": "true",
"comment": "Enable or disable local authentication"
}
]
},
{
"key": "openid",
"comment": "OpenID configuration will allow users to authenticate through a third-party OpenID Connect compatible provider.\u003cbr/\u003e\nThe provider needs to support the `openid`, `profile` and `email` scopes.\u003cbr/\u003e\n**Note:** Some openid providers (like Gitlab) only make the email of the user available through OpenID if they have set it to be publicly visible.\nIf the email is not public in those cases, authenticating will fail.\u003cbr/\u003e\n**Note 2:** The frontend expects the third party to redirect the user \u003cfrontend-url\u003e/auth/openid/\u003cauth key\u003e after authentication. Please make sure to configure the redirect url in your third party auth service accordingly if you're using the default Vikunja frontend.\nThe frontend will automatically provide the API with the redirect url, composed from the current url where it's hosted.\nIf you want to use the desktop client with OpenID, make sure to allow redirects to `127.0.0.1`.",
"children": [
{
"key": "enabled",
"default_value": "false",
"comment": "Enable or disable OpenID Connect authentication"
},
{
"key": "providers",
"comment": "A list of enabled providers. You can freely choose the `<provider key>`. Note that you must add at least one key to a config file if you want to read values from an environment variable as the provider won't be known to Vikunja otherwise.",
"children": [
{
"key": "<provider key>",
"children": [
{
"key": "name",
"default_value": "",
"comment": "The name of the provider as it will appear in the frontend."
},
{
"key": "authurl",
"default_value": "",
"comment": "The auth url to send users to if they want to authenticate using OpenID Connect."
},
{
"key": "logouturl",
"default_value": "",
"comment": "The oidc logouturl that users will be redirected to on logout.\nLeave empty or delete key, if you do not want to be redirected."
},
{
"key": "clientid",
"default_value": "",
"comment": "The client ID used to authenticate Vikunja at the OpenID Connect provider."
},
{
"key": "clientsecret",
"default_value": "",
"comment": "The client secret used to authenticate Vikunja at the OpenID Connect provider."
},
{
"key": "scope",
"default_value": "openid email profile",
"comment": "The scope necessary to use oidc.\nIf you want to use the Feature to create and assign to Vikunja teams via oidc, you have to add the custom \"vikunja_scope\" and check [openid.md](https://vikunja.io/docs/openid/).\ne.g. scope: openid email profile vikunja_scope"
}
]
}
]
}
]
}
]
},
{
"key": "metrics",
"comment": "Prometheus metrics endpoint",
"children": [
{
"key": "enabled",
"default_value": "false",
"comment": "If set to true, enables a /metrics endpoint for prometheus to collect metrics about Vikunja. You can query it from `/api/v1/metrics`."
},
{
"key": "username",
"default_value": "",
"comment": "If set to a non-empty value the /metrics endpoint will require this as a username via basic auth in combination with the password below."
},
{
"key": "password",
"default_value": "",
"comment": "If set to a non-empty value the /metrics endpoint will require this as a password via basic auth in combination with the username below."
}
]
},
{
"key": "defaultsettings",
"comment": "Provide default settings for new users. When a new user is created, these settings will automatically be set for the user. If you change them in the config file afterwards they will not be changed back for existing users.",
"children": [
{
"key": "avatar_provider",
"default_value": "initials",
"comment": "The avatar source for the user. Can be `gravatar`, `initials`, `upload` or `marble`. If you set this to `upload` you'll also need to specify `defaultsettings.avatar_file_id`."
},
{
"key": "avatar_file_id",
"default_value": "0",
"comment": "The id of the file used as avatar."
},
{
"key": "email_reminders_enabled",
"default_value": "false",
"comment": "If set to true users will get task reminders via email."
},
{
"key": "discoverable_by_name",
"default_value": "false",
"comment": "If set to true will allow other users to find this user when searching for parts of their name."
},
{
"key": "discoverable_by_email",
"default_value": "false",
"comment": "If set to true will allow other users to find this user when searching for their exact email."
},
{
"key": "overdue_tasks_reminders_enabled",
"default_value": "true",
"comment": "If set to true will send an email every day with all overdue tasks at a configured time."
},
{
"key": "overdue_tasks_reminders_time",
"default_value": "9:00",
"comment": "When to send the overdue task reminder email."
},
{
"key": "default_project_id",
"default_value": "0",
"comment": "The id of the default project. Make sure users actually have access to this project when setting this value."
},
{
"key": "week_start",
"default_value": "0",
"comment": "Start of the week for the user. `0` is sunday, `1` is monday and so on."
},
{
"key": "language",
"default_value": "\u003cunset\u003e",
"comment": "The language of the user interface. Must be an ISO 639-1 language code followed by an ISO 3166-1 alpha-2 country code. Check https://kolaente.dev/vikunja/vikunja/frontend/src/branch/main/src/i18n/lang for a list of possible languages. Will default to the browser language the user uses when signing up."
},
{
"key": "timezone",
"default_value": "\u003ctime zone set at service.timezone\u003e",
"comment": "The time zone of each individual user. This will affect when users get reminders and overdue task emails."
}
]
},
{
"key": "webhooks",
"children": [
{
"key": "enabled",
"default_value": "true",
"comment": "Whether to enable support for webhooks"
},
{
"key": "timeoutseconds",
"default_value": "30",
"comment": "The timeout in seconds until a webhook request fails when no response has been received."
},
{
"key": "proxyurl",
"default_value": "",
"comment": "The URL of [a mole instance](https://github.com/frain-dev/mole) to use to proxy outgoing webhook requests. You should use this and configure appropriately if you're not the only one using your Vikunja instance. More info about why: https://webhooks.fyi/best-practices/webhook-providers#implement-security-on-egress-communication. Must be used in combination with `webhooks.password` (see below)."
},
{
"key": "proxypassword",
"default_value": "",
"comment": "The proxy password to use when authenticating against the proxy."
}
]
},
{
"key": "autotls",
"children": [
{
"key": "enabled",
"default_value": "false",
"comment": "If set to true, Vikunja will automatically request a TLS certificate from Let's Encrypt and use it to serve Vikunja over TLS. By enabling this option, you agree to Let's Encrypt's TOS.\nYou must configure a `service.publicurl` with a valid TLD where Vikunja is reachable to make this work. Furthermore, it is reccomened to set `service.interface` to `:443` if you're using this."
},
{
"key": "email",
"default_value": "",
"comment": "A valid email address which will be used to register certificates with Let's Encrypt. You must provide this value in order to use autotls."
},
{
"key": "renewbefore",
"default_value": "30d",
"comment": "A duration when certificates should be renewed before they expire. Valid time units are `ns`, `us` (or `µs`), `ms`, `s`, `m`, `h`."
}
]
}
]
}

359
config.yml.sample Normal file
View File

@ -0,0 +1,359 @@
service:
# This token is used to verify issued JWT tokens.
# Default is a random token which will be generated at each startup of vikunja.
# (This means all already issued tokens will be invalid once you restart vikunja)
JWTSecret: "<jwt-secret>"
# The duration of the issued JWT tokens in seconds.
# The default is 259200 seconds (3 Days).
jwtttl: 259200
# The duration of the "remember me" time in seconds. When the login request is made with
# the long param set, the token returned will be valid for this period.
# The default is 2592000 seconds (30 Days).
jwtttllong: 2592000
# The interface on which to run the webserver
interface: ":3456"
# Path to Unix socket. If set, it will be created and used instead of tcp
unixsocket:
# Permission bits for the Unix socket. Note that octal values must be prefixed by "0o", e.g. 0o660
unixsocketmode:
# The URL of the frontend, used to send password reset emails.
frontendurl: ""
# The base path on the file system where the binary and assets are.
# Vikunja will also look in this path for a config file, so you could provide only this variable to point to a folder
# with a config file which will then be used.
rootpath: <rootpath>
# Path on the file system to serve static files from. Set to the path of the frontend files to host frontend alongside the api.
staticpath: ""
# The max number of items which can be returned per page
maxitemsperpage: 50
# Enable the caldav endpoint, see the docs for more details
enablecaldav: true
# Set the motd message, available from the /info endpoint
motd: ""
# Enable sharing of project via a link
enablelinksharing: true
# Whether to let new users registering themselves or not
enableregistration: true
# Whether to enable task attachments or not
enabletaskattachments: true
# The time zone all timestamps are in. Please note that time zones have to use [the official tz database names](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones). UTC or GMT offsets won't work.
timezone: GMT
# Whether task comments should be enabled or not
enabletaskcomments: true
# Whether totp is enabled. In most cases you want to leave that enabled.
enabletotp: true
# If not empty, enables logging of crashes and unhandled errors in sentry.
sentrydsn: ''
# If not empty, this will enable `/test/{table}` endpoints which allow to put any content in the database.
# Used to reset the db before frontend tests. Because this is quite a dangerous feature allowing for lots of harm,
# each request made to this endpoint needs to provide an `Authorization: <token>` header with the token from below. <br/>
# **You should never use this unless you know exactly what you're doing**
testingtoken: ''
# If enabled, vikunja will send an email to everyone who is either assigned to a task or created it when a task reminder
# is due.
enableemailreminders: true
# If true, will allow users to request the complete deletion of their account. When using external authentication methods
# it may be required to coordinate with them in order to delete the account. This setting will not affect the cli commands
# for user deletion.
enableuserdeletion: true
# The maximum size clients will be able to request for user avatars.
# If clients request a size bigger than this, it will be changed on the fly.
maxavatarsize: 1024
# If set to true, the frontend will show a big red warning not to use this instance for real data as it will be cleared out.
# You probably don't need to set this value, it was created specifically for usage on [try](https://try.vikunja.io).
demomode: false
database:
# Database type to use. Supported types are mysql, postgres and sqlite.
type: "sqlite"
# Database user which is used to connect to the database.
user: "vikunja"
# Database password
password: ""
# Database host
host: "localhost"
# Database to use
database: "vikunja"
# When using sqlite, this is the path where to store the data
path: "./vikunja.db"
# Sets the max open connections to the database. Only used when using mysql and postgres.
maxopenconnections: 100
# Sets the maximum number of idle connections to the db.
maxidleconnections: 50
# The maximum lifetime of a single db connection in milliseconds.
maxconnectionlifetime: 10000
# Secure connection mode. Only used with postgres.
# (see https://pkg.go.dev/github.com/lib/pq?tab=doc#hdr-Connection_String_Parameters)
sslmode: disable
# The path to the client cert. Only used with postgres.
sslcert: ""
# The path to the client key. Only used with postgres.
sslkey: ""
# The path to the ca cert. Only used with postgres.
sslrootcert: ""
# Enable SSL/TLS for mysql connections. Options: false, true, skip-verify, preferred
tls: false
typesense:
# Whether to enable the Typesense integration. If true, all tasks will be synced to the configured Typesense
# instance and all search and filtering will run through Typesense instead of only through the database.
# Typesense allows fast fulltext search including fuzzy matching support. It may return different results than
# what you'd get with a database-only search.
enabled: false
# The url to the Typesense instance you want to use. Can be hosted locally or in Typesense Cloud as long
# as Vikunja is able to reach it.
url: ''
# The Typesense API key you want to use.
apikey: ''
redis:
# Whether to enable redis or not
enabled: false
# The host of the redis server including its port.
host: 'localhost:6379'
# The password used to authenticate against the redis server
password: ''
# 0 means default database
db: 0
cors:
# Whether to enable or disable cors headers.
# Note: If you want to put the frontend and the api on separate domains or ports, you will need to enable this.
# Otherwise the frontend won't be able to make requests to the api through the browser.
enable: true
# A list of origins which may access the api. These need to include the protocol (`http://` or `https://`) and port, if any.
origins:
- "*"
# How long (in seconds) the results of a preflight request can be cached.
maxage: 0
mailer:
# Whether to enable the mailer or not. If it is disabled, all users are enabled right away and password reset is not possible.
enabled: false
# SMTP Host
host: ""
# SMTP Host port.
# **NOTE:** If you're unable to send mail and the only error you see in the logs is an `EOF`, try setting the port to `25`.
port: 587
# SMTP Auth Type. Can be either `plain`, `login` or `cram-md5`.
authtype: "plain"
# SMTP username
username: "user"
# SMTP password
password: ""
# Wether to skip verification of the tls certificate on the server
skiptlsverify: false
# The default from address when sending emails
fromemail: "mail@vikunja"
# The length of the mail queue.
queuelength: 100
# The timeout in seconds after which the current open connection to the mailserver will be closed.
queuetimeout: 30
# By default, vikunja will try to connect with starttls, use this option to force it to use ssl.
forcessl: false
log:
# A folder where all the logfiles should go.
path: <rootpath>logs
# Whether to show any logging at all or none
enabled: true
# Where the normal log should go. Possible values are stdout, stderr, file or off to disable standard logging.
standard: "stdout"
# Change the log level. Possible values (case-insensitive) are CRITICAL, ERROR, WARNING, NOTICE, INFO, DEBUG.
level: "INFO"
# Whether or not to log database queries. Useful for debugging. Possible values are stdout, stderr, file or off to disable database logging.
database: "off"
# The log level for database log messages. Possible values (case-insensitive) are CRITICAL, ERROR, WARNING, NOTICE, INFO, DEBUG.
databaselevel: "WARNING"
# Whether to log http requests or not. Possible values are stdout, stderr, file or off to disable http logging.
http: "stdout"
# Echo has its own logging which usually is unnecessary, which is why it is disabled by default. Possible values are stdout, stderr, file or off to disable standard logging.
echo: "off"
# Whether or not to log events. Useful for debugging. Possible values are stdout, stderr, file or off to disable events logging.
events: "off"
# The log level for event log messages. Possible values (case-insensitive) are ERROR, INFO, DEBUG.
eventslevel: "info"
# Whether or not to log mail log messages. This will not log mail contents. Possible values are stdout, stderr, file or off to disable mail-related logging.
mail: "off"
# The log level for mail log messages. Possible values (case-insensitive) are ERROR, WARNING, INFO, DEBUG.
maillevel: "info"
ratelimit:
# whether or not to enable the rate limit
enabled: false
# The kind on which rates are based. Can be either "user" for a rate limit per user or "ip" for an ip-based rate limit.
kind: user
# The time period in seconds for the limit
period: 60
# The max number of requests a user is allowed to do in the configured time period
limit: 100
# The store where the limit counter for each user is stored.
# Possible values are "keyvalue", "memory" or "redis".
# When choosing "keyvalue" this setting follows the one configured in the "keyvalue" section.
store: keyvalue
# The number of requests a user can make from the same IP to all unauthenticated routes (login, register,
# password confirmation, email verification, password reset request) per minute. This limit cannot be disabled.
# You should only change this if you know what you're doing.
noauthlimit: 10
files:
# The path where files are stored
basepath: ./files # relative to the binary
# The maximum size of a file, as a human-readable string.
# Warning: The max size is limited 2^64-1 bytes due to the underlying datatype
maxsize: 20MB
migration:
todoist:
# Wheter to enable the todoist migrator or not
enable: false
# The client id, required for making requests to the todoist api
# You need to register your vikunja instance at https://developer.todoist.com/appconsole.html to get this
clientid:
# The client secret, also required for making requests to the todoist api
clientsecret:
# The url where clients are redirected after they authorized Vikunja to access their todoist items.
# This needs to match the url you entered when registering your Vikunja instance at todoist.
# This is usually the frontend url where the frontend then makes a request to /migration/todoist/migrate
# with the code obtained from the todoist api.
# Note that the vikunja frontend expects this to be /migrate/todoist