Fix CICD
This commit is contained in:
parent
4dd9498811
commit
6d3def79f6
5 changed files with 68 additions and 19 deletions
|
@ -52,25 +52,20 @@ def main(watchFolder: str):
|
|||
# Get exposed ports
|
||||
exposedPorts = getExposedPortsFromDockerComposeFile(dockerComposeFile)
|
||||
ports[dockerComposeFile] = exposedPorts
|
||||
if len(exposedPorts) == 0:
|
||||
if len(exposedPorts) != 0:
|
||||
print(f"\n📦 {dockerComposeFile}"
|
||||
f"\n🔴 No exposed ports found"
|
||||
f"\n")
|
||||
else:
|
||||
print(f"\n📦 {dockerComposeFile}"
|
||||
f"\n🔗 Exposed ports: {exposedPorts}"
|
||||
f"\n")
|
||||
f"\n🔗 Exposed ports: {exposedPorts}")
|
||||
|
||||
wrong = checkPortUnique(ports)
|
||||
|
||||
if wrong:
|
||||
exit(1)
|
||||
else:
|
||||
print("\n\n✅ All ports are unique\n\n")
|
||||
print("\n✅ All ports are unique")
|
||||
exit(0)
|
||||
|
||||
if __name__ == "__main__":
|
||||
print("Traefik label watcher CI/CD")
|
||||
print("Port Attribution Watcher")
|
||||
# Read folder from env
|
||||
watchFolder = os.getenv("WATCH_FOLDER")
|
||||
if watchFolder == None:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue