Environmental Variables #1746

Closed
opened 2020-10-11 14:16:02 +00:00 by Rustymage · 5 comments

I've stumbled across this app and I think it's going to be able to meet my needs and see me move across from Todoist. Wooo!

However, I think I'm hit a stumbling block and I hope someone can help.

I'm running this on an RPi (w/docker) and I have the front/back end operating fine with the default setup - database is locally hosted, not mariadb.

I can't figure out for the life of me how to set & where to place the variables mentioned here: https://vikunja.io/docs/config-options/

Thanks in advance :)

I've stumbled across this app and I think it's going to be able to meet my needs and see me move across from Todoist. Wooo! However, I think I'm hit a stumbling block and I hope someone can help. I'm running this on an RPi (w/docker) and I have the front/back end operating fine with the default setup - database is locally hosted, not mariadb. I can't figure out for the life of me how to set & where to place the variables mentioned here: https://vikunja.io/docs/config-options/ Thanks in advance :)
Owner

Hey there, glad you like Vikunja!

If you're running Vikunja with docker, I would reccomend using docker-compose. In docker-compose you can set the environment variables as usual at the environment property. You can see this in the docker examples.

What does your setup look like?

Hey there, glad you like Vikunja! If you're running Vikunja with docker, I would reccomend using docker-compose. In docker-compose you can set the environment variables as usual at the `environment` property. You can see this in [the docker examples](https://vikunja.io/docs/full-docker-example/). What does your setup look like?
konrad added the
question
hosting
labels 2020-10-11 15:15:02 +00:00
Author

The thing is, I can't work out how to translate enableregistration: true to an env variable for the docker-compose.

I've tried adding it to both front & rear end via portainer and nothing happens. I suspect I'm doing something wrong?

I should add the the below works except the environmental variables.

Here's my setup.

version: '3'

services:
  api:
    image: vikunja/api
    environment:
      VIKUNJA_DATABASE_HOST: 192.168.1.115:3307
      VIKUNJA_DATABASE_PASSWORD: PASSWORD123
      VIKUNJA_DATABASE_TYPE: mysql
      VIKUNJA_DATABASE_USER: vikunja
      VIKUNJA_DATABASE_DATABASE: vikunja
    volumes:
      - ./files:/app/vikunja/files
    restart: unless-stopped
  frontend:
    image: vikunja/frontend
    restart: unless-stopped
  proxy:
    image: nginx
    ports:
      - 80:80
    volumes:
      - ./nginx.conf:/etc/nginx/conf.d/default.conf:ro
    depends_on:
      - api
      - frontend
    restart: unless-stopped
The thing is, I can't work out how to translate `enableregistration`: true to an env variable for the docker-compose. I've tried adding it to both front & rear end via portainer and nothing happens. I suspect I'm doing something wrong? I should add the the below works except the environmental variables. Here's my setup. ``` version: '3' services: api: image: vikunja/api environment: VIKUNJA_DATABASE_HOST: 192.168.1.115:3307 VIKUNJA_DATABASE_PASSWORD: PASSWORD123 VIKUNJA_DATABASE_TYPE: mysql VIKUNJA_DATABASE_USER: vikunja VIKUNJA_DATABASE_DATABASE: vikunja volumes: - ./files:/app/vikunja/files restart: unless-stopped frontend: image: vikunja/frontend restart: unless-stopped proxy: image: nginx ports: - 80:80 volumes: - ./nginx.conf:/etc/nginx/conf.d/default.conf:ro depends_on: - api - frontend restart: unless-stopped ```
Owner

The enableregistration key is located under the service key which translates to VIKUNJA_SERVICE_ENABLEREGISTRATION for the env variable. That's the same system for all of the config variables.

The `enableregistration` key is located under the `service` key which translates to `VIKUNJA_SERVICE_ENABLEREGISTRATION` for the env variable. That's the same system for all of the config variables.
Author

I think that's what I need :)

Brain wasn't functioning. Problem is I know enough to be dangerous (w/docker) but not enough to get myself out of a pickle...

Thank You!

I think that's what I need :) Brain wasn't functioning. Problem is I know enough to be dangerous (w/docker) but not enough to get myself out of a pickle... Thank You!
Author

In case anyone is wondering in the future:

VIKUNJA_SERVICE_ENABLEREGISTRATION: 'true'
VIKUNJA_SERVICE_ENABLELINKSHARING: 'true'
VIKUNJA_SERVICE_ENABLETASKATTACHMENTS: 'true'
In case anyone is wondering in the future: ``` VIKUNJA_SERVICE_ENABLEREGISTRATION: 'true' VIKUNJA_SERVICE_ENABLELINKSHARING: 'true' VIKUNJA_SERVICE_ENABLETASKATTACHMENTS: 'true' ```
Sign in to join this conversation.
No Milestone
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: vikunja/vikunja#1746
No description provided.