- Access exclusive content
- Connect with peers
- Share your expertise
- Find support resources
Enhanced Security Measures in Place: To ensure a safer experience, we’ve implemented additional, temporary security measures for all users.
10-08-2024 06:10 AM - edited 10-08-2024 07:33 AM
Hi Everyone
I'm trialling scanning of container images with Prisma Cloud. I'm finding myself stuck where the result of the scan cannot be found and the workflow fails. THis happens during the PrismaCloudScanImage function rather than the later PrismaCloudPublish one. The error message is as follow:
[PrismaCloud_DemoBuild] $ /home/jenkins/workspace/PrismaCloud_DemoBuild/twistcli18328331056399694186 images scan --docker-address tcp://192.168.0.179:12375 --ci --publish --details --address https://europe-west9.cloud.twistlock.com/france-607222237 --ci-results-file prisma-cloud-scan-results.json dev/my-ubuntu:68
[PRISMACLOUD] failed to augment data: API error (404): Could not find the file /var/lib/twistlock/analysis/result in container
A bit about the docker setup (This is a lab environment i have no concerns about security)
Below is the pipeline script which is the example taken from the documentation
Any thoughts ?
pipeline {
agent {label 'alpine-dockercli'}
stages{
stage('createImage') {
steps{
sh 'echo "Creating Dockerfile..."'
sh 'echo "FROM ubuntu:bionic" > Dockerfile'
sh 'echo "ENV MYSQL_HOST=DB_Server" >> Dockerfile'
sh 'echo "ENV MYSQL_PASSWORD=5TTnvuTDJJSq6" >> Dockerfile'
sh 'echo "LABEL description=Test_Twistlock_Jenkins_Plugin" >> Dockerfile'
sh '''docker -H=tcp://192.168.0.179:12375 build --no-cache -t dev/my-ubuntu:$BUILD_NUMBER .'''
}
}
}
stage('twistlockScan') {
steps{
prismaCloudScanImage ca: '', cert: '', dockerAddress: 'tcp://192.168.0.179:12375', ignoreImageBuildTime: true, image: 'dev/my-ubuntu:$BUILD_NUMBER', key: '', logLevel: 'debug', podmanPath: '', project: '', resultsFile: 'prisma-cloud-scan-results.json', sbom: ''
input "stop"
}
}
stage('twistlockPublish') {
steps{
prismaCloudPublish resultsFilePattern: 'prisma-cloud-scan-results.json'
}
}
}
}
Click Accept as Solution to acknowledge that the answer to your question has been provided.
The button appears next to the replies on topics you’ve started. The member who gave the solution and all future visitors to this topic will appreciate it!
These simple actions take just seconds of your time, but go a long way in showing appreciation for community members and the LIVEcommunity as a whole!
The LIVEcommunity thanks you for your participation!