Jenkinsfile 662 B

1234567891011121314151617181920212223242526
  1. pipeline {
  2. agent any
  3. stages {
  4. stage('Build') {
  5. steps {
  6. echo 'Building...'
  7. sh 'python3.7 -m poetry install --develop .'
  8. sh 'python3.7 -m poetry install'
  9. }
  10. }
  11. stage('Test') {
  12. steps {
  13. echo 'Testing...'
  14. sh 'poetry run tox'
  15. sh 'find . | grep -E "(__pycache__|\.pyc|\.pyo$)" | xargs rm -rf'
  16. }
  17. }
  18. stage('Deploy') {
  19. steps {
  20. echo 'Deploying....'
  21. sh 'ansible-playbook -i dockerbox, ansible_playbook.yaml'
  22. }
  23. }
  24. }
  25. }