Merge pull request #79478 from stefano-m/aws-sam-cli-no-telemetry

aws-sam-cli: disable telemetry
This commit is contained in:
Michele Guerini Rocco 2020-02-12 16:56:47 +01:00 committed by GitHub
commit c6ec7b613a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,5 +1,6 @@
{ lib { lib
, python , python
, enableTelemetry ? false
}: }:
let let
@ -56,6 +57,11 @@ buildPythonApplication rec {
tomlkit tomlkit
]; ];
postFixup = if enableTelemetry then "echo aws-sam-cli TELEMETRY IS ENABLED" else ''
# Disable telemetry: https://github.com/awslabs/aws-sam-cli/issues/1272
wrapProgram $out/bin/sam --set SAM_CLI_TELEMETRY 0
'';
# fix over-restrictive version bounds # fix over-restrictive version bounds
postPatch = '' postPatch = ''
substituteInPlace requirements/base.txt \ substituteInPlace requirements/base.txt \