Travis CI
Following is a sample code segment that can be configured in .travis.yml file to perform a SAST scan.
Note: Make sure to update the parameters in the sample code according to your environment before using it.
language: python
python:
- "3.6"
services:
- docker
jobs:
include:
- stage: SAST
script:
- env | grep -E "TRAVIS|TRAVIS_BUILD_ID|TRAVIS_BRANCH|TRAVIS_COMMIT" > /tmp/env
- docker run --pull always --rm --env-file /tmp/env --mount type=bind,source=$PWD,target=/scan registry.fortidevsec.forticloud.com/fdevsec_sast:latest
Following is a sample code segment that can be configured in .travis.yml file to perform a DAST scan.
language: python
python:
- "3.6"
services:
- docker
jobs:
include:
- stage: DAST
script:
- env | grep -E "TRAVIS|TRAVIS_BUILD_ID|TRAVIS_BRANCH|TRAVIS_COMMIT" > /tmp/env
- docker run --pull always --rm --env-file /tmp/env --mount type=bind,source=$PWD,target=/scan registry.fortidevsec.forticloud.com/fdevsec_dast:latest