Skip to content

Commit 8f28774

Browse files
authored
Merge pull request #91 from hackforla/90-contributing-toc-consistency
Contributing documentation consistency
2 parents 96344d9 + d4039b4 commit 8f28774

1 file changed

Lines changed: 30 additions & 40 deletions

File tree

CONTRIBUTING.md

Lines changed: 30 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -8,28 +8,18 @@ Below are guidelines for contributing to the devops-security repository hosted o
88
**The team recommends using [VS Code](https://code.visualstudio.com/download) as the preferred text editor for working on code, but feel free to utilize a text editor of your preference.**
99

1010
**If you have any additional questions about your contribution process, please feel free to reach out to the team in the [#ops](https://hackforla.slack.com/archives/CV7QGL66B) Slack channel.**
11-
<br><br>
12-
13-
## **Table of Contents**
14-
- [**How to Contribute to DevOps**](#how-to-contribute-to-devops)
15-
- [**Table of Contents**](#table-of-contents)
16-
- [**Setting up the local development environment**](#setting-up-the-local-development-environment)
17-
- [**Creating a personal AWS account**](#creating-a-personal-aws-account)
18-
- [**Login as root user & setup MFA**](#login-as-root-user-&-setup-mfa)
19-
- [**Setting up IAM and AWS CLI**](#setting-up-iam-and-aws-cli)
20-
- [**Create an IAM User**](#create-an-iam-user)
21-
- [**Create an IAM Group**](#create-an-iam-group)
22-
- [**Attach IAM user to IAM group**](#attach-iam-user-to-iam-group)
23-
- [**Attach `AdministratorAccess` policy to IAM group**](#attach-administratoraccess-policy-to-iam-group)
24-
- [**Generating Access Keys for AWS CLI**](#generating-access-keys-for-aws-cli)
25-
- [**Installing Terraform**](#installing-terraform)
26-
- [**Creating Backend State**](#creating-backend-state)
27-
- [**Installing Terraform docs**](#installing-terraform-docs)
28-
- [**Clone (Create) a copy on your computer**](#clone-create-a-copy-on-your-computer)
29-
- [**Create a new branch where you will work on your issue**](#create-a-new-branch-where-you-will-work-on-your-issue)
30-
- [**Creating Local tfvars file**](#creating-local-tfvars-file)
31-
- [**Terraform Setup and Execution Instructions**](#terraform-setup-and-execution-instructions)
32-
- [**Submitting changes via git and opening a PR**](#submitting-changes-via-git-and-opening-a-pr)
11+
12+
### Overview
13+
14+
- [Setting up the local development environment](#setting-up-the-local-development-environment)
15+
- AWS identity and access management
16+
- AWS CLI
17+
- Terraform
18+
- [Submitting changes via git and opening a PR](#submitting-changes-via-git-and-opening-a-pr)
19+
20+
### Table of Contents
21+
22+
A generated table of contents is available on GitHub by [opening the outline icon](https://docs.github.com/en/get-started/writing-on-github/getting-started-with-writing-and-formatting-on-github/basic-writing-and-formatting-syntax#headings) at the top of the markdown preview window.
3323

3424
## **Setting up the local development environment**
3525
The below instructions will walk you through setting up your own AWS account for local development and testing before pushing changes that will effect our infrastructure.
@@ -44,7 +34,7 @@ If you've already completed these steps or you aren't making Terraform changes,
4434
- Agree to the AWS Customer Agreement and Service Terms, complete the registration by clicking `"Create Account and Continue"`, verify your phone number via text or call, confirm your email address following the instructions in the confirmation email, and finally sign in to access your new AWS account using your email and password.
4535
- Follow this [video guide](https://youtu.be/CjKhQoYeR4Q?si=78GhlDLV5zZu8qwh) for deeper explanations.
4636

47-
<sub>[Back to Table of Contents](#table-of-contents)</sub>
37+
<sub>[Back to Top](#)</sub>
4838
***
4939

5040
### **Login as root user & setup MFA**
@@ -57,7 +47,7 @@ If you've already completed these steps or you aren't making Terraform changes,
5747

5848
**Note:** Select the `us-west-2` region. It's not required for managing IAM resources, as they are global. However, it's advisable since our other resources are in the same region.
5949

60-
<sub>[Back to Table of Contents](#table-of-contents)</sub>
50+
<sub>[Back to Top](#)</sub>
6151
***
6252

6353
## **Setting up IAM and AWS CLI**
@@ -86,7 +76,7 @@ If you've already completed these steps or you aren't making Terraform changes,
8676
```
8777
**Note:** Password length must be 20 characters
8878

89-
<sub>[Back to Table of Contents](#table-of-contents)</sub>
79+
<sub>[Back to Top](#)</sub>
9080
***
9181
- ### **Create an IAM Group**
9282

@@ -95,7 +85,7 @@ If you've already completed these steps or you aren't making Terraform changes,
9585
```bash
9686
aws iam create-group --group-name AdminGroup
9787
```
98-
<sub>[Back to Table of Contents](#table-of-contents)</sub>
88+
<sub>[Back to Top](#)</sub>
9989
***
10090
- ### **Attach IAM user to IAM group**
10191

@@ -109,7 +99,7 @@ If you've already completed these steps or you aren't making Terraform changes,
10999
```bash
110100
aws iam add-user-to-group --group-name AdminGroup --user-name octocat
111101
```
112-
<sub>[Back to Table of Contents](#table-of-contents)</sub>
102+
<sub>[Back to Top](#)</sub>
113103
***
114104
- ### **Attach `AdministratorAccess` policy to IAM group**
115105

@@ -118,7 +108,7 @@ If you've already completed these steps or you aren't making Terraform changes,
118108
```bash
119109
aws iam attach-group-policy --policy-arn arn:aws:iam::aws:policy/AdministratorAccess --group-name AdminGroup
120110
```
121-
<sub>[Back to Table of Contents](#table-of-contents)</sub>
111+
<sub>[Back to Top](#)</sub>
122112
***
123113
- Log in as the newly created user instead of continuing to log in as the root user.
124114
- ### **Generating Access Keys for AWS CLI**
@@ -133,13 +123,13 @@ If you've already completed these steps or you aren't making Terraform changes,
133123
```bash
134124
nano access_key.json
135125
```
136-
<sub>[Back to Table of Contents](#table-of-contents)</sub>
126+
<sub>[Back to Top](#)</sub>
137127
***
138128
The below steps must be completed in order to authenticate to AWS locally via the command line interface (CLI):
139129
- [Install AWS CLI](https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html)
140130
- [Set up the AWS CLI](https://docs.aws.amazon.com/cli/latest/userguide/getting-started-quickstart.html)
141131
142-
<sub>[Back to Table of Contents](#table-of-contents)</sub>
132+
<sub>[Back to Top](#)</sub>
143133
***
144134
145135
### **Creating Backend State**
@@ -189,21 +179,21 @@ aws dynamodb create-table \
189179
--billing-mode PAY_PER_REQUEST
190180
```
191181

192-
<sub>[Back to Table of Contents](#table-of-contents)</sub>
182+
<sub>[Back to Top](#)</sub>
193183
***
194184

195185
### **Installing Terraform**
196186

197187
Use the [Official HashiCorp install instructions](https://developer.hashicorp.com/terraform/install) for installing terraform.
198188

199-
<sub>[Back to Table of Contents](#table-of-contents)</sub>
189+
<sub>[Back to Top](#)</sub>
200190
***
201191

202192
### **Installing Terraform docs**
203193

204194
Follow the Terraform docs [installation guide](https://terraform-docs.io/user-guide/installation/)
205195

206-
<sub>[Back to Table of Contents](#table-of-contents)</sub>
196+
<sub>[Back to Top](#)</sub>
207197
***
208198

209199
## **Clone the repository**
@@ -230,7 +220,7 @@ You should now have a new folder in your `hackforla` folder called `devops-secur
230220
cd devops-security
231221
```
232222

233-
<sub>[Back to Table of Contents](#table-of-contents)</sub>
223+
<sub>[Back to Top](#)</sub>
234224
***
235225

236226
### **Create a new branch where you will work on your issue**
@@ -256,7 +246,7 @@ git checkout -b update-contributing-guide-15
256246

257247
When you've finished working on your issue, follow the steps below to prepare your changes to push to your repository.
258248
259-
<sub>[Back to Table of Contents](#table-of-contents)</sub>
249+
<sub>[Back to Top](#)</sub>
260250
***
261251
262252
### **Creating Local tfvars file**
@@ -266,14 +256,14 @@ After creating a backend state, create a `backend.tfvars` file in the `terraform
266256
```terraform
267257
bucket = "USERNAME-hfla-ops-terraform-state"
268258
key = "devops-security/terraform.tfstate"
269-
region = "us-east-2"
259+
region = "us-west-2"
270260
dynamodb_table = "hfla_ops_terraform_table"
271261
encrypt = true
272262
```
273263
274264
Remember to match these values to the ones in your backend state (and replace USERNAME with your username)
275265
276-
<sub>[Back to Table of Contents](#table-of-contents)</sub>
266+
<sub>[Back to Top](#)</sub>
277267
***
278268
279269
### **Terraform Setup and Execution Instructions**
@@ -307,7 +297,7 @@ terraform apply
307297
terraform destroy
308298
```
309299
310-
<sub>[Back to Table of Contents](#table-of-contents)</sub>
300+
<sub>[Back to Top](#)</sub>
311301
***
312302
313303
### Generate Terraform Docs
@@ -321,7 +311,7 @@ cd terraform # or other directory
321311
terraform-docs -c .terraform.docs.yml .
322312
```
323313
324-
<sub>[Back to Table of Contents](#table-of-contents)</sub>
314+
<sub>[Back to Top](#)</sub>
325315
***
326316
327317
### **Submitting changes via git and opening a PR**
@@ -346,5 +336,5 @@ git add terraform/aws-users.tf
346336
```
347337
- Lastly open a PR to merge your changes into the `main` branch.
348338
349-
<sub>[Back to Table of Contents](#table-of-contents)</sub>
339+
<sub>[Back to Top](#)</sub>
350340
***

0 commit comments

Comments
 (0)