summaryrefslogtreecommitdiff
path: root/infra/README.md
blob: 5b7605942c8f9accecbf05cb7c0dd453144431b2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# Infrastructure

Let's encrypt only supports up to 100 domains
per certificate so the country TLDs are split up
into three files:

* ccTLDs1
* ccTLDs2
* ccTLDs3

```
sudo certbot -d lex.surf
sudo certbot --cert-name cc1.lex.surf $(for tld in `cat ccTLDs1`; do echo -d $tld.lex.surf; done)
sudo certbot --cert-name cc2.lex.surf $(for tld in `cat ccTLDs2`; do echo -d $tld.lex.surf; done)
sudo certbot --cert-name cc3.lex.surf $(for tld in `cat ccTLDs3`; do echo -d $tld.lex.surf; done)
```

Generate NGINX `server_name` rules with:

```
printf '%s' $(for tld in `cat ccTLDs2`; do echo "$tld|"; done)
```

`/var/www/lex.surf` must be a symlink pointing to this repository.