Skip to content

Commit

Permalink
enroll: make flavor spec directory configurable
Browse files Browse the repository at this point in the history
  • Loading branch information
skrobul committed Nov 27, 2024
1 parent d504e52 commit ad51616
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import os

from flavor_matcher.machine import Machine
from flavor_matcher.matcher import FlavorSpec
from flavor_matcher.matcher import Matcher
Expand All @@ -8,7 +10,8 @@
from understack_workflows.helpers import setup_logger

logger = setup_logger(__name__)
FLAVORS = FlavorSpec.from_directory("/etc/understack_flavors/")
FLAVORS_DIR = os.getenv("FLAVORS_DIR", "/etc/understack_flavors/")
FLAVORS = FlavorSpec.from_directory(FLAVORS_DIR)
logger.info(f"Loaded {len(FLAVORS)} flavor specifications.")


Expand Down

0 comments on commit ad51616

Please sign in to comment.