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

Already on GitHub? Sign in to your account

Install phpMyAdmin #57

Open
patcon opened this Issue Sep 25, 2012 · 10 comments

Comments

Projects
None yet
4 participants
Contributor

patcon commented Sep 25, 2012

Further lowering the barrier for a single setup for anyone: sylus/wet-boew-drupal-devops#7

Ok, were are the docs to do this (in Chef I expect)?

I'm guessing it's a matter of copying:
wet-boew-drupal-devops/cookbooks/drupal-cookbooks/phpmyadmin/
metadata.rb recipes templates

And putting it in:
ariadne/cookbooks/mysql/recipes/
client.rb default.rb server.rb server_ec2.rb

Then re-installing it, but not sure.

Contributor

patcon commented Sep 26, 2012

actually, if you're interested, i kinda have my own layout for sanity (so it's easier to see where we diverge and override the official things)

  • cookbooks/ is the directory built from the Cheffile manifest
  • cookbooks-overrides is for new cookboks, but also for drop-in replacement or improvements which sensibly seem to fit with existing cookbooks. Chef kinda takes this directory and superimposes it over cookbooks/ (since we told it to in the Vagrantfile.
  • cookbooks-projects is another level that works similarly, but it's cookbooks for the last big of configuration on any project. It just gets it's own folder since we tell git to ignore everything here (so we don't accidentally commit client-specific cookbooks). If we set a project to "secretproject" in config/config.yml, then ariadne will add cookbooks-projects/secretproject as the last cookbook/recipe for VM configuration.

But long story short, we could either create a new cookbooks-overrides/phpmyadmin cookbook with a dependency on the mysql cookbook, or superimpose a new mysql recipe in cookbooks-overrides/mysql/recipes/phpmyadmin, or even create a new cookbook repo on github and add it to Cheffile so that it gets built right into cookbooks/.

I'm actually inclined to do the later, and then other people outside this project can start using it and contributing :)

Contributor

patcon commented Sep 26, 2012

Oh and, lastly, wherever we put it, we call it from a role in roles/, likely in dev_tools. To top level ariadne role eventually calls every role in there. I'm just keeping them separate so that later on, we'll be able to let people specify their own stack in the config file (ie. leaving out varnish role when they don't want it)

Contributor

patcon commented Sep 26, 2012

Now that I look into it, we should probably help @agiley build out his phpmyadmin cookbook, and use that :)
https://github.com/Agiley/chef-phpmyadmin

Just don't use 3.5.2.2 all languages. http://arstechnica.com/security/2012/09/questions-abound-as-malicious-phpmyadmin-backdoor-found-on-sourceforge-site/ Pretty limited in scope, but still, oops.

Trying to decide if I want to add some code to facilitate passwordless logging in and/or .htpassword protection because that's really not something you want people used to being able to access easily.

In Vagrant it would be great to have it be passwordless. However, if it's migrated over to the Internet it would be a real security risk. Is there a way to check if it is going into a Vagrant virtual box?

Contributor

patcon commented Sep 26, 2012

Thanks @fluxsauce :)

And yep @mgifford, that's totally doable -- most conveniently that logic goes into the json array in the Vagrantfile:
https://github.com/myplanetdigital/ariadne/blob/1.3.0/Vagrantfile#L94

Chef works by building up a description of the server in a big json array, and vagrsant merges in this json from the Vagrantfile, but it wouldn't be merged in when deploying to a real server (since we wouldn't be using vagrant for that). So anything added in the Vagrantfile is an override or flag exclusively for use in the vagrant box. Everything in the roles/recipes will be in both places.

@mgifford As for your question about bringing a cookbook into Ariadne (Agiley/chef-phpmyadmin#1), I need better docs. rake init_project is only a helper for bringing in a project-specific cookbook -- ones that are just for your setup and so shouldn't be in version-control. Since this is for the who ariadne project, we would bring it in by adding an entry to the Cheffile (which is like a package manager for cookbooks, and is used to generate the cookbooks/ directory):
https://github.com/myplanetdigital/ariadne/blob/1.3.0/Cheffile#L13

(Oh, and just a minor github etiquette thing, but we should probably try to keep ariadne-specific discussion out of @agiley's issue queue for his cookbook, so each issue is kept in its respective realm :)

All useful info, thanks! Hopefully this is all helping in the creation of docs for this project.

Contributor

patcon commented Sep 26, 2012

I'll def be referencing these convos when the time comes :)

skottler commented Oct 3, 2012

What do you think about making it optional? I know that when I evaluate different tools I immediately brush off systems that include phpmyadmin :P

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment