mirror of
https://github.com/fjogeleit/http-request-action.git
synced 2026-02-04 16:45:52 +08:00
Add ignore ssl error (#145)
* add ignore ssl * build and update docs * keep the upstream formatting/indentation
This commit is contained in:
@@ -29,6 +29,9 @@ if (!!core.getInput('bearerToken')) {
|
||||
|
||||
/** @type {axios.AxiosRequestConfig} */
|
||||
const instanceConfig = {
|
||||
httpsAgent: new https.Agent({
|
||||
rejectUnauthorized: core.getInput('ignoreSsl') !== 'true',
|
||||
}),
|
||||
baseURL: core.getInput('url', { required: true }),
|
||||
timeout: parseInt(core.getInput('timeout') || 5000, 10),
|
||||
headers: { ...headers, ...customHeaders }
|
||||
@@ -102,4 +105,4 @@ request({ data, method, instanceConfig, files, file, actions, options }).then(re
|
||||
if (response && typeof response == 'object') {
|
||||
handler.forEach(h => h(response))
|
||||
}
|
||||
})
|
||||
})
|
||||
Reference in New Issue
Block a user