diff --git a/NOTICE b/NOTICE index 616fc58..49e6157 100644 --- a/NOTICE +++ b/NOTICE @@ -1 +1,2 @@ +aws-scheduled-event-adjuster Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. diff --git a/adjust_schedule_function/adjust_schedule/__init__.py b/adjust_schedule_function/adjust_schedule/__init__.py index e69de29..04f8b7b 100644 --- a/adjust_schedule_function/adjust_schedule/__init__.py +++ b/adjust_schedule_function/adjust_schedule/__init__.py @@ -0,0 +1,2 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 diff --git a/adjust_schedule_function/adjust_schedule/app.py b/adjust_schedule_function/adjust_schedule/app.py index 7a3149b..6cfc005 100644 --- a/adjust_schedule_function/adjust_schedule/app.py +++ b/adjust_schedule_function/adjust_schedule/app.py @@ -1,3 +1,6 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 + import boto3 from lib.events import EventBus from lib.processors.autoscaling import AutoScalingGroupProcessor diff --git a/adjust_schedule_function/lib/__init__.py b/adjust_schedule_function/lib/__init__.py index 77479f7..dbb0ae3 100644 --- a/adjust_schedule_function/lib/__init__.py +++ b/adjust_schedule_function/lib/__init__.py @@ -1,4 +1,6 @@ # coding: utf-8 +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 from __future__ import absolute_import diff --git a/adjust_schedule_function/lib/events.py b/adjust_schedule_function/lib/events.py index 4fa8d69..42e922e 100644 --- a/adjust_schedule_function/lib/events.py +++ b/adjust_schedule_function/lib/events.py @@ -1,3 +1,6 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 + import json class Event: diff --git a/adjust_schedule_function/lib/processors/__init__.py b/adjust_schedule_function/lib/processors/__init__.py index e69de29..04f8b7b 100644 --- a/adjust_schedule_function/lib/processors/__init__.py +++ b/adjust_schedule_function/lib/processors/__init__.py @@ -0,0 +1,2 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 diff --git a/adjust_schedule_function/lib/processors/autoscaling.py b/adjust_schedule_function/lib/processors/autoscaling.py index b09b556..3f0ab2c 100644 --- a/adjust_schedule_function/lib/processors/autoscaling.py +++ b/adjust_schedule_function/lib/processors/autoscaling.py @@ -1,3 +1,6 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 + from lib import utils from lib.processors.base import ResourceProcessor diff --git a/adjust_schedule_function/lib/processors/base.py b/adjust_schedule_function/lib/processors/base.py index 5cdb5b2..9a6d810 100644 --- a/adjust_schedule_function/lib/processors/base.py +++ b/adjust_schedule_function/lib/processors/base.py @@ -1,3 +1,6 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 + class ResourceProcessor: def __init__(self, tag_prefix): self._tag_prefix = tag_prefix diff --git a/adjust_schedule_function/lib/processors/eventbridge.py b/adjust_schedule_function/lib/processors/eventbridge.py index e19fa8e..e6c54c7 100644 --- a/adjust_schedule_function/lib/processors/eventbridge.py +++ b/adjust_schedule_function/lib/processors/eventbridge.py @@ -1,3 +1,6 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 + from lib import utils from lib.processors.base import ResourceProcessor diff --git a/adjust_schedule_function/lib/recurrence.py b/adjust_schedule_function/lib/recurrence.py index a37617b..6f11fff 100644 --- a/adjust_schedule_function/lib/recurrence.py +++ b/adjust_schedule_function/lib/recurrence.py @@ -1,3 +1,6 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 + from crontab import CronTab from dateutil import parser from datetime import datetime, timedelta diff --git a/adjust_schedule_function/lib/services.py b/adjust_schedule_function/lib/services.py index d9c4676..3767af3 100644 --- a/adjust_schedule_function/lib/services.py +++ b/adjust_schedule_function/lib/services.py @@ -1,3 +1,6 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 + import boto3 diff --git a/adjust_schedule_function/lib/utils.py b/adjust_schedule_function/lib/utils.py index 900469b..5a49c98 100644 --- a/adjust_schedule_function/lib/utils.py +++ b/adjust_schedule_function/lib/utils.py @@ -1,3 +1,6 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 + def get_tag_by_key(tags, key): tags = list(filter(lambda t: t['Key'] == key, tags)) if len(tags): diff --git a/buildspec.yaml b/buildspec.yaml index ebaa912..144b594 100644 --- a/buildspec.yaml +++ b/buildspec.yaml @@ -1,3 +1,6 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 + version: 0.2 env: diff --git a/conftest.py b/conftest.py index 51ae4b7..b8ab374 100644 --- a/conftest.py +++ b/conftest.py @@ -1,3 +1,6 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 + import sys, os sys.path.insert(0, os.path.abspath("adjust_schedule_function")) diff --git a/pipeline.yaml b/pipeline.yaml index d56f477..8d72e22 100644 --- a/pipeline.yaml +++ b/pipeline.yaml @@ -1,3 +1,5 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 AWSTemplateFormatVersion: '2010-09-09' Description: > diff --git a/send-event.sh b/send-event.sh index a4444b7..bcb2ec7 100755 --- a/send-event.sh +++ b/send-event.sh @@ -1,4 +1,6 @@ #!/bin/bash +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 aws events put-events \ --entries '[ diff --git a/template.yaml b/template.yaml index c16fd35..eef64e2 100644 --- a/template.yaml +++ b/template.yaml @@ -1,3 +1,5 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 AWSTemplateFormatVersion: '2010-09-09' Transform: AWS::Serverless-2016-10-31 diff --git a/tests/unit/__init__.py b/tests/unit/__init__.py index e69de29..04f8b7b 100644 --- a/tests/unit/__init__.py +++ b/tests/unit/__init__.py @@ -0,0 +1,2 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 diff --git a/tests/unit/processors/test_autoscaling.py b/tests/unit/processors/test_autoscaling.py index 314e46e..747c645 100644 --- a/tests/unit/processors/test_autoscaling.py +++ b/tests/unit/processors/test_autoscaling.py @@ -1,3 +1,6 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 + from lib.processors.autoscaling import AutoScalingGroupProcessor from lib.recurrence import RecurrenceCalculator from lib.services import AutoScalingService diff --git a/tests/unit/processors/test_eventbridge.py b/tests/unit/processors/test_eventbridge.py index 5790f50..8fafeae 100644 --- a/tests/unit/processors/test_eventbridge.py +++ b/tests/unit/processors/test_eventbridge.py @@ -1,3 +1,6 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 + from lib.processors.eventbridge import EventBridgeProcessor from lib.recurrence import RecurrenceCalculator from lib.services import EventBridgeService diff --git a/tests/unit/services/__init__.py b/tests/unit/services/__init__.py index e69de29..04f8b7b 100644 --- a/tests/unit/services/__init__.py +++ b/tests/unit/services/__init__.py @@ -0,0 +1,2 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 diff --git a/tests/unit/services/test_autoscaling.py b/tests/unit/services/test_autoscaling.py index cf9d888..2e817c2 100644 --- a/tests/unit/services/test_autoscaling.py +++ b/tests/unit/services/test_autoscaling.py @@ -1,3 +1,6 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 + import boto3 from botocore.stub import Stubber from datetime import datetime diff --git a/tests/unit/services/test_eventbridge.py b/tests/unit/services/test_eventbridge.py index ac18d1e..d55f0b6 100644 --- a/tests/unit/services/test_eventbridge.py +++ b/tests/unit/services/test_eventbridge.py @@ -1,3 +1,6 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 + import boto3 from botocore.stub import Stubber from lib.services import EventBridgeService diff --git a/tests/unit/test_events.py b/tests/unit/test_events.py index 3c20139..876aa7f 100644 --- a/tests/unit/test_events.py +++ b/tests/unit/test_events.py @@ -1,3 +1,6 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 + import boto3 from botocore.stub import Stubber from lib.events import EventBus diff --git a/tests/unit/test_recurrence.py b/tests/unit/test_recurrence.py index 2b23a63..b235a7c 100644 --- a/tests/unit/test_recurrence.py +++ b/tests/unit/test_recurrence.py @@ -1,3 +1,6 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 + from datetime import datetime import pytest from lib.recurrence import parse_cron_expression, RecurrenceCalculator, TimeSource diff --git a/tests/unit/test_utils.py b/tests/unit/test_utils.py index d7ec058..53a47af 100644 --- a/tests/unit/test_utils.py +++ b/tests/unit/test_utils.py @@ -1,3 +1,6 @@ +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 + import pytest from lib import utils