Skip to content

Latest commit

 

History

History
79 lines (53 loc) · 2.89 KB

CONTRIBUTING.md

File metadata and controls

79 lines (53 loc) · 2.89 KB

License MIT contributions welcome

How to contribute to Org-formation

Need to ask questions?

Org-formation discussions are done through chat, join the slack channel then start a conversation.

Did you find a bug?

  • Ensure the bug was not already reported by searching on GitHub under Issues.

  • If you're unable to find an open issue addressing the problem, open a new one.

Did you write a patch that fixes a bug?

  • Open a new GitHub pull request with the patch.

  • Ensure the PR description clearly describes the problem and solution. Include the relevant issue number if applicable.

Do you intend to add a new feature or change an existing one?

  • Suggest your change in the org-formation slack channel to make sure the community is aware of your approach otherwise you may have a difficult time getting your changes approved.

Development Environment

We recommend setting up the following development environment:

  • An AWS Master (or management) account
  • Two organization OUs (dev and prod)
  • Two AWS member accounts
  • An org-formation project

Testing

While developing your PR you may find these tasks useful.

Building:

npm run build

Linting:

npm run lint:fix

Run unit tests:

npm run test

To run the local version execute npm link then you can run with ofn command from any directory. To uninstall execute npm unlink -g.

To preview templates from your project execute:

ofn print-tasks organization-tasks.yaml --output yaml --max-concurrent-stacks 100 --max-concurrent-tasks 100

Note: output are in .printed-stacks folder

To validate the generated templates execute:

ofn validate-tasks organization-tasks.yaml --failed-tasks-tolerance 0  --max-concurrent-stacks 100 --max-concurrent-tasks 100

Debugging

The general way to run org-formation using your IDE is to setup a npm configuration and execute one of the scripts in the scripts section of the package.json file.

Example scripts:

  • "start:print-tasks": "npx --quiet ts-node cli.ts print-tasks /Users/jsmith/my-ofn-project/organization-tasks.yaml --output yaml"
  • "start:validate-tasks": "npx --quiet ts-node cli.ts validate-tasks /Users/jsmith/my-ofn-project/organization-tasks.yaml --failed-tasks-tolerance 0"