mirror of
https://github.com/makeplane/plane
synced 2024-06-14 14:31:34 +00:00
feat(configure_instance): check mandatory variables before starting (#4760)
* docs: update self-host guide link in README (#4704) found via: - https://github.com/makeplane/docs/issues/48 - https://github.com/makeplane/plane/pull/3109 * feat(configure_instance): add check for mandatory variables before starting * fix(configure_instance): use correct variable and improve the exception * fix(configure_instance): remove trailling spaces * fix(configure_instance): check the mandatory value from exported env only * fix(configure_instance): remove useless import * fix(configure_command): improve the way error is raising --------- Co-authored-by: jon ⚝ <jon@allmende.io>
This commit is contained in:
parent
cb593538e4
commit
bdd43f3f24
@ -48,7 +48,7 @@ Meet [Plane](https://dub.sh/plane-website-readme), an open-source project manage
|
|||||||
|
|
||||||
The easiest way to get started with Plane is by creating a [Plane Cloud](https://app.plane.so) account.
|
The easiest way to get started with Plane is by creating a [Plane Cloud](https://app.plane.so) account.
|
||||||
|
|
||||||
If you would like to self-host Plane, please see our [deployment guide](https://docs.plane.so/docker-compose).
|
If you would like to self-host Plane, please see our [deployment guide](https://docs.plane.so/self-hosting/overview).
|
||||||
|
|
||||||
| Installation methods | Docs link |
|
| Installation methods | Docs link |
|
||||||
| -------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
| -------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
import os
|
import os
|
||||||
|
|
||||||
# Django imports
|
# Django imports
|
||||||
from django.core.management.base import BaseCommand
|
from django.core.management.base import BaseCommand, CommandError
|
||||||
|
|
||||||
# Module imports
|
# Module imports
|
||||||
from plane.license.models import InstanceConfiguration
|
from plane.license.models import InstanceConfiguration
|
||||||
@ -15,6 +15,12 @@ class Command(BaseCommand):
|
|||||||
from plane.license.utils.encryption import encrypt_data
|
from plane.license.utils.encryption import encrypt_data
|
||||||
from plane.license.utils.instance_value import get_configuration_value
|
from plane.license.utils.instance_value import get_configuration_value
|
||||||
|
|
||||||
|
mandatory_keys = ["SECRET_KEY"]
|
||||||
|
|
||||||
|
for item in mandatory_keys:
|
||||||
|
if not os.environ.get(item):
|
||||||
|
raise CommandError(f"{item} env variable is required.")
|
||||||
|
|
||||||
config_keys = [
|
config_keys = [
|
||||||
# Authentication Settings
|
# Authentication Settings
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user