Use Python libraries
parent
83208084b1
commit
ba9accc8de
|
@ -38,7 +38,8 @@ import NetLib
|
|||
import ogGlobals
|
||||
import SystemLib
|
||||
import logging
|
||||
|
||||
import DiskLib
|
||||
import NetLib
|
||||
|
||||
|
||||
|
||||
|
@ -49,7 +50,7 @@ def create_image(disk_num, partition_num, repo, image_name):
|
|||
|
||||
ntfs_impl = NTFSImplementation.NTFS3G
|
||||
og_git = OpengnsysGitLibrary(ntfs_implementation = ntfs_impl)
|
||||
device = og_git._runBashFunction("ogDiskToDev", [str(disk_num), str(partition_num)])
|
||||
device = DiskLib.ogDiskToDev(disk_num, partition_num)
|
||||
og_git.initRepo(device, image_name)
|
||||
|
||||
def main():
|
||||
|
@ -60,7 +61,7 @@ def main():
|
|||
|
||||
|
||||
opengnsys_log_dir = "/opt/opengnsys/log"
|
||||
ip_address = "unknown"
|
||||
ip_address = NetLib.ogGetIpAddress()
|
||||
logFilePath = f"{opengnsys_log_dir}/{ip_address}.CrearImagenGit.log"
|
||||
|
||||
fileLog = logging.FileHandler(logFilePath)
|
||||
|
|
Loading…
Reference in New Issue