Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add SSL_CERT_DIR and SSL_CERT_FILE to the default for [subprocess-environment].env_vars #14808

Merged
merged 3 commits into from
Mar 16, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,6 @@ jobs:
build_wheels_linux:
container: quay.io/pypa/manylinux2014_x86_64:latest
env:
PANTS_CA_CERTS_PATH: /opt/_internal/certs.pem
PANTS_REMOTE_CACHE_READ: 'false'
PANTS_REMOTE_CACHE_WRITE: 'false'
if: ${{ github.repository_owner == 'pantsbuild' }}
Expand Down
5 changes: 1 addition & 4 deletions build-support/bin/generate_github_workflows.py
Original file line number Diff line number Diff line change
Expand Up @@ -487,10 +487,7 @@ def build_steps(*, is_macos: bool) -> list[Step]:
"runs-on": LINUX_VERSION,
"container": "quay.io/pypa/manylinux2014_x86_64:latest",
"timeout-minutes": 65,
"env": {
**DISABLE_REMOTE_CACHE_ENV,
"PANTS_CA_CERTS_PATH": "/opt/_internal/certs.pem",
},
"env": DISABLE_REMOTE_CACHE_ENV,
"if": IS_PANTS_OWNER,
"steps": [
*checkout(),
Expand Down
9 changes: 6 additions & 3 deletions src/python/pants/core/util_rules/subprocess_environment.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
from pants.engine.rules import Get, collect_rules, rule
from pants.option.option_types import StrListOption
from pants.option.subsystem import Subsystem
from pants.util.docutil import doc_url
from pants.util.frozendict import FrozenDict


Expand All @@ -20,11 +21,13 @@ class SubprocessEnvironment(Subsystem):

_env_vars = StrListOption(
"--env-vars",
default=["LANG", "LC_CTYPE", "LC_ALL"],
default=["LANG", "LC_CTYPE", "LC_ALL", "SSL_CERT_FILE", "SSL_CERT_DIR"],
help=(
"Environment variables to set for process invocations. "
"Environment variables to set for process invocations.\n\n"
"Entries are either strings in the form `ENV_VAR=value` to set an explicit value; "
"or just `ENV_VAR` to copy the value from Pants's own environment."
"or just `ENV_VAR` to copy the value from Pants's own environment.\n\n"
f"See {doc_url('options#addremove-semantics')} for how to add and remove Pants's "
"default for this option."
),
advanced=True,
)
Expand Down