Compare commits

...

2 Commits

@ -99,10 +99,10 @@ while is_on:
else:
stateChanged = False
# old file removal must happen after state tracking:
# delete state.log so I can write to it cleanly
os.remove("/shared/state.log")
# queue up an alert if stateChanged = True
results = []
with open("/shared/results.json", "r") as json_File:
for line in json_File:
@ -114,7 +114,7 @@ while is_on:
errorText = key + " returned with status " + str(value) + "\n"
errorFile.write(errorText)
# track state
# Copy current results to state.log file for next iteration
errorFile = open("/shared/state.log", "a+")
errorFile.write(json_string)
errorFile.write(cert_json)

@ -7,13 +7,12 @@ RUN apk update
RUN apk add \
python3 \
python-dev \
py-cryptography
py-cryptography \
py3-openssl
RUN python3 -m pip install --upgrade pip \
&& pip3 install requests \
&& pip3 install whois \
&& pip3 install pyopenssl
&& pip3 install whois
COPY ./ ./

Loading…
Cancel
Save