From: zimoun <zimon.toutoune@gmail.com>
To: "Wiktor Żelazny" <wz@freeshell.de>,
help-guix@gnu.org, "Konrad Hinsen" <konrad.hinsen@fastmail.net>
Subject: Re: Certificates in pure and containerized environments
Date: Mon, 04 Oct 2021 09:25:13 +0200 [thread overview]
Message-ID: <86v92ddzfq.fsf@gmail.com> (raw)
In-Reply-To: <20211003164510.ebwlm6u24a2bgao4@wzguix>
Hi Konrad and Wiktór,
On Sun, 03 Oct 2021 at 18:45, Wiktor Żelazny <wz@freeshell.de> wrote:
> On Thu, Sep 30, 2021 at 12:08:53PM +0200, Konrad Hinsen wrote:
>
>> guix environment --pure \
>> --ad-hoc python nss-certs -- \
>> python3 -c 'import urllib.request; print(urllib.request.urlopen("http://wwwbis.sidc.be/DATA/uset/Wlight/2003/11/UPH20031109112104.FTS"))'
>>
>> but this doesn't work - same error as initially.
Yeah for some reasom SSL_CERT_DIR is not exported…
> For some reason, it works for me with
>
> --ad-hoc python nss-certs guix -- \
…but exported here.
--8<---------------cut here---------------start------------->8---
$ guix environment --ad-hoc python nss-certs
$ cat $GUIX_ENVIRONMENT/etc/profile
# Source this file to define all the relevant environment variables in Bash
# for this profile. You may want to define the 'GUIX_PROFILE' environment
# variable to point to the "visible" name of the profile, like this:
#
# GUIX_PROFILE=/path/to/profile ; \
# source /path/to/profile/etc/profile
#
# When GUIX_PROFILE is undefined, the various environment variables refer
# to this specific profile generation.
export PATH="${GUIX_PROFILE:-/gnu/store/bp1xirq9p5cw36nkgi1131knhmhdzcvf-profile}/bin${PATH:+:}$PATH"
export PYTHONPATH="${GUIX_PROFILE:-/gnu/store/bp1xirq9p5cw36nkgi1131knhmhdzcvf-profile}/lib/python3.8/site-packages${PYTHONPATH:+:}$PYTHONPATH"
--8<---------------cut here---------------end--------------->8---
If any package depending on nss-certs is added, then it works, I guess.
For instance, a package totally unrelated, say r-reqon:
--8<---------------cut here---------------start------------->8---
$ guix environment --ad-hoc python nss-certs r-reqon
$ cat $GUIX_ENVIRONMENT/etc/profile
# Source this file to define all the relevant environment variables in Bash
# for this profile. You may want to define the 'GUIX_PROFILE' environment
# variable to point to the "visible" name of the profile, like this:
#
# GUIX_PROFILE=/path/to/profile ; \
# source /path/to/profile/etc/profile
#
# When GUIX_PROFILE is undefined, the various environment variables refer
# to this specific profile generation.
export PATH="${GUIX_PROFILE:-/gnu/store/mj821vsw16c8krqm2c4syg2mdfzqy3j0-profile}/bin${PATH:+:}$PATH"
export CURL_CA_BUNDLE="${GUIX_PROFILE:-/gnu/store/mj821vsw16c8krqm2c4syg2mdfzqy3j0-profile}/etc/ssl/certs/ca-certificates.crt"
export SSL_CERT_FILE="${GUIX_PROFILE:-/gnu/store/mj821vsw16c8krqm2c4syg2mdfzqy3j0-profile}/etc/ssl/certs/ca-certificates.crt"
export SSL_CERT_DIR="${GUIX_PROFILE:-/gnu/store/mj821vsw16c8krqm2c4syg2mdfzqy3j0-profile}/etc/ssl/certs"
export PYTHONPATH="${GUIX_PROFILE:-/gnu/store/mj821vsw16c8krqm2c4syg2mdfzqy3j0-profile}/lib/python3.8/site-packages${PYTHONPATH:+:}$PYTHONPATH"
--8<---------------cut here---------------end--------------->8---
Hope that helps,
simon
next prev parent reply other threads:[~2021-10-04 7:30 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-09-30 10:08 Certificates in pure and containerized environments Konrad Hinsen
2021-10-03 16:45 ` Wiktor Żelazny
2021-10-04 7:25 ` zimoun [this message]
2021-10-04 9:37 ` Konrad Hinsen
2021-10-04 10:04 ` zimoun
2021-10-10 15:42 ` Wiktor Żelazny
2021-10-11 6:27 ` Konrad Hinsen
2021-10-05 17:42 ` Maxim Cournoyer
2021-10-08 8:47 ` Konrad Hinsen
2021-10-11 15:05 ` Maxim Cournoyer
2021-10-13 11:51 ` Konrad Hinsen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=86v92ddzfq.fsf@gmail.com \
--to=zimon.toutoune@gmail.com \
--cc=help-guix@gnu.org \
--cc=konrad.hinsen@fastmail.net \
--cc=wz@freeshell.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).