Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added concurrency feature to main.yml #639

Merged
merged 1 commit into from
Jul 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/workflows/Build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ on:
push:
branches: [ main ]

concurrency:
group: merge-queue
cancel-in-progress: false

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cancel-in-progress: false
Do we need to add it ?

jobs:
unittest:
name: unittest
Expand Down
2 changes: 1 addition & 1 deletion jenkins/clouds/aws/daily/org_cost_explorer/Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ pipeline {
COST_CENTER_OWNER = credentials('cloud-governance-cost-center-owner')
REPLACE_ACCOUNT_NAME = credentials('cloud-governance-replace-account-names')
PAYER_SUPPORT_FEE_CREDIT = credentials('cloud-governance-aws-payer-support-fee-credit')
AWS_SECRET_ACCESS_KEY_DELETE_ATHIRUMA_BOT = credentials('AWS_SECRET_ACCESS_KEY_DELETE_ATHIRUMA_BOT')
AWS_SECRET_ACCESS_KEY_ATHIRUMA_BOT = credentials('AWS_SECRET_ACCESS_KEY_ATHIRUMA_BOT')
AWS_ACCESS_KEY_ID_ATHIRUMA_BOT = credentials('AWS_ACCESS_KEY_ID_ATHIRUMA_BOT')
S3_RESULTS_PATH = credentials('S3_RESULTS_PATH')
ATHENA_DATABASE_NAME = credentials('ATHENA_DATABASE_NAME')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@
REPLACE_ACCOUNT_NAME = os.environ['REPLACE_ACCOUNT_NAME']
PAYER_SUPPORT_FEE_CREDIT = os.environ['PAYER_SUPPORT_FEE_CREDIT']
AWS_ACCESS_KEY_ID_ATHIRUMA_BOT = os.environ['AWS_ACCESS_KEY_ID_ATHIRUMA_BOT']
AWS_SECRET_ACCESS_KEY_DELETE_ATHIRUMA_BOT = os.environ['AWS_SECRET_ACCESS_KEY_DELETE_ATHIRUMA_BOT']
AWS_SECRET_ACCESS_KEY_ATHIRUMA_BOT = os.environ['AWS_SECRET_ACCESS_KEY_ATHIRUMA_BOT']
S3_RESULTS_PATH = os.environ['S3_RESULTS_PATH']
ATHENA_DATABASE_NAME = os.environ['ATHENA_DATABASE_NAME']
ATHENA_TABLE_NAME = os.environ['ATHENA_TABLE_NAME']

print("Updating the Org level cost billing reports")
os.system('echo "Updating the Org level cost billing reports"')

# Cost Explorer upload to ElasticSearch
cost_metric = 'UnblendedCost' # UnblendedCost/BlendedCost
Expand All @@ -35,8 +35,9 @@

os.system('echo "Run the Spot Analysis report over the account using AWS Athena"')
os.system(f"""podman run --rm --name cloud-governance -e policy="spot_savings_analysis" -e account="pnt-payer" \
-e AWS_ACCESS_KEY_ID="{AWS_ACCESS_KEY_ID_ATHIRUMA_BOT}" -e AWS_SECRET_ACCESS_KEY=" \
{AWS_SECRET_ACCESS_KEY_DELETE_ATHIRUMA_BOT}" -e es_host="{ES_HOST}" -e es_port="{ES_PORT}" \
-e AWS_ACCESS_KEY_ID="{AWS_ACCESS_KEY_ID_ATHIRUMA_BOT}" \
-e AWS_SECRET_ACCESS_KEY="{AWS_SECRET_ACCESS_KEY_ATHIRUMA_BOT}" \
-e es_host="{ES_HOST}" -e es_port="{ES_PORT}" \
-e es_index="cloud-governance-clouds-billing-reports" \
-e S3_RESULTS_PATH="{S3_RESULTS_PATH}" \
-e ATHENA_DATABASE_NAME="{ATHENA_DATABASE_NAME}" \
Expand Down