Commit 71f70460 authored by Thomasa Balthazar's avatar Thomasa Balthazar

Upgrade to 0.2.2

What this upgrade does:
- renew the certificate
- add a daily cron job that will check if the certificate must be
  renewed

The `renew_from_cube` script only renew the cert if it will [expire in
less than 4
months](https://github.com/Neutrinet/renew_cert/blob/master/renew_from_cube.py#L29).
parent 7b649520
......@@ -15,12 +15,24 @@ fi
# 0.2 -> 0.2.1
if [[ "$version" == "0.2" ]]; then
get_out_of_testing
sudo yunohost app setting neutrinet version -v "0.2.1"
version="0.2.1"
cd /opt/neutrinet/renew_cert
cd $RENEW_CERT_PATH
sudo ve/bin/python renew_from_cube.py
fi
# 0.2.1 -> 0.2.2
if [[ "$version" == "0.2.1" ]]; then
sudo yunohost app setting neutrinet version -v "0.2.2"
version="0.2.2"
cd $RENEW_CERT_PATH
sudo ve/bin/python renew_from_cube.py
cat <<EOF > /etc/cron.daily/neutrinet-renew-cert.sh
#!/bin/bash
cd $RENEW_CERT_PATH && ve/bin/python renew_from_cube.py
EOF
chmod 0755 /etc/cron.daily/neutrinet-renew-cert.sh
fi
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment