Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/spilo fixes #164

Merged
merged 13 commits into from
Jan 21, 2016
Merged

Conversation

feikesteenbergen
Copy link
Contributor

No description provided.

Reusing an EBS-snapshot didn't work correctly due to the erasing of
the data volume. With this commit, you can build a Spilo
out of a snapshot.
@hjacobs
Copy link
Contributor

hjacobs commented Jan 14, 2016

@feikesteenbergen could you tackle the decreasing code coverage please?

…tration and ELB's.

Having only one security group for all Spilo's in one account doesn't quite cut it.
We need to be able to distinguish which databases are allowed to be accessed by which application.
We also need to be able to restrict access to Patroni, replica's or masters.

As pg_hba.conf is of limited use (it only reports the ELB address), we need Security Groups to shield
access away from the Spilo.

This change creates the following Security Groups:

- Member: Internode communication and Bastion Host communication is allowed on all ports. Connections from the ELB's
  is allowed.
- Master: Connection from a cidrblock is allowed (default: vpc)
- Replica: Connection from a cidrblock is allowed (default: vpc)

In this way we reduce the chance of exposure when running public facing Spilo's.
To increase security, allow access to directories only in S3. When running multiple Spilo's in one
account it is now impossible to delete or update the wrong directory.
Resource:
- arn:aws:s3:::{{wal_s3_bucket}}/spilo/*
- arn:aws:s3:::{{wal_s3_bucket}}
- "arn:aws:s3:::zalando-acid-eu-west-1-spilo-app/spilo/{{Arguments.version}}/*"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be {{wal_s3_bucket}}

Changed the tedious formatting of placeholders for senza create into their own variables.
This makes the template much more readable.

Attach the {{version}} placeholder to many resources to ease identification.
We rely on convention to find out the security group of the Odd host. With this patch we only
add rules for the Odd Host if we can find it and if the user confirms it.
@feikesteenbergen
Copy link
Contributor Author

Closing (temporarily)

@alexeyklyukin
Copy link
Contributor

+1

@hjacobs
Copy link
Contributor

hjacobs commented Jan 21, 2016

👍

hjacobs added a commit that referenced this pull request Jan 21, 2016
@hjacobs hjacobs merged commit 5666fef into zalando-stups:master Jan 21, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants