uffizzi icon indicating copy to clipboard operation
uffizzi copied to clipboard

Map UFFIZZI_URL value to other env vars using config

Open waveywaves opened this issue 2 years ago • 2 comments

Tell us about your request I would like to see the value associated to UFFIZZI_URL associated to other env vars mentioned in a config under x-uffizzi config under docker compose

Which service(s) is this request for? kube controller, uffizzi_app

Tell us about the problem you're trying to solve. What are you trying to do, and why is it hard? I need to map UFFIZZI_URL to other env vars at times when setting up user repos

Describe the solution you'd like

x-uffizzi:
  ingress:
    service: serving-em
    env-map:
    - "REDIRECT_URL"
    - "ENDPOINT"

Are you currently working around the issue? Using docker-entrypoint.sh to export during runtime

Additional context Add any other context or screenshots about the feature request here.

waveywaves avatar Sep 07 '22 14:09 waveywaves

In case there is path after the main url, we can do something like this:

x-uffizzi:
  ingress:
    service: serving-em
    uffizzi-envvar-overrides:
      - REDIRECT_URL: $$UFFIZZI_URL/home
      - BACKEND_URL: $$UFFIZZI_URL/backend

moklidia avatar Nov 15 '22 15:11 moklidia

@waveywaves Maybe can we just make like this?

    entrypoint: /bin/bash
    command:
      - "-c"
      - "REDIRECT_URL=$$UFFIZZI_URL/home ENDPOINT=$$UFFIZZI_URL/entrypoint node /app/app/app.js"

I've tried it here and it works

SCR-20221116-ovf

zipofar avatar Nov 16 '22 15:11 zipofar