You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+60-18Lines changed: 60 additions & 18 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -58,11 +58,7 @@ This plane is where the actual infrastructure exists including clusters, databas
58
58
59
59
## How to spin up your Humanitec AWS Reference Architecture
60
60
61
-
This repo contains an implementation of part of the Humanitec Reference Architecture for an Internal Developer Platform.
62
-
63
-
To install an implementation containing add-ons, follow the separate README. We currently feature these add-ons:
64
-
65
-
*[Base layer plus Backstage](examples/with-backstage/)
61
+
This repo contains an implementation of part of the Humanitec Reference Architecture for an Internal Developer Platform, including Backstage as optional Portal solution.
66
62
67
63
This repo covers the base layer of the implementation for AWS.
68
64
@@ -101,13 +97,13 @@ This reference architecture implementation uses Terraform. You will need to do t
101
97
102
98
For example:
103
99
104
-
```
100
+
```shell
105
101
export HUMANITEC_TOKEN="my-humanitec-api-token"
106
102
```
107
103
108
104
5. Run terraform:
109
105
110
-
```
106
+
```shell
111
107
terraform init
112
108
terraform plan
113
109
terraform apply
@@ -125,34 +121,34 @@ Check for the existence of key elements of the reference architecture. This is a
125
121
126
122
1. Set the `HUMANITEC_ORG` environment variable to the ID of your Humanitec Organization (must be all lowercase):
127
123
128
-
```
124
+
```shell
129
125
export HUMANITEC_ORG="my-humanitec-org"
130
126
```
131
127
132
128
2. Verify the existence of the Resource Definition for the EKS cluster in your Humanitec Organization:
3. Verify the existence of the newly created EKS cluster:
148
144
149
-
```
145
+
```shell
150
146
aws eks list-clusters --region <your-region>
151
147
```
152
148
153
149
This should output:
154
150
155
-
```
151
+
```json
156
152
{
157
153
"clusters": [
158
154
"ref-arch",
@@ -161,17 +157,55 @@ Check for the existence of key elements of the reference architecture. This is a
161
157
}
162
158
```
163
159
160
+
### Enable a portal (optional)
161
+
162
+
#### Portal Prerequisites
163
+
164
+
Backstage requires a GitHub connection, which in turn needs:
165
+
166
+
* A GitHub organization and permission to create new repositories in it. Go to <https://github.com/account/organizations/new> to create a new org (the "Free" option is fine). Note: is has to be an organization, a free account is not sufficient.
167
+
* Create a classic github personal access token with `repo`, `workflow`, `delete_repo` and `admin:org` scope [here](https://github.com/settings/tokens).
168
+
* Set the `GITHUB_TOKEN` environment variable to your token.
169
+
170
+
```shell
171
+
export GITHUB_TOKEN="my-github-token"
172
+
```
173
+
174
+
* Set the `GITHUB_ORG_ID` environment variable to your GitHub organization ID.
175
+
176
+
```shell
177
+
export GITHUB_ORG_ID="my-github-org-id"
178
+
```
179
+
180
+
* Install the GitHub App for Backstage into your GitHub organization
181
+
* Run `docker run --rm -it -e GITHUB_ORG_ID -v $(pwd):/pwd -p 127.0.0.1:3000:3000 ghcr.io/humanitec-architecture/create-gh-app` ([image source](https://github.com/humanitec-architecture/create-gh-app/)) and follow the instructions:
182
+
* “All repositories” ~> Install
183
+
* “Okay, […] was installed on the […] account.” ~> You can close the window and server.
184
+
185
+
#### Portal Usage
186
+
187
+
* Enable `with_backstage` inside your `terraform.tfvars` and configure the additional variables that a required for Backstage.
188
+
* Perform another `terraform apply`
189
+
190
+
#### Verify portal setup
191
+
192
+
*[Fetch the DNS entry](https://developer.humanitec.com/score/getting-started/get-dns/) of the Humanitec Application `backstage`, Environment `development`.
193
+
* Open the host in your browser.
194
+
* Click the "Create" button and scaffold your first application.
195
+
164
196
### Cleaning up
165
197
166
198
Once you are finished with the reference architecture, you can remove all provisioned infrastructure and the resource definitions created in Humanitec with the following:
167
199
168
-
1.Ensure you are (still) logged in with `aws`.
200
+
1.Delete all Humanitec Applications scaffolded using the Portal, if you used one, but not the `backstage` app itself.
169
201
170
-
2. Ensure you still have the `HUMANITEC_TOKEN` environment variable set to an appropriate Humanitec API token with the `Administrator` role on the Humanitec Organization.
202
+
2. Ensure you are (still) logged in with `aws`.
171
203
172
-
3.Run terraform:
204
+
3.Ensure you still have the `HUMANITEC_TOKEN` environment variable set to an appropriate Humanitec API token with the `Administrator` role on the Humanitec Organization.
173
205
174
-
```
206
+
4. Run terraform:
207
+
208
+
```shell
175
209
terraform destroy
176
210
```
177
211
@@ -184,25 +218,33 @@ Once you are finished with the reference architecture, you can remove all provis
0 commit comments