-
Notifications
You must be signed in to change notification settings - Fork 827
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
Sovereign 2 #667
Comments
On 17.03.2017 12:36, Alex Collins wrote:
As mentioned in a previous approach, I've come up with a way to evolve
Sovereign. I've put some ideas into a Wiki page:
https://github.com/alexec/sovereign/wiki/Sovereign-2
I'd be keen to see what people think? What problems do you encounter?
What do you like? What would you want to see?
If you have a large team that constantly and in a VERY fast pace tracks
security issues, maintaines, updates and rebuilds your local docker
packages,
this approach of using Docker might be fine.
Otherwise I'd consider it a security nightmare with a jungle of not
properly maintained docker images.
Build it straight from the Debian packages so that a simple "apt-get
update; apt-get upgrade" gives you the latest security fixes.
Cheers
Mike
|
Thanks. That's a really important comment about a critical issue. We don't want to sacrifice security. This isn't as straightforward in the Docker world as |
A simple fix is to make official Sovereign Docker images that are vetted for security. It could be a part of the Sovereign value proposition that these Docker images are locked-down. |
I really like this idea. How complicated is it to build your own docker images? |
Excellent work on all this! Here's my pie-in-the-sky wish list:
|
I think using Docker images will make it much harder as those images need an individual update. Or in that case we are better of splitting sovereign into individual services and each service is the one that builds the docker image. |
This was what prevented me from using sovereign, since it has many interdependent parts (and also because it had many services I don't need, and I wanted to learn ansible/ configuration management in general). I'm still following development here as I consider it high quality work and the commit log is very instructive; feel free to borrow ideas from my (personal, wouldn't yet recommend for production use) ansible based self-hosting solution at https://github.com/nodiscc/srv01 - it is not as feature complete as sovereign but I think it solves the modularity problem (roles are sometimes interconnected but it takes advantage of ansible's tagging system). Criticism and bug reports are also welcome. I'm not very interested in Docker based containerization but I'd like to learn/work on seccomp/LXC/... based sandboxing in the future. Best of luck with future work on sovereign |
@nodiscc Your self-hosting solution at https://github.com/nodiscc/srv01 is very intresting, thanks for sharing the link. I'am working on something compareable see https://github.com/return42/handsOn. handsOn was created for german users, the description is in german: http://return42.github.io/handsOn But I guess, with a little bash knowledge, reading the scripts https://github.com/return42/handsOn/tree/master/scripts and with a look at the templates https://github.com/return42/handsOn/tree/master/templates everyone will see how my setups are made. |
@return42 with all respect I would not use your project at all; and I don't think it can actually be used to improve sovereign. Sovereign's only indesirable characteristic is interdependence of roles. Regarding handsOn
This is just a list of few things you could improve (hint: you might be better off starting from scratch and using configuration management). Re. sovereign 2: I would definitely use something based on/similar to DebOps ansible playbooks, which can actually be run separately, but with an added layer that eases configuration/customization (which Sovereign is actually good at, and was a great inspiration for my work - single config file). A docker-container approach is the complete opposite of this, and as others have said, would be a security/maintenance nightmare. |
@nodiscc: As I wrote, handsOn is for german audience. It focus on productivity AND education, describing the setups in detail to give the audiance a chance to admin in a different context. It's far from what sovereign is (no plug&play character). I gave the link to show how my service-setups are / if someone is intrested e.g to see how to place this or that service behind an apache instance (your speach: "feel free to borrow ideas from my"). If there is nothing for you, leaf it. Anyway, thanks for your hints. Good point, I have to lint my scripts ;) ... BTW:
.. one reason for the hundreds of errors :o |
@return42 I understand; juste a note that if you use it for educational purposes - aside from a few ansible-specific tricks and basic config - I think ansible makes the whole setup much easier to understand than bash scripts - ie. you don't have to learn bash intricacies; along several other advantages. Not trying to detract from your work, it looks rather well done aside unavoidable problems when working with a large bash codebase, which ansible effectively abstracts away. @alexec I have re-read your writeup and I think it brings some good points, can you give some details on the following:
|
Ad owncloud/nextcloud: You need to set the permissions correctly after install and as far as I could tell right now sovereign is not doing that. Install documentations |
@cstich Here are the tasks I use to harden Owncloud file permissions: https://github.com/nodiscc/srv01/blob/master/roles/webapp-owncloud/tasks/owncloud.yml#L140. |
@nodiscc Oh nice. Thanks for pointing this out. |
@alexec Awesome that you consider going for nginx as well! 🎉 That would be another reason to reopen the issue with the answer to life the universe and everything. 😉 |
Sorry for a delay in replying, I wanted to take some time over my reply. First, a bit about me. I've worked with *nix development for 15 years, but I'm not an expert. I've worked extensively with Docker. I.e. I'm Docker strong, but *nix weak. My primary concerns are reliability, security, and privacy. Naturally, I'd like these at minimum cost. Everything I say is from my personal experience. It's great to see everyone so excited about this discussion.
I'd say it took me around 20 hours to set-up my server, including one prototype. Most of the time was spent reading and understanding both the documentation and code. Understanding what applications do what, and then making modifications to remove the ones I didn't want to reduce the attack surface. This felt like a long time when I just wanted to run an email server initially. I would expect pulling and starting Docker images to be quicker.
I've spent time fixing cron jobs and the ilk, e.g. so they work with recent versions of PHP or MySQL.
I'm very familiar with Ubuntu, and it's a popular and well supported, e.g. DigitalOcean's "One-click apps" all run on Ubuntu.
OwnCloud needs to be set-up after install. I don't know how this could be automated. I don't know much about this.
Some manual config, some config files. Some passwords in one place, some in another. Various hacking of files after install to get them working with Ubuntu.
Personally, I would have less confidence in its effectiveness than isolated containers.
This is quite the opposite of my experience with Docker. I've found time and again getting Docker running, especially using a container management tool, extremely quick and easy. I'm quite experienced with Docker, and if you're not experienced with it, I could imagine this would be a concern for you. Therefore, I won't dismiss this as an issue that would need to be addressed.
Absolutely, this impacts both security (via lack of isolation) and maintenance (coupling).
Apt-get update gets you the latest security fixes, but it would be magical thinking to believe this gives you a secure system. You'll still have many un-patched bugs and vulnerabilities, and this is more likely the more packages you install. Sovereign can install (IMHO) a very large number of packages and programs. This is why isolation is so important. Quite a few people seemed concerned about getting good quality Docker images and keeping them up to date. The security and maintenance benefits of Docker are well documented, but they come at a price. That price includes having a build pipeline for you images, and having a container management solution, and requiring more powerful machines to run on. There's no such thing as a free lunch, and the question that needs to asked is -is the trade off worthwhile?
Sorry :( The intent of using Nginx would be TLS termination and level 7 routing. What concerns do people have about security and maintenance with Sovereign currently? Have you had an easier ride that I have? If so, why do you think that is? Do you have different skills and expertise? Different levels of experience? What are your goals and what do you want to get out of it? |
Just my 2 cents. Skills: Maintenance: OwnCloud: Configuration: Security: Goals: Contribution: |
I think making Sovereign easier to setup and to maintain has little to do with putting the individual services in containers. The biggest issue that we seem to have is that some things are broken and there aren't enough people fixing them (like Ubuntu 16.04 compatability). I'm one of those people who should fix more stuff 😊 Perhaps we should create some milestones and when we reach them we create releases. That way we have something to work towards and a sense of achievement. Right now it's just a never ending thing. |
Re: owncloud auto configuration: apparently being worked on in #669 |
A proof of concept of Docker compatibility would be interesting (eg. fork the repository, remove except everything the common and eg. apache roles, adapt them to a docker setup, setup automatic builds, work from there to try and merge it - as an optional feature? - to sovereign). This would also probably help in identifying unneeded coupling. Re: Multiple distribution compatibility: maybe adding compatible/targeted distributions to the README would help in clarifying this? And identifying things that don't work out of the box. I've found no mention of targeted distros. Re: complex/time-consuming configuration/installation: centralizing configuration in a single file (maybe a 2nd for advanced settings) and automating steps described in https://github.com/sovereign/sovereign#installation would probably help. Ansible Filter plugins [1] [2] could be used to generate hashes/etc. Re: general organization: have something to work towards and a sense of achievement. Right now it's just a never ending thing: Yep opening a new issue for each separate concern (eg those listed in https://github.com/alexec/sovereign/wiki/Sovereign-2) would be good. |
Re: concerns about security and maintenance with Sovereign: I don't understand quite well how it works. The accpeted method of running a trimmed down Sovereign is to remove components - I prefer it to be the other way around (start minimal, add components with minimum hassle, my approach to this). Configuration is confusing (my take on it) Re: expertise: I'm just a user with some experience in Linux system admin. My end goals are: deploying a server with just the services I need as quickly as possible, have it easily extensible/configurable, have sane defaults re. security/hardening/config, tend toward zero maintenance, and learn more about system administration. |
Overall I really like this system! Mainly, for me at least having installed this on several systems it would be awesome to make it more customizable - as mentioned above having containers. This way we could turn on a few things and not others. As for making this more user-accessible while working with one person they did find it difficult to generate all the hash values on their system. I think that's relevant as it requires more advanced skills and confidence. |
Does Docker work on low-cost VPS's? I didn't think it did and that would rule it out for a lot of people. That's one of the things that attracted me to Sovereign. I've also had problems running Docker on local hardware with limited resources as well. Really the Ansible scripting is the thing that sets Sovereign apart from other efforts. |
Hey all! Thanks for the great work in this repo! From my understanding of things, here's my 2 cents on this matter:
Note that N° 3 probably isn't production ready as of now (because Service Catalog and APBs haven't gone GA, yet), but one could start out with containerization of the different processes (e.g. like in N° 2, or done directly with Docker / rkt / OCI-containers) which is needed before running them on Kube anyway. If you want to fully leverage Ansible, I feel like N° 2 would be a good starting point! Cheers |
the docker approach is interesting because it help to integrate news applications. such as a good example where docker is preferable is when you come to upgrade from php5 to php7 Docker and ressources For the security perspective Apps perspective the proxy (Nginx) Let's Encrypt Why not turning DB outside of docker ? Next/Owncloud |
I concur with @TotallyInformation - Sovereign would loose its main advantage if it became Docker-exclusive. Right now breaking up Sovereign isn't hard (see my mailstack-only hardfork https://github.com/ubermail/ubermail), and can be perfectly containerized as it is i.e. with LXD. Dockerizing Sovereign would make it a real pain for low-cost as well as high-performance deployments as well as Sovereign customizations/forks. |
As mentioned in a previous approach, I've come up with a way to evolve Sovereign. I've put some ideas into a Wiki page:
https://github.com/alexec/sovereign/wiki/Sovereign-2
I'd be keen to see what people think? What problems do you encounter? What do you like? What would you want to see?
The text was updated successfully, but these errors were encountered: