From 28bba631318cee9402668ba8b3879f8233017295 Mon Sep 17 00:00:00 2001 From: tkinaba Date: Fri, 27 Feb 2026 12:41:09 -0300 Subject: [PATCH] ci: init --- Jenkinsfile | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 Jenkinsfile diff --git a/Jenkinsfile b/Jenkinsfile new file mode 100644 index 0000000..3fc90cf --- /dev/null +++ b/Jenkinsfile @@ -0,0 +1,50 @@ +pipeline { + agent { + docker { + image 'hub.davinti.com.br:443/infra/node:latest' + args '-u root' + } + } + + environment { + S3_BUCKET = "s3://app-dono-manifests" + } + + stages { + stage('Install') { + steps { + sh 'npm install' + } + } + + stage('Vet') { + steps { + echo 'Validating modules (Standard for all branches)...' + sh 'npx jeff vet -i "src/**/*.module.ts" --strict' + } + } + + stage('Generate & Upload') { + when { + branch 'main' + } + steps { + echo 'Generating manifest and deploying to S3...' + sh 'npm run generate:output' + + withAWS(credentials: 'aws-jeff-credentials-id', region: 'sa-east-1') { + script { + echo "Uploading to S3..." + sh "aws s3 cp dist/manifest.json ${S3_BUCKET}/manifest.json" + } + } + } + } + } + + post { + always { + echo "Finished build for ${env.BRANCH_NAME}" + } + } +}