You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
44 lines
1.2 KiB
44 lines
1.2 KiB
pipeline {
|
|
agent any
|
|
|
|
parameters {
|
|
choice(name: 'ip_address', choices: ['52.220.220.29'], description: 'AWS IP address')
|
|
}
|
|
|
|
stages {
|
|
stage ('Create MongoDB Container') {
|
|
steps {
|
|
sh """mkdir -p /home/ubuntu/mongo"""
|
|
}
|
|
}
|
|
|
|
stage ('Running MongoDB Container') {
|
|
steps {
|
|
// sudo docker run -d --name mongo-db -v /home/ubuntu/mongo:/data/db -p 27017:27017 mongo:latest
|
|
echo "Execute MongoDB dockers"
|
|
}
|
|
}
|
|
}
|
|
|
|
post {
|
|
always {
|
|
// Clean up command + steps
|
|
echo "Done"
|
|
}
|
|
success {
|
|
// office365ConnectorSend webhookUrl: "${env.TEAMS_URL}"
|
|
// message: 'Alerts created and updated.',
|
|
// status: 'Success',
|
|
// color: '#00FF00'
|
|
// cleanWs()
|
|
echo "Success"
|
|
}
|
|
failure {
|
|
// office365ConnectorSend webhookUrl: "${env.TEAMS_URL}",
|
|
// message: 'Alert create and update failed',
|
|
// status: 'Failure',
|
|
// color: '#FF0000'
|
|
echo "Failure"
|
|
}
|
|
}
|
|
} |