Add the possibility to pass API token as environment variable for Docker container
This commit is contained in:
parent
3cf9484644
commit
5e32f55138
|
|
@ -3,6 +3,8 @@ Version 1.0.44 (unreleased)
|
||||||
|
|
||||||
Improvements:
|
Improvements:
|
||||||
|
|
||||||
|
* Update Docker image to Alpine Linux 3.5
|
||||||
|
* Add the possibility to pass API token as environment variable for Docker container
|
||||||
* Add wildcard search for task reference field
|
* Add wildcard search for task reference field
|
||||||
* Improve automated action TaskAssignColorOnDueDate to update task only when necessary
|
* Improve automated action TaskAssignColorOnDueDate to update task only when necessary
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -78,6 +78,10 @@ class AuthenticationMiddleware extends Base implements MiddlewareInterface
|
||||||
return API_AUTHENTICATION_TOKEN;
|
return API_AUTHENTICATION_TOKEN;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (getenv('API_AUTHENTICATION_TOKEN')) {
|
||||||
|
return getenv('API_AUTHENTICATION_TOKEN');
|
||||||
|
}
|
||||||
|
|
||||||
return $this->configModel->get('api_token');
|
return $this->configModel->get('api_token');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,8 @@ Environment Variables
|
||||||
|
|
||||||
Environment variables maybe useful when Kanboard is deployed as container (Docker).
|
Environment variables maybe useful when Kanboard is deployed as container (Docker).
|
||||||
|
|
||||||
| Variable | Description |
|
| Variable | Description |
|
||||||
|---------------|---------------------------------------------------------------------------------------------------------------------------------|
|
|--------------------------|---------------------------------------------------------------------------------------------------------------------------------|
|
||||||
| DATABASE_URL | `[database type]://[username]:[password]@[host]:[port]/[database name]`, example: `postgres://foo:foo@myserver:5432/kanboard` |
|
| DATABASE_URL | `[database type]://[username]:[password]@[host]:[port]/[database name]`, example: `postgres://foo:foo@myserver:5432/kanboard` |
|
||||||
| DEBUG | Enable/Disable debug mode: "true" or "false" |
|
| DEBUG | Enable/Disable debug mode: "true" or "false" |
|
||||||
|
| API_AUTHENTICATION_TOKEN | Custom API token |
|
||||||
|
|
|
||||||
|
|
@ -1,2 +1,3 @@
|
||||||
env[DATABASE_URL] = $DATABASE_URL
|
env[DATABASE_URL] = $DATABASE_URL
|
||||||
env[DEBUG] = $DEBUG
|
env[DEBUG] = $DEBUG
|
||||||
|
env[API_AUTHENTICATION_TOKEN] = $API_AUTHENTICATION_TOKEN
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue