forked from public/mirror-checker
22 lines
578 B
Python
22 lines
578 B
Python
#!/usr/bin/env python3
|
|
|
|
"""
|
|
This mirror status checker determines whether CSC mirror is up-to-date with upstream
|
|
"""
|
|
|
|
import requests
|
|
from arch import Arch
|
|
from ceph import Ceph
|
|
from debian import Debian
|
|
from eclipse import Eclipse
|
|
from gnu import GNU
|
|
from kernel import Kernel
|
|
from openbsd import OpenBSD
|
|
|
|
if __name__ == "__main__":
|
|
for distro in [Arch, Ceph, Debian, Eclipse, GNU, Kernel, OpenBSD]:
|
|
try:
|
|
distro.print_output(distro.check())
|
|
except requests.exceptions.RequestException as err:
|
|
print(f"Error: {distro.name()}\n{err}")
|