Skip to content
Snippets Groups Projects
Commit 1d0df598 authored by Thibault's avatar Thibault
Browse files

Retour sur ancien jenkins file pour clair

parent 3cd89b57
No related branches found
No related tags found
No related merge requests found
node{
def app
def registryProject='http://172.20.0.2:8083/repository/RegistryDocker/'
def registryProject='http://127.0.0.1:8083'
def image="${registryProject}:version-${env.BUILD_ID}"
stage('Clone') {
checkout scm
......@@ -29,14 +27,15 @@ node{
stage('Scan Clair'){
sh '''
wget -qO clair-scanner https://github.com/arminc/clair-scanner/releases/download/v8/clair-scanner_linux_amd64 && chmod +x clair-scanner
./clair-scanner --report="rapClair" --ip="172.20.0.4" --clair="http://172.20.0.6:6060" debian:buster || exit 0
wget -qO clair-scanner https://github.com/arminc/clair-scanner/releases/download/v8/clair-scanner_linux_amd64 && chmod +x clair-scanner
./clair-scanner --report="rapportClair" --ip="172.20.0.4" --clair="http://172.20.0.6:6060" debian:buster || exit 0
'''
}
stage('Push on repo nexus'){
docker.withRegistry(registryProject,'Jenkins-credential'){
app.push ()
docker.withRegistry(registryProject,'reg2'){
img.push 'latest'
img.push
}
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment