Skip to content
This repository was archived by the owner on Apr 4, 2025. It is now read-only.

fix(@schematics/update): Allow usage strict SSL configuration #838

Merged
merged 1 commit into from
May 14, 2018
Merged
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
8 changes: 8 additions & 0 deletions packages/schematics/update/update/npm.ts
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@ export function getNpmPackageJson(
return concat(
getNpmConfigOption('proxy'),
getNpmConfigOption('https-proxy'),
getNpmConfigOption('strict-ssl'),

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is getNpmConfigOption('strict-ssl') provides true default when strict-ssl is missing in config?

).pipe(
toArray(),
concatMap(options => {
Expand All @@ -101,6 +102,13 @@ export function getNpmPackageJson(
http: options[0],
https: options[1],
},
ssl: {
...(options[2] === 'false'
? { strict: false }
: (options[2] === 'true'
? { strict: true }
: {})),
},
});
client.log.level = 'silent';
const params = {
Expand Down