diff --git a/README.md b/README.md index 77f96c8..8812c7e 100644 --- a/README.md +++ b/README.md @@ -20,14 +20,14 @@ the token service: - `COOKIE_NAME` _(required)_: Name of the moderator cookie (example: `jitsi_mod_jwt`) - `JWT_VALIDITY` _(default: `1h`)_: Duration for which the generated token should be valid for (example: `1h30m`, `300s`) -- `JWT_SECRET` _(required)_: Secret JWT signing string, this value needs +- `JWT_APP_SECRET` _(required)_: Secret JWT signing string, this value needs to match the one configured in Jitsi meet (example: `my_jitsi_app_secret`) -- `JWT_ISSUER` _(required)_: JWT issuer, this value needs +- `JWT_APP_ID` _(required)_: JWT issuer, this value needs to match the one configured in Jitsi meet (example: `my_jitsi_app_id`) - `JWT_AUDIENCE` _(default: `jitsi`)_: JWT audience, this value needs to match the one configured in Jitsi - `JWT_LEEWAY` _(default: `1m`)_: Maximum clock drift allowed for JWT validation -- `JITSI_URL` _(required)_: Jitsi Meet base URL (without the room identifier) +- `PUBLIC_URL` _(required)_: Jitsi Meet base URL (without the room identifier) (example: `https://meet.jitsi`) - `HTML_DOCROOT` _(default: `./html`)_: Directory containing the HTML login form template diff --git a/main.go b/main.go index 01c4a09..d780c5a 100644 --- a/main.go +++ b/main.go @@ -24,12 +24,12 @@ var config struct { CookieName string `env:"COOKIE_NAME,notEmpty"` JWTValidity time.Duration `env:"JWT_VALIDITY" envDefault:"1h"` - JWTSecret string `env:"JWT_SECRET,notEmpty,unset"` - JWTIssuer string `env:"JWT_ISSUER,notEmpty"` + JWTSecret string `env:"JWT_APP_SECRET,notEmpty,unset"` + JWTIssuer string `env:"JWT_APP_ID,notEmpty"` JWTAudience string `env:"JWT_AUDIENCE" envDefault:"jitsi"` JWTLeeway time.Duration `env:"JWT_LEEWAY" envDefault:"1m"` - JitsiURL url.URL `env:"JITSI_URL,notEmpty"` + JitsiURL url.URL `env:"PUBLIC_URL,notEmpty"` HTMLDocRoot string `env:"HTML_DOCROOT" envDefault:"./html"` HTMLTitle string `env:"HTML_TITLE" envDefault:"Jitsi Moderator Login"`