Skip to content

Commit 3a7a409

Browse files
authored
Update the free matrix server article/guide (#1073)
1 parent 9255200 commit 3a7a409

File tree

1 file changed

+21
-45
lines changed

1 file changed

+21
-45
lines changed

gatsby/content/docs/free-small-matrix-server.mdx

Lines changed: 21 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
title: 'Free Small Matrix Server'
2+
title: 'Free Matrix Server using Oracle Cloud'
33
author: Paul Tötterman <[email protected]>
44
layout: post
55
section: Server Setup
@@ -20,9 +20,10 @@ Ingredients:
2020

2121
## Free domain name
2222

23-
Get one from [Freenom] for free or any other place you wish. Freenom only gives
24-
free domains for a year. A Matrix server cannot be [migrated] from one domain to
25-
another, so you might want to get a longer-lived one.
23+
Get one from [Freenom] or [DuckDNS] for free or any other place you wish.
24+
Freenom can be tricky to renew for free after the first year. A Matrix server
25+
cannot be [migrated] from one domain to another, so you might want to get a
26+
longer-lived one.
2627

2728
- https://tld-list.com/ - find cheap domains, look at renewal fees also
2829
- https://www.namecheap.com/promos/99-cent-domain-names/ - cheap first year
@@ -32,19 +33,20 @@ aren't sufficient). To do this I added the domain on the free [Cloudflare] plan.
3233
You can also use freenom dns management if you prefer.
3334

3435
[Freenom]: https://www.freenom.com
36+
[DuckDNS]: https://www.duckdns.org/
3537
[Cloudflare]: https://www.cloudflare.com
3638
[migrated]: https://github.com/matrix-org/synapse/issues/1209
3739

3840
## Get a free server
3941

40-
Comparison of free cloud offerings (2019/10):
42+
Comparison of free cloud offerings (2021/09):
4143

4244
| Vendor | Time-limit | Count | RAM (GB) | Storage (GB) | Transfer (GB) |
43-
| -------- | ---------- | ------------------------ | -------: | -----------: | ------------: |
44-
| [AWS] | 12 months | 1 t2.micro | 1 | 30 | 15 |
45-
| [Azure] | 12 months | 1 B1S | 1 | 2x 64 | 15 |
46-
| [GCP] | no limit | 1 f1-micro | 0.6 | 30 | 1 |
47-
| [Oracle] | no limit | 2 VM.Standard.E2.1.Micro | 1 | 100 | 10000 |
45+
| -------- | ---------- | ----------------------- | -------: | -----------: | ------------: |
46+
| [AWS] | 12 months | 1 t2.micro | 1 | 30 | 15 |
47+
| [Azure] | 12 months | 1 B1S | 1 | 2x 64 | 15 |
48+
| [GCP] | no limit | 1 e2-micro | 1 | 30 | 1 |
49+
| [Oracle] | no limit | 1-4 VM.Standard.A1.Flex | 24 | 200 | 10000 |
4850

4951
[AWS]: https://aws.amazon.com/free/
5052
[Azure]: https://azure.microsoft.com/en-us/free/
@@ -54,9 +56,9 @@ Comparison of free cloud offerings (2019/10):
5456
If you choose to, register on Oracle Cloud (requires credit card for
5557
verification) and create a free VM:
5658

57-
1. Create a VM instance
59+
1. Create a VM.Standard.A1.Flex VM instance
5860
2. Give it a name
59-
3. OS/image: Canonical Ubuntu 18.04 Minimal
61+
3. OS/image: Canonical Ubuntu 20.04
6062
4. Show Shape, Network and Storage Options -> Assign a public IP address
6163
5. Add SSH key ([generate one][sshkey] using `ssh-keygen` if you don't have one)
6264
6. Show advanced options. I removed monitoring, since I'll remove the monitoring
@@ -113,18 +115,6 @@ snap remove oracle-cloud-agent
113115
apt purge snapd open-iscsi lxd lxcfs
114116
```
115117

116-
## Tune server (optional)
117-
118-
I suggest enabling swap, since there's only 1 GB of RAM.
119-
120-
```shell
121-
dd if=/dev/zero of=/swap bs=1M count=1k
122-
chmod 0600 /swap
123-
mkswap /swap
124-
swapon /swap
125-
echo '/swap none swap sw 0 0' >> /etc/fstab
126-
```
127-
128118
## Point domain at server
129119

130120
Assuming you're using a new domain only for this you need the following DNS
@@ -143,14 +133,17 @@ Follow the [guide], with some tweaks:
143133

144134
### Guide in a nutshell, TL;DR
145135

136+
If you are too busy to read the guide, here are the most important steps:
137+
146138
```shell
147139
git clone https://github.com/spantaleev/matrix-docker-ansible-deploy/
148140
cd matrix-docker-ansible-deploy
149141
mkdir inventory/host_vars/matrix.$domain
150-
cp examples/host-vars.yml inventory/host_vars/matrix.$domain/vars.yaml
142+
cp examples/vars.yml inventory/host_vars/matrix.$domain/vars.yml
151143
cp examples/hosts inventory/hosts
152144
$EDITOR inventory/hosts
153-
$EDITOR inventory/host_vars/matrix.$domain/vars.yaml
145+
# put most settings here in vars.yml, read following sections for some ideas
146+
$EDITOR inventory/host_vars/matrix.$domain/vars.yml
154147
# you'll need to rerun setup-all and start tags again if you edit vars later
155148
ansible-playbook -i inventory/hosts setup.yml --tags=setup-all,start
156149
ansible-playbook -i inventory/hosts setup.yml --tags=self-check
@@ -163,30 +156,12 @@ ansible-playbook -i inventory/hosts setup.yml -e username=$user -e password=$pas
163156
matrix_nginx_proxy_base_domain_serving_enabled: true
164157
```
165158

166-
### Disable all extras because of RAM
167-
168-
```yaml
169-
matrix_mxisd_enabled: false
170-
matrix_mailer_enabled: false
171-
matrix_coturn_enabled: true # disable to save more RAM
172-
```
173-
174159
### Configure the public IP address for coturn
175160

176161
```yaml
177162
matrix_coturn_turn_external_ip_address: $instance_external_ip_address
178163
```
179164

180-
### Limit rooms because of limited RAM
181-
182-
```yaml
183-
matrix_synapse_configuration_extension_yaml: |
184-
limit_remote_rooms:
185-
enabled: true
186-
complexity: 1.0 # this limits joining complex (~large) rooms, can be
187-
# increased, but larger values can require more RAM
188-
```
189-
190165
## Done!
191166

192167
Point your browser to https://element.$domain or use [another
@@ -210,4 +185,5 @@ but really, take a brief look at all the documentation.
210185
Come join [#synapse:matrix.org](https://matrix.to/#/#synapse:matrix.org) to
211186
discuss homeservers. Or say hi to
212187
[@ptman:ptman.name](https://matrix.to/#/@ptman:ptman.name), who wrote this
213-
guide.
188+
guide (also <a
189+

0 commit comments

Comments
 (0)