Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: changed config instance to allow for ENV_VAR or cwd check for .env and .ini files #715

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion packages/opal-common/opal_common/confi/confi.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,13 @@
import inspect
import json
import logging
import os
import string
from collections import OrderedDict
from functools import partial, wraps
from typing import Any, Callable, Dict, List, Optional, Tuple, TypeVar, Union

from decouple import Csv, UndefinedValueError, config, text_type, undefined
from decouple import AutoConfig, Csv, UndefinedValueError, text_type, undefined
from opal_common.authentication.casting import cast_private_key, cast_public_key
from opal_common.authentication.types import EncryptionKeyFormat, PrivateKey, PublicKey
from opal_common.confi.cli import get_cli_object_for_config_objects
Expand All @@ -22,6 +23,8 @@
from typer import Typer


config = AutoConfig(os.environ.get("CONFI_PATH") or os.getcwd())

class Placeholder(object):
"""Placeholder instead of default value for decouple."""

Expand Down
Loading