Merge pull request #2353 from PaladinCloud/fix/next-291/rename-featur… #818
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CE-Dev-S3 | |
on: | |
push: | |
branches: | |
- master | |
- release-v*.*.* | |
pull_request: | |
branches: | |
- master | |
- release-v*.*.* | |
permissions: | |
id-token: write | |
contents: read | |
pull-requests: read | |
# job to tcheck if the branch is a release branch | |
jobs: | |
check_branch: | |
name: Check Branch | |
runs-on: ubuntu-latest | |
outputs: | |
is_release: ${{ steps.check_branch.outputs.is_release }} | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v4 | |
- name: Check if the branch is a release branch | |
id: check_branch | |
run: | | |
branch_name="${{ github.ref }}" | |
if [[ $branch_name =~ ^refs/heads/release-(.+)$ ]]; then | |
echo "::set-output name=is_release::true" | |
else | |
echo "::set-output name=is_release::false" | |
fi | |
- name: Display is_release | |
run: | | |
is_release="${{ steps.check_branch.outputs.is_release }}" | |
echo " It is an release branch: $is_release" | |
filter: | |
name: filters | |
runs-on: ubuntu-latest | |
needs: | |
- check_branch | |
outputs: | |
pom: ${{ steps.filter.outputs.pom }} | |
commons: ${{ steps.filter.outputs.commons }} | |
azure-discovery: ${{ steps.filter.outputs.azure-discovery }} | |
pacman-awsrules: ${{ steps.filter.outputs.pacman-awsrules }} | |
recommendation-enricher: ${{ steps.filter.outputs.recommendation-enricher }} | |
gcp-discovery: ${{ steps.filter.outputs.gcp-discovery }} | |
pacman-cloud-discovery: ${{ steps.filter.outputs.pacman-cloud-discovery }} | |
pacman-rule-engine: ${{ steps.filter.outputs.pacman-rule-engine }} | |
job-scheduler: ${{ steps.filter.outputs.job-scheduler }} | |
pacman-cloud-notifications: ${{ steps.filter.outputs.pacman-cloud-notifications }} | |
pacman-tenable-enricher: ${{ steps.filter.outputs.pacman-tenable-enricher }} | |
pacman-aqua-enricher: ${{ steps.filter.outputs.pacman-aqua-enricher }} | |
pacman-data-shipper: ${{ steps.filter.outputs.pacman-data-shipper }} | |
pacman-qualys-enricher: ${{ steps.filter.outputs.pacman-qualys-enricher }} | |
notification-es-logging-service: ${{ steps.filter.outputs.notification-es-logging-service }} | |
notification-invoke-service: ${{ steps.filter.outputs.notification-invoke-service }} | |
notification-send-email-service: ${{ steps.filter.outputs.notification-send-email-service }} | |
notification-template-formatter-service: ${{ steps.filter.outputs.notification-template-formatter-service }} | |
subsystem-auth: ${{ steps.filter.outputs.subsystem-auth }} | |
DB_Policy: ${{ steps.filter.outputs.DB_Policy }} | |
DB: ${{ steps.filter.outputs.DB }} | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: dorny/paths-filter@v2 | |
id: filter | |
with: | |
filters: | | |
pom: | |
- 'jobs/pom.xml' | |
commons: | |
- 'commons/**' | |
azure-discovery: | |
- 'jobs/azure-discovery/**' | |
pacman-awsrules: | |
- 'jobs/pacman-awsrules/**' | |
pacman-qualys-enricher: | |
- 'jobs/pacman-qualys-enricher/**' | |
recommendation-enricher: | |
- 'jobs/recommendation-enricher/**' | |
gcp-discovery: | |
- 'jobs/gcp-discovery/**' | |
pacman-cloud-discovery: | |
- 'jobs/pacman-cloud-discovery/**' | |
pacman-rule-engine: | |
- 'jobs/pacman-rule-engine-2.0/**' | |
job-scheduler: | |
- 'jobs/job-scheduler/**' | |
pacman-cloud-notifications: | |
- 'jobs/pacman-cloud-notifications/**' | |
pacman-tenable-enricher: | |
- 'jobs/pacman-tenable-enricher/**' | |
pacman-aqua-enricher: | |
- 'jobs/pacman-aqua-enricher/**' | |
pacman-data-shipper: | |
- 'jobs/pacman-data-shipper/**' | |
notification-es-logging-service: | |
- 'lambda-functions/notification-es-logging-service/**' | |
notification-invoke-service: | |
- 'lambda-functions/notification-invoke-service/**' | |
notification-send-email-service: | |
- 'lambda-functions/notification-send-email-service/**' | |
notification-template-formatter-service: | |
- 'lambda-functions/notification-template-formatter-service/**' | |
subsystem-auth: | |
- 'subsystem/auth/**' | |
DB_Policy: | |
- 'installer/resources/pacbot_app/files/DB_Policy.sql' | |
DB: | |
- 'installer/resources/pacbot_app/files/DB.sql' | |
extract_version: | |
name : extract_version | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/heads/release-v') | |
outputs: | |
version: ${{ steps.extract_version.outputs.version }} | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v4 | |
- name: Extract Version | |
id: extract_version | |
run: | | |
branch_name="${{ github.ref }}" | |
if [[ $branch_name =~ ^refs/heads/release-(.+)$ ]]; then | |
echo "::set-output name=version::${BASH_REMATCH[1]}" | |
else | |
echo "Invalid branch name format" | |
exit 1 | |
fi | |
- name: Display Version | |
run: | | |
version="${{ steps.extract_version.outputs.version }}" | |
echo "Extracted Version: $version" | |
AzureBuild: | |
name: Azure-Build | |
runs-on: ubuntu-latest | |
needs: | |
- filter | |
- check_branch | |
if: needs.filter.outputs.pom == 'true' || needs.filter.outputs.commons == 'true' || needs.filter.outputs.azure-discovery == 'true' || needs.check_branch.outputs.is_release == 'true' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: running update | |
run: sudo apt update | |
- name: Setup Maven Action | |
uses: s4u/[email protected] | |
with: | |
checkout-fetch-depth: 0 | |
java-version: 8 | |
java-distribution: temurin | |
maven-version: 3.6.3 | |
- name: Building commons jar | |
run: | | |
cd commons | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Building Jobs jar | |
run: | | |
cd jobs/azure-discovery/ | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Upload Jobs artifact | |
if: github.event_name == 'push' || github.event_name == 'create' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: jobs-azure-artifact | |
path: ./dist/jobs | |
Push-azure-Dev: | |
name: Push azure-discovery to s3 dev | |
runs-on: ubuntu-latest | |
environment: 'SaaSDEV' | |
if: (github.event_name == 'push' && startsWith(github.ref, 'refs/heads/master')) | |
needs: | |
- AzureBuild | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for Dev account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_DEV }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-azure-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_DEV }}/vlatest/dev/jobs | |
Push-azure-QA: | |
name: Push azure-discovery to s3 QA | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/heads/release-v') | |
environment: 'SaaSQA' | |
needs: | |
- AzureBuild | |
- extract_version | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for Qa account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_QA }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-azure-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_QA }}/${{ needs.extract_version.outputs.version }}/qa/jobs | |
AwsrulesBuild: | |
name: Awsrules-Build | |
runs-on: ubuntu-latest | |
needs: | |
- filter | |
- check_branch | |
if: needs.filter.outputs.pom == 'true' || needs.filter.outputs.commons == 'true' || needs.filter.outputs.pacman-awsrules == 'true' || needs.check_branch.outputs.is_release == 'true' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: running update | |
run: sudo apt update | |
- name: Setup Maven Action | |
uses: s4u/[email protected] | |
with: | |
checkout-fetch-depth: 0 | |
java-version: 8 | |
java-distribution: temurin | |
maven-version: 3.6.3 | |
- name: Building commons jar | |
run: | | |
cd commons | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Building Jobs jar | |
run: | | |
cd jobs/pacman-awsrules/ | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Upload Jobs artifact | |
if: github.event_name == 'push' || github.event_name == 'create' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: jobs-awsrules-artifact | |
path: ./dist/jobs | |
Push-awsrules-Dev: | |
name: Push awsrules to s3 dev | |
runs-on: ubuntu-latest | |
environment: 'SaaSDEV' | |
if: (github.event_name == 'push' && startsWith(github.ref, 'refs/heads/master')) | |
needs: | |
- AwsrulesBuild | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for Dev account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_DEV }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-awsrules-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_DEV }}/vlatest/dev/jobs | |
Push-awsrules-QA: | |
name: Push awsrules to s3 QA | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/heads/release-v') | |
environment: 'SaaSQA' | |
needs: | |
- AwsrulesBuild | |
- extract_version | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for QA account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_QA }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-awsrules-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_QA }}/${{ needs.extract_version.outputs.version }}/qa/jobs | |
QualysBuild: | |
name: qualys-Build | |
runs-on: ubuntu-latest | |
needs: | |
- filter | |
- check_branch | |
if: needs.filter.outputs.pom == 'true' || needs.filter.outputs.commons == 'true' || needs.filter.outputs.pacman-qualys-enricher == 'true' || needs.check_branch.outputs.is_release == 'true' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: running update | |
run: sudo apt update | |
- name: Setup Maven Action | |
uses: s4u/[email protected] | |
with: | |
checkout-fetch-depth: 0 | |
java-version: 8 | |
java-distribution: temurin | |
maven-version: 3.6.3 | |
- name: Building commons jar | |
run: | | |
cd commons | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Building Jobs jar | |
run: | | |
cd jobs/pacman-qualys-enricher/ | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Upload Jobs artifact | |
if: github.event_name == 'push' || github.event_name == 'create' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: jobs-qualys-artifact | |
path: ./dist/jobs | |
Push-Qualys-Dev: | |
name: Push qualys to s3 dev | |
runs-on: ubuntu-latest | |
environment: 'SaaSDEV' | |
if: (github.event_name == 'push' && startsWith(github.ref, 'refs/heads/master')) | |
needs: | |
- QualysBuild | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for Dev account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_DEV }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-qualys-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_DEV }}/vlatest/dev/jobs | |
Push-Qualys-QA: | |
name: Push qualys to s3 QA | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/heads/release-v') | |
environment: 'SaaSQA' | |
needs: | |
- QualysBuild | |
- extract_version | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for QA account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_QA }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-qualys-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_QA }}/${{ needs.extract_version.outputs.version }}/qa/jobs | |
RecommendationBuild: | |
name: Recommendation-Build | |
runs-on: ubuntu-latest | |
needs: | |
- filter | |
- check_branch | |
if: needs.filter.outputs.pom == 'true' || needs.filter.outputs.commons == 'true' || needs.filter.outputs.recommendation-enricher == 'true' || needs.check_branch.outputs.is_release == 'true' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: running update | |
run: sudo apt update | |
- name: Setup Maven Action | |
uses: s4u/[email protected] | |
with: | |
checkout-fetch-depth: 0 | |
java-version: 8 | |
java-distribution: temurin | |
maven-version: 3.6.3 | |
- name: Building commons jar | |
run: | | |
cd commons | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Building Jobs jar | |
run: | | |
cd jobs/recommendation-enricher/ | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Upload Jobs artifact | |
if: github.event_name == 'push' || github.event_name == 'create' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: jobs-recommendation-artifact | |
path: ./dist/jobs | |
Push-recommendation-Dev: | |
name: Push recommendation-enricher to s3 dev | |
runs-on: ubuntu-latest | |
environment: 'SaaSDEV' | |
if: (github.event_name == 'push' && startsWith(github.ref, 'refs/heads/master')) | |
needs: | |
- RecommendationBuild | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for Dev account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_DEV }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-recommendation-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_DEV }}/vlatest/dev/jobs | |
Push-recommendation-QA: | |
name: Push recommendation-enricher to s3 QA | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/heads/release-v') | |
environment: 'SaaSQA' | |
needs: | |
- RecommendationBuild | |
- extract_version | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for QA account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_QA }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-recommendation-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_QA }}/${{ needs.extract_version.outputs.version }}/qa/jobs | |
Cloud-Discovery-Build: | |
name: Cloud-Discovery-Build | |
runs-on: ubuntu-latest | |
needs: | |
- filter | |
- check_branch | |
if: needs.filter.outputs.pom == 'true' || needs.filter.outputs.commons == 'true' || needs.filter.outputs.pacman-cloud-discovery == 'true' || needs.check_branch.outputs.is_release == 'true' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: running update | |
run: sudo apt update | |
- name: Setup Maven Action | |
uses: s4u/[email protected] | |
with: | |
checkout-fetch-depth: 0 | |
java-version: 8 | |
java-distribution: temurin | |
maven-version: 3.6.3 | |
- name: Building commons jar | |
run: | | |
cd commons | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Building Jobs jar | |
run: | | |
cd jobs/pacman-cloud-discovery/ | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Upload Jobs artifact | |
if: github.event_name == 'push' || github.event_name == 'create' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: jobs-cloud-artifact | |
path: ./dist/jobs | |
Push-Cloud-Discovery-Dev: | |
name: Push Cloud-discovery to s3 dev | |
runs-on: ubuntu-latest | |
environment: 'SaaSDEV' | |
if: (github.event_name == 'push' && startsWith(github.ref, 'refs/heads/master')) | |
needs: | |
- Cloud-Discovery-Build | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for Dev account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_DEV }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-cloud-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_DEV }}/vlatest/dev/jobs | |
Push-Cloud-Discovery-QA: | |
name: Push Cloud-discovery to s3 QA | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/heads/release-v') | |
environment: 'SaaSQA' | |
needs: | |
- Cloud-Discovery-Build | |
- extract_version | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for QA account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_QA }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-cloud-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_QA }}/${{ needs.extract_version.outputs.version }}/qa/jobs | |
RuleEngineBuild: | |
name: Rule-engine-2.0-Build | |
runs-on: ubuntu-latest | |
needs: | |
- filter | |
- check_branch | |
if: needs.filter.outputs.pom == 'true' || needs.filter.outputs.commons == 'true' || needs.filter.outputs.pacman-rule-engine == 'true' || needs.check_branch.outputs.is_release == 'true' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: running update | |
run: sudo apt update | |
- name: Setup Maven Action | |
uses: s4u/[email protected] | |
with: | |
checkout-fetch-depth: 0 | |
java-version: 8 | |
java-distribution: temurin | |
maven-version: 3.6.3 | |
- name: Building commons jar | |
run: | | |
cd commons | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Building awsrules jar | |
run: | | |
cd jobs/pacman-awsrules/ | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Building Jobs jar | |
run: | | |
cd jobs/pacman-rule-engine-2.0/ | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Upload Jobs artifact | |
if: github.event_name == 'push' || github.event_name == 'create' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: jobs-RE2.0-artifact | |
path: ./dist/jobs | |
Push-RuleEngineBuild-Dev: | |
name: Push Rule-engine-2.0 to s3 dev | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push' && startsWith(github.ref, 'refs/heads/master')) | |
environment: 'SaaSDEV' | |
needs: | |
- RuleEngineBuild | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for Dev account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_DEV }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-RE2.0-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_DEV }}/vlatest/dev/jobs | |
Push-RuleEngineBuild-QA: | |
name: Push Rule-engine-2.0 to s3 QA | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/heads/release-v') | |
environment: 'SaaSQA' | |
needs: | |
- RuleEngineBuild | |
- extract_version | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for QA account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_QA }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-RE2.0-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_QA }}/${{ needs.extract_version.outputs.version }}/qa/jobs | |
SchedulerBuild: | |
name: Scheduler-Build | |
runs-on: ubuntu-latest | |
needs: | |
- filter | |
- check_branch | |
if: needs.filter.outputs.pom == 'true' || needs.filter.outputs.commons == 'true' || needs.filter.outputs.job-scheduler == 'true' || needs.check_branch.outputs.is_release == 'true' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: running update | |
run: sudo apt update | |
- name: Setup Maven Action | |
uses: s4u/[email protected] | |
with: | |
checkout-fetch-depth: 0 | |
java-version: 8 | |
java-distribution: temurin | |
maven-version: 3.6.3 | |
- name: Building commons jar | |
run: | | |
cd commons | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Building Jobs jar | |
run: | | |
cd jobs/job-scheduler/ | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Upload Jobs artifact | |
if: github.event_name == 'push' || github.event_name == 'create' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: jobs-scheduler-artifact | |
path: ./dist/jobs | |
Push-SchedulerBuild-Dev: | |
name: Push SchedulerBuild to s3 dev | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push' && startsWith(github.ref, 'refs/heads/master')) | |
environment: 'SaaSDEV' | |
needs: | |
- SchedulerBuild | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for Dev account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_DEV }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-scheduler-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_DEV }}/vlatest/dev/api | |
Push-SchedulerBuild-QA: | |
name: Push SchedulerBuild to s3 QA | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/heads/release-v') | |
environment: 'SaaSQA' | |
needs: | |
- SchedulerBuild | |
- extract_version | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for QA account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_QA }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-scheduler-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_QA }}/${{ needs.extract_version.outputs.version }}/qa/api | |
NotificationBuild: | |
name: Notification-Build | |
runs-on: ubuntu-latest | |
needs: | |
- filter | |
- check_branch | |
if: needs.filter.outputs.pom == 'true' || needs.filter.outputs.pacman-cloud-notifications == 'true' || needs.filter.outputs.pom == 'true' || needs.check_branch.outputs.is_release == 'true' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: running update | |
run: sudo apt update | |
- name: Setup Maven Action | |
uses: s4u/[email protected] | |
with: | |
checkout-fetch-depth: 0 | |
java-version: 8 | |
java-distribution: temurin | |
maven-version: 3.6.3 | |
- name: Building commons jar | |
run: | | |
cd commons | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Building Jobs jar | |
run: | | |
cd jobs/pacman-cloud-notifications/ | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Upload Jobs artifact | |
if: github.event_name == 'push' || github.event_name == 'create' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: jobs-notification-artifact | |
path: ./dist/jobs | |
Push-Notification-Dev: | |
name: Push Notification to s3 dev | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push' && startsWith(github.ref, 'refs/heads/master')) | |
environment: 'SaaSDEV' | |
needs: | |
- NotificationBuild | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for Dev account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_DEV }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-notification-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_DEV }}/vlatest/dev/jobs | |
Push-Notification-QA: | |
name: Push Notification to s3 QA | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/heads/release-v') | |
environment: 'SaaSQA' | |
needs: | |
- NotificationBuild | |
- extract_version | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for QA account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_QA }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-notification-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_QA }}/${{ needs.extract_version.outputs.version }}/qa/jobs | |
TenableBuild: | |
name: Tenable-Build | |
runs-on: ubuntu-latest | |
needs: | |
- filter | |
- check_branch | |
if: needs.filter.outputs.pom == 'true' || needs.filter.outputs.commons == 'true' || needs.filter.outputs.pacman-tenable-enricher == 'true' || needs.check_branch.outputs.is_release == 'true' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: running update | |
run: sudo apt update | |
- name: Setup Maven Action | |
uses: s4u/[email protected] | |
with: | |
checkout-fetch-depth: 0 | |
java-version: 8 | |
java-distribution: temurin | |
maven-version: 3.6.3 | |
- name: Building commons jar | |
run: | | |
cd commons | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Building Jobs jar | |
run: | | |
cd jobs/pacman-tenable-enricher/ | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Upload Jobs artifact | |
if: github.event_name == 'push' || github.event_name == 'create' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: jobs-Tenable-artifact | |
path: ./dist/jobs | |
Push-Tenable-Dev: | |
name: Push Tenable to s3 dev | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push' && startsWith(github.ref, 'refs/heads/master')) | |
environment: 'SaaSDEV' | |
needs: | |
- TenableBuild | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for Dev account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_DEV }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-Tenable-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_DEV }}/vlatest/dev/jobs | |
Push-Tenable-QA: | |
name: Push Tenable to s3 QA | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/heads/release-v') | |
environment: 'SaaSQA' | |
needs: | |
- TenableBuild | |
- extract_version | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for QA account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_QA }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-Tenable-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_QA }}/${{ needs.extract_version.outputs.version }}/qa/jobs | |
AquaBuild: | |
name: Aqua-Build | |
runs-on: ubuntu-latest | |
needs: | |
- filter | |
- check_branch | |
if: needs.filter.outputs.pom == 'true' || needs.filter.outputs.commons == 'true' || needs.filter.outputs.pacman-aqua-enricher == 'true' || needs.check_branch.outputs.is_release == 'true' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: running update | |
run: sudo apt update | |
- name: Setup Maven Action | |
uses: s4u/[email protected] | |
with: | |
checkout-fetch-depth: 0 | |
java-version: 8 | |
java-distribution: temurin | |
maven-version: 3.6.3 | |
- name: Building commons jar | |
run: | | |
cd commons | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Building Jobs jar | |
run: | | |
cd jobs/pacman-aqua-enricher/ | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Upload Jobs artifact | |
if: github.event_name == 'push' || github.event_name == 'create' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: jobs-aqua-artifact | |
path: ./dist/jobs | |
Push-Aqua-Dev: | |
name: Push Aqua to s3 dev | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push' && startsWith(github.ref, 'refs/heads/master')) | |
environment: 'SaaSDEV' | |
needs: | |
- AquaBuild | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for Dev account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_DEV }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-aqua-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_DEV }}/vlatest/dev/jobs | |
Push-Aqua-QA: | |
name: Push Aqua to s3 QA | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/heads/release-v') | |
environment: 'SaaSQA' | |
needs: | |
- AquaBuild | |
- extract_version | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for QA account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_QA }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-aqua-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_QA }}/${{ needs.extract_version.outputs.version }}/qa/jobs | |
ShipperBuild: | |
name: Shipper-Build | |
runs-on: ubuntu-latest | |
needs: | |
- filter | |
- check_branch | |
if: needs.filter.outputs.pom == 'true' || needs.filter.outputs.commons == 'true' || needs.filter.outputs.pacman-data-shipper == 'true' || needs.check_branch.outputs.is_release == 'true' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: running update | |
run: sudo apt update | |
- name: Setup Maven Action | |
uses: s4u/[email protected] | |
with: | |
checkout-fetch-depth: 0 | |
java-version: 8 | |
java-distribution: temurin | |
maven-version: 3.6.3 | |
- name: Building commons jar | |
run: | | |
cd commons | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Building Jobs jar | |
run: | | |
cd jobs/pacman-data-shipper/ | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Upload Jobs artifact | |
if: github.event_name == 'push' || github.event_name == 'create' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: jobs-shipper-artifact | |
path: ./dist/jobs | |
Push-Shipper-Dev: | |
name: Push Shipper to s3 dev | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push' && startsWith(github.ref, 'refs/heads/master')) | |
environment: 'SaaSDEV' | |
needs: | |
- ShipperBuild | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for Dev account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_DEV }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-shipper-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_DEV }}/vlatest/dev/jobs | |
Push-Shipper-QA: | |
name: Push Shipper to s3 QA | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/heads/release-v') | |
environment: 'SaaSQA' | |
needs: | |
- ShipperBuild | |
- extract_version | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for QA account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_QA }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: jobs-shipper-artifact | |
path: ./dist/jobs | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/jobs/ s3://${{ secrets.AWS_BUCKET_QA }}/${{ needs.extract_version.outputs.version }}/qa/jobs | |
Es-logging: | |
name: es-logging-Build | |
runs-on: ubuntu-latest | |
needs: | |
- filter | |
- check_branch | |
if: needs.filter.outputs.notification-es-logging-service == 'true' || needs.check_branch.outputs.is_release == 'true' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: running update | |
run: sudo apt update | |
- name: Setup Maven Action | |
uses: s4u/[email protected] | |
with: | |
checkout-fetch-depth: 0 | |
java-version: 8 | |
java-distribution: temurin | |
maven-version: 3.6.3 | |
- name: Building commons jar | |
run: | | |
cd commons | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Building Jobs jar | |
run: | | |
cd lambda-functions/notification-es-logging-service/ | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Upload Jobs artifact | |
if: github.event_name == 'push' || github.event_name == 'create' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: es-logging-artifact | |
path: ./dist/lambda | |
Es-logging-Dev: | |
name: Push es log lambda to s3 dev | |
environment: 'SaaSDEV' | |
runs-on: ubuntu-latest | |
if: (github.event_name == 'push' && startsWith(github.ref, 'refs/heads/master')) | |
needs: | |
- Es-logging | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for Dev account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_DEV }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: es-logging-artifact | |
path: ./dist/lambda | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/lambda/ s3://${{ secrets.AWS_BUCKET_DEV }}/vlatest/dev/lambda | |
Es-logging-QA: | |
name: Push es log lambda to s3 QA | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/heads/release-v') | |
environment: 'SaaSQA' | |
needs: | |
- Es-logging | |
- extract_version | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for QA account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_QA }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: es-logging-artifact | |
path: ./dist/lambda | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/lambda/ s3://${{ secrets.AWS_BUCKET_QA }}/${{ needs.extract_version.outputs.version }}/qa/lambda | |
Invoke-Service: | |
name: invoke-service-Build | |
runs-on: ubuntu-latest | |
needs: | |
- filter | |
- check_branch | |
if: needs.filter.outputs.notification-invoke-service == 'true' || needs.check_branch.outputs.is_release == 'true' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: running update | |
run: sudo apt update | |
- name: Setup Maven Action | |
uses: s4u/[email protected] | |
with: | |
checkout-fetch-depth: 0 | |
java-version: 8 | |
java-distribution: temurin | |
maven-version: 3.6.3 | |
- name: Building commons jar | |
run: | | |
cd commons | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Building Jobs jar | |
run: | | |
cd lambda-functions/notification-invoke-service | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Upload Jobs artifact | |
if: github.event_name == 'push' || github.event_name == 'create' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: invoke-service-artifact | |
path: ./dist/lambda | |
InvokeService-Dev: | |
name: Push invoke service lambda to s3 dev | |
runs-on: ubuntu-latest | |
environment: 'SaaSDEV' | |
if: (github.event_name == 'push' && startsWith(github.ref, 'refs/heads/master')) | |
needs: | |
- Invoke-Service | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for Dev account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_DEV }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: invoke-service-artifact | |
path: ./dist/lambda | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/lambda/ s3://${{ secrets.AWS_BUCKET_DEV }}/vlatest/dev/lambda | |
InvokeService-QA: | |
name: Push invoke service lambda to s3 QA | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/heads/release-v') | |
environment: 'SaaSQA' | |
needs: | |
- Invoke-Service | |
- extract_version | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for QA account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_QA }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: invoke-service-artifact | |
path: ./dist/lambda | |
- name: copy lambda jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/lambda/ s3://${{ secrets.AWS_BUCKET_QA }}/${{ needs.extract_version.outputs.version }}/qa/lambda | |
Send-Email-Service: | |
name: Send-Email-Build | |
runs-on: ubuntu-latest | |
needs: | |
- filter | |
- check_branch | |
if: needs.filter.outputs.notification-send-email-service == 'true' || needs.check_branch.outputs.is_release == 'true' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: running update | |
run: sudo apt update | |
- name: Setup Maven Action | |
uses: s4u/[email protected] | |
with: | |
checkout-fetch-depth: 0 | |
java-version: 8 | |
java-distribution: temurin | |
maven-version: 3.6.3 | |
- name: Building commons jar | |
run: | | |
cd commons | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Building Jobs jar | |
run: | | |
cd lambda-functions/notification-send-email-service | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Upload Jobs artifact | |
if: github.event_name == 'push' || github.event_name == 'create' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: send-email-artifact | |
path: ./dist/lambda | |
Send-Email-Dev: | |
name: Push send mail lambda to s3 dev | |
runs-on: ubuntu-latest | |
environment: 'SaaSDEV' | |
if: (github.event_name == 'push' && startsWith(github.ref, 'refs/heads/master')) | |
needs: | |
- Send-Email-Service | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for Dev account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_DEV }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: send-email-artifact | |
path: ./dist/lambda | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/lambda/ s3://${{ secrets.AWS_BUCKET_DEV }}/vlatest/dev/lambda | |
Send-Email-QA: | |
name: Push send mail lambdato s3 QA | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/heads/release-v') | |
environment: 'SaaSQA' | |
needs: | |
- Send-Email-Service | |
- extract_version | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for QA account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_QA }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: send-email-artifact | |
path: ./dist/lambda | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/lambda/ s3://${{ secrets.AWS_BUCKET_QA }}/${{ needs.extract_version.outputs.version }}/qa/lambda | |
Template-formatter-Service: | |
name: Template-formatter-Build | |
runs-on: ubuntu-latest | |
needs: | |
- filter | |
- check_branch | |
if: needs.filter.outputs.notification-template-formatter-service == 'true' || needs.check_branch.outputs.is_release == 'true' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: running update | |
run: sudo apt update | |
- name: Setup Maven Action | |
uses: s4u/[email protected] | |
with: | |
checkout-fetch-depth: 0 | |
java-version: 8 | |
java-distribution: temurin | |
maven-version: 3.6.3 | |
- name: Building commons jar | |
run: | | |
cd commons | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Building Jobs jar | |
run: | | |
cd lambda-functions/notification-template-formatter-service | |
mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true | |
- name: Upload Jobs artifact | |
if: github.event_name == 'push' || github.event_name == 'create' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: template-formatter-artifact | |
path: ./dist/lambda | |
Template-formatter-Dev: | |
name: Push template formatter to s3 dev | |
runs-on: ubuntu-latest | |
environment: 'SaaSDEV' | |
if: (github.event_name == 'push' && startsWith(github.ref, 'refs/heads/master')) | |
needs: | |
- Template-formatter-Service | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for Dev account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_DEV }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: template-formatter-artifact | |
path: ./dist/lambda | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/lambda/ s3://${{ secrets.AWS_BUCKET_DEV }}/vlatest/dev/lambda | |
Template-formatter-QA: | |
name: Push template formatter to s3 QA | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/heads/release-v') | |
environment: 'SaaSQA' | |
needs: | |
- Template-formatter-Service | |
- extract_version | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for QA account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_QA }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: template-formatter-artifact | |
path: ./dist/lambda | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp --recursive ./dist/lambda/ s3://${{ secrets.AWS_BUCKET_QA }}/${{ needs.extract_version.outputs.version }}/qa/lambda | |
subsystem-auth-service: | |
name: subsystem-auth-service-Build | |
runs-on: ubuntu-latest | |
needs: | |
- filter | |
- check_branch | |
if: needs.filter.outputs.subsystem-auth == 'true' || needs.check_branch.outputs.is_release == 'true' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Set up Go | |
uses: actions/setup-go@v4 | |
with: | |
go-version: '1.21' | |
- name: Execute Makefile | |
run: | | |
cd subsystem/auth/services/svc-api-authorizer | |
make build package | |
- name: Upload auth service artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: auth-service-artifact | |
path: subsystem/auth/services/svc-api-authorizer/bin/svc-api-authorizer.zip | |
subsystem-auth-service-Dev: | |
name: Push auth service to s3 dev | |
runs-on: ubuntu-latest | |
environment: 'SaaSDEV' | |
if: (github.event_name == 'push' && startsWith(github.ref, 'refs/heads/master')) | |
needs: | |
- subsystem-auth-service | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for Dev account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_DEV }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v3 | |
with: | |
name: auth-service-artifact | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp svc-api-authorizer.zip s3://${{ secrets.AWS_BUCKET_DEV }}/vlatest/dev/lambda/ | |
subsystem-auth-service-QA: | |
name: Push auth service to s3 QA | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/heads/release-v') | |
environment: 'SaaSQA' | |
needs: | |
- subsystem-auth-service | |
- extract_version | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for QA account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_QA }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: Download Jobs artifact | |
uses: actions/download-artifact@v3 | |
with: | |
name: auth-service-artifact | |
- name: copy Jobs jars to S3 | |
run: | | |
aws s3 cp svc-api-authorizer.zip s3://${{ secrets.AWS_BUCKET_QA }}/${{ needs.extract_version.outputs.version }}/qa/lambda/ | |
push-sql-Dev: | |
name: Push SQL files to s3 dev | |
runs-on: ubuntu-latest | |
environment: 'SaaSDEV' | |
if: (github.event_name == 'push' && startsWith(github.ref, 'refs/heads/master')) | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for Dev account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_DEV }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: sql files to dev S3 | |
run: | | |
cd ./installer/resources/pacbot_app/files/ | |
aws s3 cp DB_Policy.sql s3://${{ secrets.AWS_BUCKET_DEV }}/vlatest/dev/sql/ | |
aws s3 cp DB.sql s3://${{ secrets.AWS_BUCKET_DEV }}/vlatest/dev/sql/ | |
push-sql-Qa: | |
name: Push SQL files to s3 qa | |
runs-on: ubuntu-latest | |
needs: | |
- extract_version | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/heads/release-v') | |
environment: 'SaaSQA' | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Configure AWS credentials for QA account | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_QA }} | |
aws-region: ${{ secrets.AWS_REGION }} | |
- name: sql files to qa S3 | |
run: | | |
cd ./installer/resources/pacbot_app/files/ | |
aws s3 cp DB_Policy.sql s3://${{ secrets.AWS_BUCKET_QA }}/${{ needs.extract_version.outputs.version }}/qa/sql/ | |
aws s3 cp DB.sql s3://${{ secrets.AWS_BUCKET_QA }}/${{ needs.extract_version.outputs.version }}/qa/sql/ |