Fix package endswith error
This commit is contained in:
parent
3c04a58570
commit
b972f1274a
@ -125,11 +125,11 @@ for service in SERVICES:
|
|||||||
|
|
||||||
print("[ ADDING PACKAGES TO FREIGHT LIBRARY ]")
|
print("[ ADDING PACKAGES TO FREIGHT LIBRARY ]")
|
||||||
# loop through all files in the microservices deb directory
|
# loop through all files in the microservices deb directory
|
||||||
for filename in os.scandir(MICROSERVICES_DEB_DIR):
|
for package in os.scandir(MICROSERVICES_DEB_DIR):
|
||||||
# avoid any files which are not debian packages
|
# avoid any files which are not debian packages
|
||||||
if filename.endswith(".deb"):
|
if package.name.endswith(".deb"):
|
||||||
print("[ ADDING PACKAGE {} ]".format(filename.name))
|
print("[ ADDING PACKAGE {} ]".format(package.name))
|
||||||
subprocess.call(["freight", "add", "-c", FREIGHT_CONF, filename.path, "apt/buster"])
|
subprocess.call(["freight", "add", "-c", FREIGHT_CONF, package.path, "apt/buster"])
|
||||||
|
|
||||||
print("[ ADDING PACKAGES TO FREIGHT CACHE ]")
|
print("[ ADDING PACKAGES TO FREIGHT CACHE ]")
|
||||||
# needs to be run as sudo user
|
# needs to be run as sudo user
|
||||||
|
Loading…
x
Reference in New Issue
Block a user