
- package: tis-postgresql
- name: PostgreSQL
- version: 17.6-3
- categories: System and network
- maintainer: WAPT TEAM, SEGAT GAETAN, ALLARD THIBAUT
- target_os: windows
- impacted_process: postgres,pg_ctl
- architecture: x64
- signature_date:
- size: 361.35 Mo
package : tis-postgresql
version : 17.6-3
architecture : x64
section : base
priority : optional
name : PostgreSQL
categories : System and network
maintainer : WAPT TEAM, SEGAT GAETAN, ALLARD THIBAUT
description : PostgreSQL is a relational and object database management system.
depends :
conflicts :
maturity : PROD
locale :
target_os : windows
min_wapt_version : 2.5
sources : https://www.enterprisedb.com/downloads/postgres-postgresql-downloads
installed_size :
impacted_process : postgres,pg_ctl
description_fr : PostgreSQL est un système de gestion de base de données relationnelle et objet.
description_pl :
description_de :
description_es :
description_pt :
description_it :
description_nl :
description_ru :
audit_schedule :
editor :
keywords :
licence :
homepage :
package_uuid : 26ba934f-2932-4201-afe2-1d5bf9571c99
valid_from :
valid_until :
forced_install_on :
changelog :
min_os_version : 10
max_os_version :
icon_sha256sum : ced24d01ab0a984121c3ab089f4961f34e141b0ecdcaa120b86f1a460a94fe07
signer : Tranquil IT
signer_fingerprint: 8c5127a75392be9cc9afd0dbae1222a673072c308c14d88ab246e23832e8c6bb
signature_date : 2025-08-19T13:02:29.000000
signed_attributes : package,version,architecture,section,priority,name,categories,maintainer,description,depends,conflicts,maturity,locale,target_os,min_wapt_version,sources,installed_size,impacted_process,description_fr,description_pl,description_de,description_es,description_pt,description_it,description_nl,description_ru,audit_schedule,editor,keywords,licence,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
signature : Se13E1IS2U5u1LuRCWgLAFfPkj9g+JGVIC3Dwf5UXH1w9h4lm2h0LoYPYE97rTOBtgK0eHDR7nP9N5eOp+Kk1nXKwk5ABY7lQEdTSvQyM7QFVBU/R8ZrXfhQ82cAMWGdDsBGY+HXe0XpfMNre6jqsI7nn1MrGaV1JwYKjOVdJaBb4Mzy5MLSsbl2mrJDft/ulWT4GQtLHdukiXBAKuzi8cyrM8F89ErE6h/Aa2+dCL1i+DRZ9pvC7tJR9rkmByzqSPukOMyFIAc1jKLTo/ga9PNPABMyauIH6inJnILCbGM7Kb147w9kxb3Y3ss55Lxmx3H8LlBKXG3twrJ2eyoXEA==
# -*- coding: utf-8 -*-
from setuphelpers import *
import base64
import json
"""
Usable WAPT package functions: install(), uninstall(), session_setup(), audit(), update_package()
"""
# Declaring global variables - Warnings: 1) WAPT context is only available in package functions; 2) Global variables are not persistent between calls
bin_contains = "postgresql-"
def install():
# Declaring local variables
package_version = control.get_software_version()
bin_name = glob.glob("*%s*.exe" % bin_contains)[0]
app_uninstallkey = "PostgreSQL %s" % package_version.split('.')[0]
silent_args = "--unattendedmodeui none --mode unattended --enable-components server"
# Removing old version
for soft in installed_softwares("PostgreSQL %s" % package_version):
if Version(soft["version"]) < Version(package_version):
print("Uninstalling old version: %s" % soft["version"])
run(uninstall_cmd(soft["key"]))
# Installing the software
print("Installing: %s" % bin_name)
install_exe_if_needed(
bin_name,
silentflags=silent_args,
key=app_uninstallkey,
min_version=bin_name.replace('postgresql-','').replace('-windows-x64.exe',''), # version displayed in registry contains "-"
timeout=600,
)
# Adding quiet uninstall string to registry
uninstallstring = installed_softwares(app_uninstallkey)[0]['uninstall_string']
register_uninstall(app_uninstallkey,quiet_uninstall_string=f'{uninstallstring} --mode unattended')
# -*- coding: utf-8 -*-
from setuphelpers import *
import os
r"""
Usable WAPT package functions: install(), uninstall(), session_setup(), audit(), update_package()
"""
def update_package():
package_updated = False
proxies = get_proxies_from_wapt_console()
if not proxies:
proxies = get_proxies()
app_name = control.name
url = "https://www.enterprisedb.com/downloads/postgres-postgresql-downloads"
# Send a GET request to the URL
response = requests.get(url)
# Check if the request was successful
if response.status_code == 200:
# Find the <tbody> tag
tbody = bs_find(
url,
"tbody",
user_agent="Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Firefox/91.0",
proxies=proxies,
features='html.parser',
)
if tbody:
# Find the first line in the tbody
first_row = tbody.find('tr')
if first_row:
# Find all columns in first row
columns = first_row.find_all('td')
# Check if there are at least 5 columns
if len(columns) >= 5:
# Check the contents of the first column
version = str(columns[0].text.strip())
print("Contenu de la première colonne :", version)
# Retrieve the 5th column
fifth_column = columns[4]
# Find an <a> tag with a href starting with "https"
download_url = fifth_column.find('a', href=lambda href: href and href.startswith("https"))
if download_url:
# Show found link
print("Lien trouvé dans la 5ème colonne :", download_url['href'])
# We prefer keeping the original binary name because it contains the version displayed in Windows registry
bin_name = requests.head(download_url['href']).headers['Location'].split('/')[-1]
wget(download_url['href'], bin_name)
control.set_software_version(version)
control.save_control_to_wapt()
package_updated = True
print("Software version is up-to-date (%s)" % Version(version))
else:
print("Aucun lien commençant par 'https' n'a été trouvé dans la 5ème colonne.")
else:
print("Il n'y a pas suffisamment de colonnes dans la première ligne.")
else:
print("La première ligne dans <tbody> n'a pas été trouvée.")
else:
print("Aucun <tbody> n'a été trouvé sur la page.")
else:
print("Erreur lors de la requête :", response.status_code)
remove_outdated_binaries(version, filename_contains="postgresql-")
return package_updated
38d056ab130f7bf7c481c12636a4e9959de36561d3dfcbe54c6e3571bc0c1dc3 : WAPT/certificate.crt
90aa807cc0b4363034474a691c321545b0e3d99b58a2f718b0c478a51611ccf7 : WAPT/control
ced24d01ab0a984121c3ab089f4961f34e141b0ecdcaa120b86f1a460a94fe07 : WAPT/icon.png
0c807a18f7fd65342cfd11417f4027a814c6c1a023720bcca4617c5303f9e39e : luti.json
0ffbd42f3777338ed629686349c905f37a657074c4da410b1e3ac61fe38d23a0 : postgresql-17.6-1-windows-x64.exe
90f9576799596a9ddf9ae050dcbc5618eb867bf53032e40dc4367638be26b592 : setup.py
eee62b5396c52f3cee22f46cb515d83d0edba17e8cfa6118bb7ab1d7a87c92dc : update_package.py