Skip to content

Commit

Permalink
docs: write documentation for release 0.11.0 (#423)
Browse files Browse the repository at this point in the history
  • Loading branch information
purpleclay authored Nov 10, 2023
1 parent 094b08d commit 4db02d5
Show file tree
Hide file tree
Showing 11 changed files with 68 additions and 28 deletions.
4 changes: 0 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,6 @@ Written in Go, dns53 is incredibly small and easy to install.

https://user-images.githubusercontent.com/106762954/200760788-f0d78147-9e3f-4f7d-8606-1050895597dc.mp4

<div>
<sub>recorded using <a href="https://github.com/charmbracelet/vhs" target="_blank">VHS</a> 💜</sub>
</div>

## Badges

[![Build status](https://img.shields.io/github/actions/workflow/status/purpleclay/dns53/ci.yml?style=flat-square&logo=go)](https://github.com/purpleclay/dns53/actions?workflow=ci)
Expand Down
2 changes: 0 additions & 2 deletions docs/configure/auto-attachment.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
description: "Automatically attach your EC2 to a default Route53 Private Hosted Zone"
icon: material/connection
status: new
---

# Auto Attachment of your EC2
Expand All @@ -19,7 +18,6 @@ For this to work as intended, `dns53` handles two attachment scenarios, removing
<source src="../../static/dns53-auto-attach.webm" type="video/webm">
<source src="../../static/dns53-auto-attach.mp4" type="video/mp4">
</video>
<sub>recorded using <a href="https://github.com/charmbracelet/vhs" target="_blank">VHS</a> 💜</sub>
</div>

## You are the first Auto Attachment
Expand Down
1 change: 0 additions & 1 deletion docs/configure/broadcast-ec2.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,5 +32,4 @@ dns53 --phz-id Z05504861FO8RFR02KU72
<source src="../../static/dns53-phzid.webm" type="video/webm">
<source src="../../static/dns53-phzid.mp4" type="video/mp4">
</video>
<sub>recorded using <a href="https://github.com/charmbracelet/vhs" target="_blank">VHS</a> 💜</sub>
</div>
1 change: 0 additions & 1 deletion docs/configure/iam.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
description: "Understand what Identity Access Management (IAM) permissions are needed for dns53 to run"
icon: material/shield-lock-outline
status: new
---

# IAM Permissions
Expand Down
39 changes: 39 additions & 0 deletions docs/configure/tracing-requests.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
---
description: "Launch a reverse proxy for tracing requests in to your EC2"
icon: material/shoe-print
status: new
---

# Tracing Requests with a Reverse Proxy

To trace requests sent to your broadcasted EC2, `dns53` comes bundled with an internal reverse proxy. To enable proxying:

```{ .sh .no-select }
dns53 --proxy
```

Once enabled, set the required environment variables to trace both `HTTP` and `HTTPS` requests. It is advised not to proxy any requests to IMDS on your EC2.

```{ .sh .no-select }
export HTTP_PROXY=http://localhost:10080
export HTTPS_PROXY=http://localhost:10080
export NO_PROXY=169.254.169.254
```

```{ .sh .no-select }
curl http://httpbin.org/headers
```

```{ .sh .no-select }
curl https://httpbin.org/ip -k
```

If you do not wish to set any of these environment variables, your preferred CLI tool should support request proxying using a dedicated flag. For `curl`, that is `-x`.

## Changing the proxy port

Feel free to change the default proxy port of `:10080` by using the `proxy-port` flag:

```{ .sh .no-select }
dns53 --proxy --proxy-port 10888
```
5 changes: 1 addition & 4 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,12 @@
# dns53
# DNS 53

Dynamic DNS within Amazon Route 53. Expose your EC2 quickly, easily, and privately within a Route 53 Private Hosted Zone (PHZ).

Easily collaborate with a colleague by exposing your EC2 within a team VPC. You could even hook up a locally running application to a local k3d cluster using an ExternalName service during development. Once your EC2 is exposed, control how it is accessed through your EC2 security groups.

Written in Go, `dns53` is incredibly small and easy to install.

<div>
<video controls>
<source src="./static/dns53.webm" type="video/webm">
<source src="./static/dns53.mp4" type="video/mp4">
</video>
<sub>recorded using <a href="https://github.com/charmbracelet/vhs" target="_blank">VHS</a> 💜</sub>
</div>
2 changes: 1 addition & 1 deletion docs/install/source.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ icon: material/file-code-outline

# Compiling from Source

Download both [Go 1.19+](https://go.dev/doc/install) and [go-task](https://taskfile.dev/#/installation). Then clone the code from GitHub:
Download both [Go 1.21+](https://go.dev/doc/install) and [go-task](https://taskfile.dev/#/installation). Then clone the code from GitHub:

```sh
git clone https://github.com/purpleclay/dns53.git
Expand Down
9 changes: 5 additions & 4 deletions docs/reference/cli/dns53-imds.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,20 +11,21 @@ Toggle EC2 IMDS features

## Usage

```text
```{ .text .no-select .no-copy }
dns53 imds [flags]
```

## Flags

```text
```{ .text .no-select .no-copy }
-h, --help help for imds
--instance-metadata-tags string toggle the inclusion of EC2 instance tags within IMDS (on|off)
--instance-metadata-tags string toggle the inclusion of EC2 instance tags
within IMDS (on|off)
```

## Global Flags

```text
```{ .text .no-select .no-copy }
--profile string the AWS named profile to use when loading credentials
--region string the AWS region to use when querying AWS
```
6 changes: 3 additions & 3 deletions docs/reference/cli/dns53-tags.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,19 @@ Lists all available EC2 instance tags and how to use them with Go templating

## Usage

```text
```{ .text .no-select .no-copy }
dns53 tags [flags]
```

## Flags

```text
```{ .text .no-select .no-copy }
-h, --help help for tags
```

## Global Flags

```text
```{ .text .no-select .no-copy }
--profile string the AWS named profile to use when loading credentials
--region string the AWS region to use when querying AWS
```
26 changes: 18 additions & 8 deletions docs/reference/cli/dns53.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ description: "Learn how to use the DNS 53 command line for privately broadcastin
icon: material/console
social:
cards: false
status: new
---

# Command Line
Expand All @@ -13,27 +14,36 @@ Your EC2 will be exposed through a dynamically generated resource record that wi

## Usage

```text
```{ .text .no-select .no-copy }
dns53 [flags]
dns53 [command]
```

## Flags

```text
--auto-attach automatically create and attach a record set to a default private hosted zone
--domain-name string assign a custom domain name when generating a record set
```{ .text .no-select .no-copy }
--auto-attach automatically create and attach a record set to a
default private hosted zone
--domain-name string assign a custom domain name when generating a record
set
-h, --help help for dns53
--phz-id string an ID of a Route53 private hosted zone to use when generating a record set
--phz-id string an ID of a Route53 private hosted zone to use when
generating a record set
--profile string the AWS named profile to use when loading credentials
--proxy enable a reverse proxy for tracing requests to this
ec2
--proxy-port int the port assigned to the proxy when enabled
(default 10080)
--region string the AWS region to use when querying AWS
```

## Commands

```text
completion Generate completion script for your target shell
```{ .text .no-select .no-copy }
completion Generate the autocompletion script for the specified shell
help Help about any command
imds Toggle EC2 IMDS features
version Prints the build time version information
tags Lists all available EC2 instance tags and how to use them with Go
templating
version Print build time version information
```
1 change: 1 addition & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ nav:
- Expose EC2 Tags: configure/exposing-tags.md
- List EC2 Tags: configure/list-tags.md
- IAM: configure/iam.md
- Tracing Requests: configure/tracing-requests.md
- Installation:
- Binary: install/binary.md
- From Source: install/source.md
Expand Down

0 comments on commit 4db02d5

Please sign in to comment.