-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
ngr
committed
Jul 10, 2019
1 parent
730e7c7
commit a030b7b
Showing
7 changed files
with
140 additions
and
43 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
"""Sosw Essential Orchestrator | ||
""" | ||
|
||
import logging | ||
|
||
from sosw.orchestrator import Orchestrator | ||
from sosw.app import LambdaGlobals, get_lambda_handler | ||
|
||
logger = logging.getLogger() | ||
logger.setLevel(logging.INFO) | ||
|
||
|
||
class Essential(Orchestrator): | ||
pass | ||
|
||
|
||
global_vars = LambdaGlobals() | ||
lambda_handler = get_lambda_handler(Essential, global_vars) |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
sosw |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
AWSTemplateFormatVersion: "2010-09-09" | ||
Description: "CloudWatch ScheduledEvents for Orchestrator and Scavenger" | ||
|
||
Resources: | ||
ScheduledRuleSoswOrchestrator: | ||
Type: "AWS::Events::Rule" | ||
Properties: | ||
Description: "Scheduler for sosw_orchestrator /1 min" | ||
ScheduleExpression: "rate(1 minute)" | ||
State: "ENABLED" | ||
Targets: | ||
- | ||
Arn: | ||
- Fn::ImportValue: "sosw-lambda-orchestrator" | ||
Id: "SoswOrchestrator" | ||
|
||
|
||
# Each Lambda to be triggered by ScheduledRules should provide permissions for that. | ||
# These Permissions are usually in some generic Policy, but for this example they are directly | ||
# in the YAML templates of functions. |
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
16 changes: 8 additions & 8 deletions
16
docs/yaml/autotest-bucket.yaml → docs/yaml/sosw-s3-bucket.yaml
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,25 @@ | ||
AWSTemplateFormatVersion: "2010-09-09" | ||
Description: "autotest-bucket" | ||
Description: "sosw-s3-bucket" | ||
|
||
|
||
Parameters: | ||
|
||
AutotestBucketName: | ||
SoswBucketName: | ||
Description: "S3 bucket used for storing Lambda packages." | ||
Type: String | ||
Default: 'autotest-bucket' | ||
Default: 'sosw-s3' | ||
|
||
|
||
Resources: | ||
AutotestBucket: | ||
SoswBucket: | ||
Type: AWS::S3::Bucket | ||
Properties: | ||
BucketName: !Sub "${AutotestBucketName}" | ||
BucketName: !Sub "${SoswBucketName}-${AWS::AccountId}" | ||
|
||
|
||
Outputs: | ||
AutotestBucket: | ||
SoswBucket: | ||
Description: "Sample Bucket for Packages and Other Artifacts" | ||
Value: !Ref AutotestBucket | ||
Value: !Ref SoswBucket | ||
Export: | ||
Name: "autotest-bucket" | ||
Name: "sosw-s3-bucket" |
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