Skip to content

Commit

Permalink
Release/1.0.1 (#23)
Browse files Browse the repository at this point in the history
* reverted back to build on all branches

* Version bump commons (#20)

* Main (#22)

* Update build.yml - added conditions for PR

* bump version to 0.0.2

* Deploying

* Deploying

* bump version to 1.0.0-rc0

* Deploying

* bump version to 1.0.0-rc1

* bump version to 1.0.0

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: cqbanh <[email protected]>

* Update to utilize new commons (#21)

* Update terraform to make PCM release tags optional

* Update submit_to_sds to utilize new auto version selection

* Fix tests

* bumping version to 1.0.1

* bump version to 1.0.1-alpha1

* Update CHANGE

* Update push on branches

* bump version to 1.0.1-rc0

* bump version to 1.0.1-rc1

---------

Co-authored-by: Josh Garde <[email protected]>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: cqbanh <[email protected]>
Co-authored-by: Curtis Banh <curtis.q.banhjpl.nasa.gov>
  • Loading branch information
4 people authored Jun 14, 2024
1 parent 805ad48 commit a07308e
Show file tree
Hide file tree
Showing 13 changed files with 557 additions and 541 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ jobs:
- name: Bump rc version
if: startsWith(github.ref, 'refs/heads/release/') && github.event_name != 'workflow_dispatch' && github.event_name != 'pull_request'
run: |
bumpver update -f --tag rc --tag-num
bumpver update -f -n --tag rc --tag-num
echo "TARGET_ENV=UAT" >> $GITHUB_ENV
- name: Release version
if: github.ref == 'refs/heads/main' && github.event_name != 'workflow_dispatch' && github.event_name != 'pull_request'
Expand Down
4 changes: 1 addition & 3 deletions CHANGE
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
podaac/swodlr-ingest-to-sds deployment
podaac/swodlr-ingest-to-sds deployment
podaac/swodlr-ingest-to-sds deployment
Version 1.0.1
2 changes: 1 addition & 1 deletion bumpver.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[bumpver]
current_version = "1.0.0"
current_version = "1.0.1-rc1"
version_pattern = "MAJOR.MINOR.PATCH[-TAGNUM]"
commit = true
tag = true
Expand Down
3 changes: 1 addition & 2 deletions podaac/swodlr_ingest_to_sds/submit_to_sds.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,13 @@
ACCEPTED_EXTS = ['nc']
INGEST_QUEUE_URL = utils.get_param('ingest_queue_url')
INGEST_TABLE_NAME = utils.get_param('ingest_table_name')
PCM_RELEASE_TAG = utils.get_param('sds_pcm_release_tag')

dynamodb = boto3.client('dynamodb')
sqs = boto3.client('sqs')

logger = utils.get_logger(__name__)
ingest_job_type = utils.mozart_client.get_job_type(
f'job-INGEST_STAGED:{PCM_RELEASE_TAG}'
utils.get_latest_job_version('job-INGEST_STAGED')
)
ingest_job_type.initialize()

Expand Down
1,072 changes: 544 additions & 528 deletions poetry.lock

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "swodlr-ingest-to-sds"
version = "1.0.0"
version = "1.0.1-rc1"
description = "A system for ingesting input products for the SWOT SDS"
authors = ["podaac-tva <[email protected]>"]
license = "Apache-2.0"
Expand Down
1 change: 0 additions & 1 deletion terraform/bin/config.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,5 @@ export TF_INPUT=false # https://www.terraform.io/cli/config/environment-variabl

export TF_VAR_region="$REGION"
export TF_VAR_stage="$VENUE"
export TF_VAR_sds_pcm_release_tag="$SWODLR_sds_pcm_release_tag"

terraform init -reconfigure -backend-config="bucket=$BUCKET" -backend-config="region=$REGION"
1 change: 0 additions & 1 deletion terraform/environments/ops.env
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
export REGION=us-west-2
export BUCKET=podaac-services-ops-terraform
export SWODLR_sds_pcm_release_tag=pcm-v5.0.0-pge-v5.0.4
1 change: 0 additions & 1 deletion terraform/environments/sit.env
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
export REGION=us-west-2
export BUCKET=podaac-services-sit-terraform
export SWODLR_sds_pcm_release_tag=pcm-v5.0.0-pge-v5.0.4
1 change: 0 additions & 1 deletion terraform/environments/uat.env
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
export REGION=us-west-2
export BUCKET=podaac-services-uat-terraform
export SWODLR_sds_pcm_release_tag=pcm-v5.0.0-pge-v5.0.4
3 changes: 3 additions & 0 deletions terraform/lambdas.tf
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ resource "aws_lambda_function" "bootstrap" {
resource "aws_lambda_function" "submit_to_sds" {
function_name = "${local.service_prefix}-submit_to_sds"
handler = "podaac.swodlr_ingest_to_sds.submit_to_sds.lambda_handler"
timeout = 300

role = aws_iam_role.lambda.arn
runtime = "python3.9"
Expand All @@ -29,6 +30,7 @@ resource "aws_lambda_function" "submit_to_sds" {
resource "aws_lambda_function" "poll_status" {
function_name = "${local.service_prefix}-poll_status"
handler = "podaac.swodlr_ingest_to_sds.poll_status.lambda_handler"
timeout = 300

role = aws_iam_role.lambda.arn
runtime = "python3.9"
Expand Down Expand Up @@ -186,6 +188,7 @@ resource "aws_iam_role" "lambda" {

# -- SSM Parameters --
resource "aws_ssm_parameter" "sds_pcm_release_tag" {
count = var.sds_pcm_release_tag == null ? 0 : 1
name = "${local.service_path}/sds_pcm_release_tag"
type = "String"
value = var.sds_pcm_release_tag
Expand Down
1 change: 1 addition & 0 deletions terraform/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ variable "region" {

variable "sds_pcm_release_tag" {
type = string
default = null
}

variable "sds_host" {
Expand Down
5 changes: 4 additions & 1 deletion tests/test_submit_to_sds.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,16 @@
with (
patch('boto3.client'),
patch('otello.mozart.Mozart.get_job_type'),
patch('podaac.swodlr_common.utilities.BaseUtilities.get_latest_job_version'), # pylint: disable-next=line-too-long # noqa: E501
patch('podaac.swodlr_ingest_to_sds.utilities.utils.get_grq_es_client') as mock_es_client, # pylint: disable-next=line-too-long # noqa: E501
patch.dict(environ, {
'SWODLR_ENV': 'dev',
'SWODLR_sds_username': 'test_username',
'SWODLR_sds_password': 'test_password',
'SWODLR_ingest_table_name': 'test_ingest_table_name',
'SWODLR_ingest_queue_url': 'test_ingest_queue_url',
'SWODLR_available_tiles_table': 'test_available_tiles_table'
'SWODLR_available_tiles_table': 'test_available_tiles_table',
'SWODLR_sds_host': 'http://sds-host.test/'
})
):
from podaac.swodlr_ingest_to_sds import submit_to_sds
Expand Down

0 comments on commit a07308e

Please sign in to comment.