util: move get_host_storage() to a separate module
Add a new util module called host which is used for functions that are meant for interactions with the host. These functions should not be used in stages. The containers.get_host_storage() function is renamed to host.get_container_storage() for clarity, since it is no longer namespaced under containers.
This commit is contained in:
parent
bce908e4a2
commit
07a597481b
4 changed files with 24 additions and 22 deletions
|
|
@ -18,7 +18,7 @@ import subprocess as sp
|
|||
import sys
|
||||
|
||||
from osbuild import sources
|
||||
from osbuild.util import containers
|
||||
from osbuild.util import host
|
||||
|
||||
SCHEMA = """
|
||||
"additionalProperties": false,
|
||||
|
|
@ -49,7 +49,7 @@ class ContainersStorageSource(sources.SourceService):
|
|||
Construct the full image name that references an image with a given checksum in the local storage.
|
||||
"""
|
||||
if self.storage_conf is None:
|
||||
conf = containers.get_host_storage()
|
||||
conf = host.get_container_storage()
|
||||
driver = conf["storage"]["driver"]
|
||||
graphroot = conf["storage"]["graphroot"]
|
||||
runroot = conf["storage"]["runroot"]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue