Skip to content

Commit

Permalink
Removes the Ophan Dist S3 bucket dependency from the friendly hostnam…
Browse files Browse the repository at this point in the history
…es role
  • Loading branch information
SHession committed Dec 2, 2024
1 parent efd0b1b commit a837d63
Show file tree
Hide file tree
Showing 4 changed files with 3,144 additions and 13 deletions.
10 changes: 1 addition & 9 deletions roles/friendly-hostnames/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@ and it isn't necessary to name them. Sometimes you want to treat them more like
Perhaps they hold data meaning there is a risk associated with indiscriminately killing them and replacing them with
another. You may benefit from knowing which server you have up at a given time.

The feature sets the hostname for your server and applies an AWS "Name" tag. The name is chosen from a list of names,
defaulting to ~3000 names at `https://s3-eu-west-1.amazonaws.com/ophan-dist/ophan/elasticsearch/hostnames.txt`.
The feature sets the hostname for your server and applies an AWS "Name" tag. The name is chosen from a list of ~3000 feminists names.

You will need to run the following script in your cloud init

Expand All @@ -20,13 +19,6 @@ A hostname will be chosen at random and formatted to a
[valid hostname](https://en.wikipedia.org/wiki/Hostname#Restrictions_on_valid_hostnames),
only including the characters [^A-Za-z].

If you would like to override the default list and supply your own names you will need to specify your hostnames URL,
for example

```
hostnames_url: https://example.com/hostnames.txt
```

You might need to consider the [birthday problem](https://en.wikipedia.org/wiki/Birthday_problem) when choosing your
list size. For a cluster of size `s`, and a probability of `p` of a name clash (hopefully low, less than `0.05`), you'll
need a hostnames list of length `s^2 / 2 * p`.
2 changes: 0 additions & 2 deletions roles/friendly-hostnames/defaults/main.yml

This file was deleted.

Loading

0 comments on commit a837d63

Please sign in to comment.