Râu Cao raucao
  • Joined on 2018-11-24
raucao commented on pull request kosmos/chef#163 2020-05-14 11:02:27 +00:00
Add recipe to set up PostgreSQL replication, rewrite kosmos-postgresql cookbook

Left a couple of comments/questions.

raucao commented on pull request kosmos/chef#163 2020-05-14 11:02:27 +00:00
Add recipe to set up PostgreSQL replication, rewrite kosmos-postgresql cookbook

I don't see where that's done in this PR?

raucao commented on pull request kosmos/chef#163 2020-05-14 11:02:27 +00:00
Add recipe to set up PostgreSQL replication, rewrite kosmos-postgresql cookbook

What does this mean? Why would they use a different port to connect to Postgres?

raucao commented on issue kosmos/chef#160 2020-05-14 09:27:51 +00:00
Set up Postgres replication

I'm not sure I follow. The point of verifying a hostname, is that it can change. That's the problem with DNS.

Thus, the question is still open: why would we have to verify the cert on the client in this scenario? It is a simple local config. And it is only there to encrypt the connection, so that someone outside of our machines cannot record unencrypted traffic, when it's flowing through a public network. Nothing else.

So the options for this use case are:

  1. Use a private network
  2. Encrypt the connection on a public network

The easiest way to achieve number 2 is with simple shared certificates that we ourselves configure on the machines.

raucao commented on issue kosmos/chef#160 2020-05-14 07:43:49 +00:00
Set up Postgres replication

... also, aside from not needing a hostname, why would we have to verify the cert on every connection? Someone who could replace the IP could also replace the local cert used.

raucao commented on issue kosmos/chef#160 2020-05-14 07:41:23 +00:00
Set up Postgres replication

it fails verifying the hostname

What hostname? Why would we use hostnames?

raucao commented on issue kosmos/chef#160 2020-05-13 17:49:48 +00:00
Set up Postgres replication

Sounds to me like this is all much more complicated than just setting up a private network to be honest.

But in any case, does that mean ejabberd comes with its own CA list/store, or why would it ignore a Kosmos CA cert from the system store (like when you just use update-ca-certificates e.g.)?

raucao commented on issue kosmos/chef#160 2020-05-12 10:22:49 +00:00
Set up Postgres replication

... also not mentioning short expiration dates and frequent renewals, of course. None of that is necessary with a connection between private servers, where the only point is to encrypt the connection between the particular, internal machines.

raucao commented on issue kosmos/chef#160 2020-05-12 10:15:44 +00:00
Set up Postgres replication

TLS with Let's Encrypt is easier to set up than a self signed cert on all machines. In my experience generating self-signed certs in a pain in the ass.

How is LE easier than running literally a single command on any POSIX system with OpenSSL installed? Storing it in a data bag is as easy.

If the primary PostgreSQL server is for example andromeda.kosmos.org with TLS, changing it to another server in the client configs is the same amount of work as changing an IP (changing the FQDN)

That completely disregards my criticism of using DNS here. And if you change the entire hostname, then it's obviously more work on both ends than simply changing the IP only.

raucao commented on issue kosmos/chef#160 2020-05-12 09:15:54 +00:00
Set up Postgres replication

There is an open PR now, and the question why we need DNS and LE is still left unanswered by it. I think a normal custom cert, based on a Kosmos root cert that all machines can use, would have been much easier to begin with, but also that it makes more sense overall.

With DNS, we have to change hostnames instead of IPs, which requires waiting for the cache to update. And LE isn't required at all when there are no public clients using DNS. A simple X509 cert, based on a shared Kosmos root CA, would suffice.

raucao commented on pull request kosmos/chef#163 2020-05-12 09:12:41 +00:00
Add recipe to set up PostgreSQL replication, rewrite kosmos-postgresql cookbook

I glanced over everything and added a few comments to the mentioned README.

raucao commented on pull request kosmos/chef#163 2020-05-12 09:12:41 +00:00
Add recipe to set up PostgreSQL replication, rewrite kosmos-postgresql cookbook

What's "custom" about these servers? If "custom" merely means that it's going to be configured for our use case, then isn't that the case for literally every other server, too?

raucao commented on pull request kosmos/chef#163 2020-05-12 09:12:41 +00:00
Add recipe to set up PostgreSQL replication, rewrite kosmos-postgresql cookbook

The replica also needs to have "primary" as role?

raucao commented on pull request kosmos/chef#163 2020-05-12 09:12:41 +00:00
Add recipe to set up PostgreSQL replication, rewrite kosmos-postgresql cookbook

Which rules are needed? How are they declared? I believe this README would not answer these questions for someone trying to use it.

raucao commented on issue kosmos/chef#160 2020-05-11 09:53:52 +00:00
Set up Postgres replication

I didn't ask why we need TLS, but why we would need DNS and Let's Encrypt. It seems like you're proposing to use both in addition to TLS.

raucao opened issue kosmos/wormhole#1 2020-05-08 12:19:57 +00:00
Re-connect on XMPP disconnects
raucao commented on issue kosmos/chef#160 2020-05-07 09:03:58 +00:00
Set up Postgres replication

Why would we need Let's Encrypt tho? We don't want any public clients to access it.

raucao commented on issue kosmos/chef#148 2020-05-07 08:08:10 +00:00
Investigate Jitsi Meet and alternatives

Just found out it's possible to set up normal XMPP auth for Jitsi Meet room creation after all:

https://www.howtoforge.com/how-to-install-jitsi-meet-video-conferencing-solution-on-debian-10/#set-up-user-authentication-for-jitsi-meet

raucao created pull request kosmos/chef#162 2020-05-02 12:41:27 +00:00
Configure TURN properly