Pa11y: Injection des identifiants Basic Auth dans la configuration
This commit is contained in:
parent
f3e5f7b9ef
commit
ffe16b7927
@ -2,5 +2,11 @@
|
||||
"chromeLaunchConfig": {
|
||||
"args": ["--disable-dev-shm-usage", "--no-sandbox", "--disable-gpu"],
|
||||
"ignoreHTTPSErrors": true
|
||||
},
|
||||
"headers": {
|
||||
{{if not (empty .PA11Y_USERNAME)}}
|
||||
{{ $credentials := print .PA11Y_USERNAME ":" .PA11Y_PASSWORD }}
|
||||
"Authorization": "Basic {{b64enc $credentials}}"
|
||||
{{end}}
|
||||
}
|
||||
}
|
@ -1,10 +1,15 @@
|
||||
def audit(String url, Map params = [:]) {
|
||||
def reporter = params.reporter ? params.reporter : 'html'
|
||||
def username = params.username ? params.username : '';
|
||||
def password = params.password ? params.password : '';
|
||||
|
||||
def pa11yImage = buildDockerImage()
|
||||
|
||||
def dockerArgs = """
|
||||
-e PA11Y_REPORTER='${reporter}'
|
||||
-e PA11Y_URL='${url}'
|
||||
-e PA11Y_USERNAME='${username}'
|
||||
-e PA11Y_PASSWORD='${password}'
|
||||
"""
|
||||
|
||||
pa11yImage.inside(dockerArgs) {
|
||||
|
Loading…
Reference in New Issue
Block a user