From 2d810ffe982b0dd1dc19b0b3e8b72e56729a1938 Mon Sep 17 00:00:00 2001 From: Pierre COSSON Date: Tue, 5 Sep 2023 16:33:48 +0200 Subject: [PATCH] first commit --- .gitignore | 41 +++++++++++++++++++++++++++ all/WAPT/control | 43 +++++++++++++++++++++++++++++ all/WAPT/icon.png | Bin 0 -> 2756 bytes all/setup.py | 69 ++++++++++++++++++++++++++++++++++++++++++++++ all/wapt_api.ini | 4 +++ 5 files changed, 157 insertions(+) create mode 100644 .gitignore create mode 100644 all/WAPT/control create mode 100644 all/WAPT/icon.png create mode 100644 all/setup.py create mode 100644 all/wapt_api.ini diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..f6fbb96 --- /dev/null +++ b/.gitignore @@ -0,0 +1,41 @@ +# Do not commit binaries: +*.exe +*.msu +*.msi +*.zip +*.rpm +*.deb +*.yum +*.dmg +*.vsix +*.appx +*.appxbundle +*.msix +*.msixbundle +*.iso +*.cab +*.pkg +*.jar +*.msp +*.part +*.bak + +# Do not commit generated WAPT files: +*.pyc +*.crt +*.sha256 +*.wapt +.env +*.psproj +**/.vscode/ +signature +*.sha1 + +# Do not commit template part: +template.py +.vscode/*.json +code_template.cmd +/template +package_template.py + +# Specific to this package (use ! as prefix to allow commit): diff --git a/all/WAPT/control b/all/WAPT/control new file mode 100644 index 0000000..ea48768 --- /dev/null +++ b/all/WAPT/control @@ -0,0 +1,43 @@ +package : comi-apps-to-update-on-wapt-server +version : 0-10 +architecture : all +section : base +priority : optional +name : json-update +categories : Utilities +maintainer : Comitari,pcosson +description : Package to audit the wapt-server and generate a json with applications that are not up to date +depends : +conflicts : +maturity : PROD +locale : all +target_os : all +min_wapt_version : 2.3 +sources : +installed_size : +impacted_process : +description_fr : Package pour auditer le serveur wapt et générer un json avec les applications qui ne sont pas à jour +description_pl : Pakiet do audytu serwera wapt i generowania pliku json z aplikacjami, które nie są aktualne +description_de : Paket zur Überprüfung des wapt-Servers und zur Erstellung eines json mit Anwendungen, die nicht auf dem neuesten Stand sind +description_es : Paquete para auditar el servidor wapt y generar un json con las aplicaciones que no están actualizadas +description_pt : Pacote para auditar o wapt-server e gerar um json com as aplicações que não estão atualizadas +description_it : Pacchetto per verificare il server wapt e generare un json con le applicazioni che non sono aggiornate +description_nl : Pakket om de wapt-server te controleren en een json te genereren met applicaties die niet up-to-date zijn +description_ru : Пакет для аудита wapt-сервера и генерации json с неактуальными приложениями +audit_schedule : +editor : +keywords : +licence : opensource_free,wapt_public +homepage : +package_uuid : +valid_from : +valid_until : +forced_install_on : +changelog : +min_os_version : +max_os_version : +icon_sha256sum : +signer : +signer_fingerprint: +signature_date : +signed_attributes : \ No newline at end of file diff --git a/all/WAPT/icon.png b/all/WAPT/icon.png new file mode 100644 index 0000000000000000000000000000000000000000..1f86e211f498b95d52f6ff9a5e4e8a8d4398a367 GIT binary patch literal 2756 zcmV;#3On_QP)}3XlyT`EB3TC#2FyJya%bq3Y25i zrOoEC%WA#}y#VBG>_&ReNvJU%(J_Flg~T1GwSsidBK%^t9Nrorzq|)&#+xW3a&e`8}@teC->v|sLX5bjgQm9|jxLsyPvN7~IAO|>vY91l)3r>$Rl8UeX z^e%#)CowG#$U1~^SY{;!ktv{E`|m_u&&I{SjgUdeliw)bSCNOI9|1WiE2&Kzl1w}_ z_kb@v1LgO?TU38~1FI**n!2e_Pw0dIheK_pCJbEFtK9ScN~BWKskAQ zmqXiMfOO2d$65u7IpJYM!y7@LLvzg9&Hw<1Pb~n-QGUhjijj_e zY#Y%qb%&%ER9p&t4{+E%*gHVXn}AOc?gDc=lCm3R3Q&b`Bk%2TYXbllBV?Il$rQa76D#SpmENl8dY63Y3XJ zCL$%2WFLq2iaB36fKmwjk?Kz$Y|IUX<=24mD$omM7s6$r&k*!X1<@qp%dl5}CP7b0 zoAWwqiA+az39uel%~<@S>)QwL?@lLr>?6PpS_!fNr9Z;Yu}9yIrE3vc3k-FHXf9sJ zC*XO^{yj1c(S?XLl0fz+ZR)TW>>c1R^~RMf$~xH4)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jS!##d+S*#jc7Txg<9JPU6pco2m<8Hp?=n4U>QYtG1W^!f5n|oT33+~)5ZQ!DaV>vu z0st_KUxM)qf}S@VC-a5J0=IyyBj7HxU-lVq13iFyPWv@%!gk`X6jt1nv~OYf0nlqv z))307ws|^Y{>n6>Ryi;bv4*3@G~hmj8dPs1=zaIJ#5cF5Jkb-8Ja$$+-53;dH>Yx* zD<7c#pKJT*lMu^HQ5bJf|Lf~^?BO)fM zR|9>4y;wSq1>SJOkd7VdRU1Oxkhu7#aG4{|sCa--))s2hazGvjQh`bFWEw+c0WRap z=Hj8F9+*|$A4BXy%P?yQWNkg8!jqZ5@;pw(l#utx|75;z!~P4vw6ZexF26?r0000< KMNUMnLSTX Version(transformed_package_dict[key]): + print("ajout de " + key + " à la liste des paquets à mettre à jour") + app_to_update_list.append({"package": key, "version": online_dict[key]}) + + with open(app_to_update_json_path, "w") as json_file: + json.dump(app_to_update_list, json_file) + return "OK" + + +def download_json_from_url(url): + try: + response = requests.get(url, verify=False) + response.raise_for_status() # Raise an exception for unsuccessful responses + json_data = response.json() + return json_data + except requests.exceptions.RequestException as e: + print(f"Error downloading JSON from URL: {e}") + return None diff --git a/all/wapt_api.ini b/all/wapt_api.ini new file mode 100644 index 0000000..3f2be2f --- /dev/null +++ b/all/wapt_api.ini @@ -0,0 +1,4 @@ +[wapt] +wapt_username = xxxxx +wapt_password = xxxxx +wapt_url =xxxxx \ No newline at end of file