p00003/Jenkinsfile
greenamber676 5babd91cfa
Some checks failed
DEV-234/pipeline/head There was a failure building this commit
added full path for podman compose file
2025-01-09 20:44:07 -05:00

61 lines
1.5 KiB
Groovy

pipeline {
agent any
environment {
DOCKER_IMAGE_PGADMIN = 'dpage/pgadmin4:latest'
DOCKER_IMAGE_POSTGRES = 'postgres:16.6'
DOCKER_COMPOSE_FILE = '/home/v/projects/p00003/podman-compose.yml'
}
stages {
stage('Checkout') {
steps {
// Checkout the code from Gitea
git url: 'http://gitea.domeitsolutions.com/2265959/p00003.git', branch: 'main'
}
}
stage('Build Node.js') {
steps {
script {
// Build Node.js application
echo 'step 1 - build reflex-react UI'
}
}
}
stage('Build Django') {
steps {
script {
// Build Django application
echo 'step-1 build django-api'
}
}
}
stage('Run Tests') {
steps {
script {
// Run tests using Docker Compose
sh "podman-compose -f '/home/v/projects/p00003/podman-compose.yml' --dry-run up"
}
}
}
stage('Deploy') {
steps {
script {
// Deploy using Docker Compose
sh "podman-compose -f ${DOCKER_COMPOSE_FILE} up -d"
}
}
}
}
post {
always {
// Clean up Docker containers and images
sh 'podman-compose -f ${DOCKER_COMPOSE_FILE} down'
}
}
}