bc-server – service status AWS
This is a status service that stores job status in AWS DynamoDB, and job output in AWS S3.
Configuration variables
The following configuration variables can be defined using the config set command. One set, the service can be loaded/reloaded using the status service reload command.
beyondcron.status.service | AWS |
aws.access.key.id | AWS access key ID. |
aws.secret.access.key | AWS access key secret. |
aws.region | AWS region. |
aws.table.current | Name of DynamoDB table containing the current status of each job. |
aws.table.history | Name of DynamoDB table containing the each jobs status history. |
aws.s3.bucket | The S3 bucket containing the output of each job. |
aws.s3.object.prefix | The prefix to use when naming output objects. Default is beyondcron/status/output , unless BEYONDCRON_CLUSTER_NAME has been set, in which case the default value is beyondcron/BEYONDCRON_CLUSTER_NAME/status/output. |
Notes:
- aws.secret.access.key is a secret configuration variable, and as such can only be viewed by users with write access to /_beyondcron/configuration.
- if aws.access.key.id, aws.secret.access.key & aws.region are all undefined, AND an AWS config service is configured, BeyondCron will attempt to use the config service environment variables
AWS_ACCESS_KEY_ID
,AWS_SECRET_ACCESS_KEY
&AWS_REGION
to connect to AWS.
Limits
- This service does not support wildcard queries as used by by job history.
AWS Permissions
This service requires the following AWS permissions:
Actions:
- dynamodb:CreateTable – if you wish to allow BeyondCron to create aws.table.current & aws.table.history if they do not exist.
- dynamodb:DescribeTable
- dynamodb:Query
- dynamodb:Scan
- dynamodb:GetItem
- dynamodb:PutItem
- dynamodb:UpdateItem
Resources:
- arn:aws:dynamodb:aws.region:account-id:table/aws.table.current
- arn:aws:dynamodb:aws.region:account-id:table/aws.table.history
Actions:
- s3:CreateBucket – if you wish to allow BeyondCron to create aws.s3.bucket if it does not exist.
- s3:ListBucket
Resources:
- arn:aws:s3:::aws.s3.bucket
Actions:
- s3:GetObject
- s3:PutObject
- s3:DeleteObject
Resources:
- arn:aws:s3:::aws.s3.bucket/*
DynamoDB tables
This service requires the following tables:
Table | Partition key | Sort key | Required permissions |
---|---|---|---|
aws.table.current | name (String) | – | Read/Write |
aws.table.history | name (String) | timestamp (Number) | Read/Write |
If the aws.access.key.id account has permission, BeyondCron will create these tables if they do not already exist.
S3 Bucket
This service requires the following bucket.
Bucket | Required permissions |
---|---|
aws.s3.bucket | Read/Write |
If the aws.access.key.id account has permission, BeyondCron will create the bucket if it does not already exist.
Example
BeyondCron % config set aws.access.key.id AKIAIT…
BeyondCron % config set aws.secret.access.key o0BQNc…
BeyondCron % config set aws.region us-west-1
BeyondCron % config set aws.table.current bc-status-current
BeyondCron % config set aws.table.history bc-status-history
BeyondCron % config set aws.s3.bucket bc-status-output
BeyondCron % config set beyondcron.status.service AWS
BeyondCron % status service reload
Setup AWS using the same configuration oas the AWS config service.
BeyondCron % config set aws.table.current bc-status-current
BeyondCron % config set aws.table.history bc-status-history
BeyondCron % config set aws.s3.bucket bc-status-output
BeyondCron % config set beyondcron.status.service AWS
BeyondCron % status service reload
See also
Reference
- Amazon AWS
- Amazon DynamoDB
- Amazon S3
- Working with AWS Credentials
- AWS Region Selection