From 04506c4496e5ca8b3bc38e28ed70945a145fb036 Mon Sep 17 00:00:00 2001 From: Frederick Muriuki Muriithi Date: Mon, 4 Nov 2024 10:13:01 -0600 Subject: Define REQUESTS_CA_BUNDLE envvar for python-requests Define the `REQUESTS_CA_BUNDLE` for all applications that make use of python's requests library. The library needs to know the location of valid CA certificates in order to work as expected. --- genenetwork/services/genenetwork.scm | 26 ++++++++++++++++++++++---- 1 file changed, 22 insertions(+), 4 deletions(-) diff --git a/genenetwork/services/genenetwork.scm b/genenetwork/services/genenetwork.scm index ec66f64..1ea9ae2 100644 --- a/genenetwork/services/genenetwork.scm +++ b/genenetwork/services/genenetwork.scm @@ -349,6 +349,9 @@ object." ("PLINK_COMMAND" ,(file-append gn2-profile "/bin/plink2")) ("SQL_URI" ,sql-uri) ("AI_SEARCH_ENABLED" "True"))))) + (gn3-profile (profile + (content (package->development-manifest genenetwork3)) + (allow-collisions? #t))) (gn3-conf (computed-file "gn3.conf" (configuration-file-gexp `(("AUTH_DB" ,auth-db) @@ -360,6 +363,9 @@ object." ("GENOTYPE_FILES" ,genotype-files) ("REAPER_COMMAND" ,(file-append gn2-profile "/bin/qtlreaper")) ("LLM_DB_PATH" ,llm-db-path))))) + (gn-auth-profile (profile + (content (package->development-manifest gn-auth)) + (allow-collisions? #t))) (gn-auth-conf (computed-file "gn-auth.conf" (configuration-file-gexp `(("GN_AUTH_SECRETS" ,(string-append gn-auth-secrets "/gn-auth-secrets.py")) @@ -387,7 +393,10 @@ object." (value gn2-conf)) (environment-variable (name "HOME") - (value "/tmp")))) + (value "/tmp")) + (environment-variable + (name "REQUESTS_CA_BUNDLE") + (value (file-append gn2-profile "/etc/ssl/certs/ca-certificates.crt"))))) (mappings (list database-mapping (file-system-mapping (source genotype-files) @@ -435,7 +444,10 @@ object." (value gn3-secrets)) (environment-variable (name "HOME") - (value "/tmp")))) + (value "/tmp")) + (environment-variable + (name "REQUESTS_CA_BUNDLE") + (value (file-append gn3-profile "/etc/ssl/certs/ca-certificates.crt"))))) (mappings (list database-mapping (file-system-mapping (source gn3-conf) @@ -482,7 +494,10 @@ object." (value "/tmp")) (environment-variable (name "AUTHLIB_INSECURE_TRANSPORT") - (value "true")))) + (value "true")) + (environment-variable + (name "REQUESTS_CA_BUNDLE") + (value (file-append gn-auth-profile "/etc/ssl/certs/ca-certificates.crt"))))) (mappings (list database-mapping (file-system-mapping (source gn-auth-conf) @@ -630,7 +645,10 @@ a @code{} record." (value "/tmp")) (environment-variable (name "GN_UPLOADER_ENVIRONMENT") - (value gn-uploader-profile)))) + (value gn-uploader-profile)) + (environment-variable + (name "REQUESTS_CA_BUNDLE") + (value (file-append gn-uploader-profile "/etc/ssl/certs/ca-certificates.crt"))))) (mappings (list database-mapping (file-system-mapping (source gn-uploader-conf) -- cgit v1.2.3