-
Notifications
You must be signed in to change notification settings - Fork 50
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #14 from aws-samples/code-quality
Added contribution guide, updated readme and added pre-commit tool
- Loading branch information
Showing
71 changed files
with
207 additions
and
145 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
account: '\d{12}' | ||
account: "\d{12}" | ||
account=\d{12} | ||
account=\d{12} |
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 |
---|---|---|
|
@@ -33,4 +33,4 @@ single-node-deploy*.json | |
ha-nodes-deploy*.json | ||
|
||
*.OLD | ||
.env | ||
.env |
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
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 |
---|---|---|
@@ -1,5 +1,25 @@ | ||
# AWS Blockchain Node Runners | ||
|
||
This repository contains sample [AWS Cloud Development Kit (CDK)](https://aws.amazon.com/cdk/) applications that help to set up and run self-service blockchain nodes for different protocols on AWS. | ||
This repository contains sample [AWS Cloud Development Kit (CDK)](https://aws.amazon.com/cdk/) applications (Node Runner blueprints) to deploy on AWS self-service blockchain nodes for various protocols. For more information see [Introducing AWS Blockchain Node Runners](https://aws-samples.github.io/aws-blockchain-node-runners/docs/intro). | ||
|
||
- [Setup instructions for Ethereum nodes on AWS](./lib/ethereum/README.md) | ||
### Documentation | ||
For deployment instructions see [AWS Blockchain Node Runners Blueprints](https://aws-samples.github.io/aws-blockchain-node-runners/docs/Blueprints/intro) | ||
|
||
### Contributing | ||
See [CONTRIBUTING](./CONTRIBUTING.md) for more information. | ||
|
||
### Directory structure | ||
|
||
- `docs` - General documentation applicable to all Node Runner blueprints (CDK applications within the `./lib` directory) | ||
- `lib` - The place for all Node Runner blueprints and shared re-usable [CDK constructs](https://docs.aws.amazon.com/cdk/v2/guide/constructs.html) | ||
- `lib/constructs` - [CDK constructs](https://docs.aws.amazon.com/cdk/v2/guide/constructs.html) used in Node Runner blueprints | ||
- `lib/your-chain` - Node Runner blueprint for a specific chain | ||
- `lib/your-chain/doc` - Documentation specific to the Node Runner blueprint | ||
- `lib/your-chain/lib` - Place for CDK stacks and other blueprint assets | ||
- `lib/your-chain/sample-configs` - Place for sample configurations to deploy Node Runner blueprint to your environment | ||
- `lib/your-chain/test` - Place for unit tests to verify the Node Runner blueprint creates all necessary infrastructure | ||
- `website` - Content for the project web site built with [Docusaurus](https://docusaurus.io/) | ||
- `website/docs` - Place for the new blueprint deployment instructions. (If you are adding a new blueprint, use on of the existing examples to refer to the `README.md` file within your Node Runner blueprint directory inside `lib`). | ||
|
||
### License | ||
This repository uses MIT License. See more in [LICENSE](./LICENSE) |
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,43 @@ | ||
# Pre-merge tools | ||
|
||
We need your help to achieve better code quality and make sure the blueprints stay secure. Before merging your new commit, please set up and run the following tools on your development machine. | ||
|
||
1. [git-secrets](https://github.com/awslabs/git-secrets) | ||
|
||
```bash | ||
# Install (Mac OS) | ||
npm run install-git-secrets-mac | ||
|
||
# Install on other platforms: https://github.com/awslabs/git-secrets#installing-git-secrets | ||
|
||
# Setup | ||
npm run setup-git-secrets | ||
|
||
# Scan history | ||
npm run scan-history-git-secrets | ||
|
||
# Scan repository | ||
npm run scan-repo-git-secrets | ||
``` | ||
|
||
2. [semgrep](https://github.com/semgrep/semgrep) | ||
|
||
```bash | ||
# Install (Mac OS) | ||
npm run install-semgrep-mac | ||
|
||
# Install on other platforms: https://github.com/semgrep/semgrep#option-2-getting-started-from-the-cli | ||
|
||
# Scan | ||
npm run scan-semgrep | ||
``` | ||
|
||
3. [pre-commit](https://pre-commit.com) | ||
|
||
```bash | ||
# Install (Mac OS) | ||
npm run install-pre-commit-mac | ||
|
||
# Run | ||
npm run run-pre-commit | ||
``` |
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,4 +1,4 @@ | ||
export const InstanceStoreageDeviceVolumeType = "instance-store"; | ||
export const NoneValue = "none"; | ||
export const VolumeDeviceNames = ["/dev/sdf", "/dev/sdg", "/dev/sdh", "/dev/sdi", "/dev/sdj", "/dev/sdk"] | ||
export const GibibytesToBytesConversionCoefficient = 1073741824; | ||
export const GibibytesToBytesConversionCoefficient = 1073741824; |
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
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
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
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
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 |
---|---|---|
|
@@ -73,4 +73,4 @@ | |
} | ||
} | ||
} | ||
} | ||
} |
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 |
---|---|---|
|
@@ -270,4 +270,4 @@ export const SyncNodeCWDashboardJSON = { | |
} | ||
} | ||
] | ||
} | ||
} |
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
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
Oops, something went wrong.