try https
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 6m31s

This commit is contained in:
Pierre Geeraert
2025-12-02 16:45:04 +00:00
parent 6b46873009
commit 2483e71d98
+6 -2
View File
@@ -15,7 +15,11 @@ import yaml
from urllib import request as urlrequest from urllib import request as urlrequest
proxy_host = "gluetun-svc.gluetun.svc:8888" proxy_host = "gluetun-svc.gluetun.svc:8888"
proxy_url = 'http://gluetun-svc.gluetun.svc:8888'
proxy = urlrequest.ProxyHandler({
'http': proxy_url,
'https': proxy_url # Add the handler for HTTPS
})
def hello(request): def hello(request):
return HttpResponse('<h1>Hello stash!</h1>') return HttpResponse('<h1>Hello stash!</h1>')
@@ -73,7 +77,7 @@ def increment_and_download(minimum_increment,maximum_increment,url,url_suffix,st
elif len(str(increment)) == 1: elif len(str(increment)) == 1:
increment_generated ='000' + str(increment) increment_generated ='000' + str(increment)
proxy = urlrequest.ProxyHandler({'http': 'http://gluetun-svc.gluetun.svc:8888'}) proxy = urlrequest.ProxyHandler({'https': 'http://gluetun-svc.gluetun.svc:8888'})
opener = urlrequest.build_opener(proxy) opener = urlrequest.build_opener(proxy)
urlrequest.install_opener(opener) urlrequest.install_opener(opener)
urlrequest.urlretrieve(url+increment_generated+url_suffix, stash_folder+"/"+increment_generated+url_suffix) urlrequest.urlretrieve(url+increment_generated+url_suffix, stash_folder+"/"+increment_generated+url_suffix)