Check whether our mirror packages are up to date.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
773 B

import requests
import datefinder # another date finding library
import re
from datetime import datetime
from project import Project
from shared import CSC_MIRROR
2 years ago
class saltstack(Project):
2 years ago
"""saltstack class"""
def check(data, project, current_time):
csc_url = CSC_MIRROR + data[project]["csc"] + data[project]["file"]
upstream_url = data[project]["upstream"] + data[project]["file"]
page1 = requests.get(csc_url).text
page2 = requests.get(upstream_url).text
CSC_release ='Latest release: (\d)+.(\d)+ \((.+)\)', page1)
upstream_release ='Latest release: (\d)+.(\d)+ \((.+)\)', page2)
2 years ago
# print(
# print(
2 years ago
return ==