Proposal: drupal.org testsite install profile

We encourage users to post events happening in the community to the community events group on https://www.drupal.org.
You are viewing a wiki page. You are welcome to join the group and then edit it. Be bold!

this is an idea i've been thinking about. posting it here so other folks can add to it, provide feedback, etc.

Summary

we could really use an install profile that setup a test site similarly to how drupal.org is configured (especially the project* modules and CVS integration). obviously, it wouldn't have the bluebeach theme, but otherwise, it would look fairly similar to d.o in terms of structure, content, permissions, etc.

this would greatly help people who wanted to reproduce bugs and test patches for the project* family of modules, which is something we desperately need more of. it also might be a popular profile as a starting point for people looking to setup software-collaboration sites (though ideally we'd have a separate "software development site" profile eventually).

here's what i envision (but please edit this to expand or modify it):

  • enables and configures all the project* modules and the CVS repo stuff
  • sets up the d.o project taxonomy stuff (project types, module categories, etc)
  • enables and configures the devel.module
  • configures the d.o roles and permissions
  • generates a bunch of random users
  • generates a few targetted users for each of the main roles on d.o, with documented usernames and initial passwords
  • generates a skeleton set of project nodes (core, some of the common contribs, cross-section of different project types (modules, themes, translations, etc))
  • generates a bunch of random releases
  • generates a bunch of random issues
  • (optionally) generates some random forums and comments
  • ...

so, you download all the right versions of things, install this profile, and you're ready to start testing patches for the d.o infrastructure.

in his "State of Drupal" talk, Dries was making a plea for more people to help with making our home on d.o more like a palace. this should significantly facilitate getting more "builders" involved in the construction. ;)

Details

specific modules

see http://drupal.org/node/27367 to start with. ;) otherwise, contribs i'm specifically interested in, are:
* cvslog
* project (including project_release)
* project_issue
* code filter

taxonomy

The project taxonomy stuff is a little weird. you get the basic idea: there's a "project" vocabulary, which is hierarchical. top level terms are "Module", "Theme", "Installation profile", etc, etc. At this point, only Module has sub-terms, which are the module categories (see http://drupal.org/project/Modules for a list of them). Once http://drupal.org/node/105986 is done, and contrib translations are in their own projects, we'll have sub-terms for each language under the "Translations" term, but that's getting ahead of myself. ;)

There's also the project release vocabulary -- "Drupal Core compatibility" (for the "5.x", "4.7.x", etc terms on release nodes, which is also used in a bunch of the download pages, etc).

I see 2 possible solutions for this:

  1. you just manually re-create a subset of this structure (not every single module category, etc)
  2. we actually export the relevent records from the {term_*} tables directly (and regularly) from d.o. not sure this idea will fly, but perhaps we could have a cron job that just does a selective mysqldump and sticks the .mysql file somewhere folks can just download. ;) i'm *only* talking about the structure of the project (and project release) vocabularies, nothing more.

cvs repository

ideally, the install profile would include a tarball of a pre-configured cvs repository that had the right basic directory structure, and some files for the project nodes that would get created with the profile. all the contributions/modules/cvslog/xcvs* stuff would be configured in the CVSROOT of this repo, and would be customized during install to point to the right drupal database. there's a pretty thorough README.txt in there now. we'd probably want to create 2 repos, in fact -- the contrib and core ones.
then, of course, the drupal site would be configured to know about each repo (via [site]/admin/project/cvs-repositories).

specific nodes

i don't think it's feasable or desireable to actually replicate all of the project, issue, and follow-up content from d.o. i was thinking we'djust creating a small handful (~10) different projects that are representative of the structure on d.o. these would be the same small handful of directories in the stub CVS repository. they'd have some specific CVS tags and branches, too, and the corresponding release nodes. once that's in place, i'd say we just randomly generate a bunch of issues and comments automatically.

roles and permissions

i'm not sure how much of this i can share, nor how much of it is really necessary for the needs of this profile. basically, we should just configure the anonymous and authenticated users with the appropriate perms, and then make an uber-site-admin role with all perms enabled. the whole "document maintainer" vs. "site maintainer" vs. "site admin" stuff probably isn't essential -- though it might be nice to tackle in a future version once the other parts are working smoothly.

other settings

i'm not sure what's the best way to deal with this: if i should (can?) just provide a dump of the relevent entries in the {variables} table, like i'm proposing for the {term_*} stuff. i'll try to get some of the more senior powers that be to comment on this part, too.

Related Links

Instructions on setting up and configuring cvs/project* are here. There is also a correspnding demo site which anyone can create an account at and play around with the stuff we're working on.

Comments

+1 -- seems like a good

merlinofchaos's picture

+1 -- seems like a good idea.

Sadly can't volunteer.

good idea!

joshk's picture

I need a focal point for learning install profiles. Let's talk about how to get started on this!

http://www.chapterthreellc.com | http://www.outlandishjosh.com

Start time frame?

simplymenotu's picture

I'm with joshk on this.

-s

Have some computing power available

figaro's picture

I am really keen on learning about this. I can only run scripts as opposed to develop them and I have a few idle FreeBSD machines and quite prepared to put them to good use. As far as I am concerned the next step would be to develop a platform where registered users could submit their own tests and pick up the results some time later, so a test would consist of a Drupal configuration (core + modules + data + patch) and a browser script.

Can we keep this thread as a reference to the install script or do we create a repository in groups.drupal for this? For instance http://drupal.org/project/drupalorg_testing

how to get started: start. ;)

dww's picture

i already sketched out most of what this would take to be useful. so, here's how to get started:

0) read the docs on how to write install profiles
1) start. ;)
2) get something done
3) commit it as a new install profile project on d.o
4) keep working on the stuff i outlined above.
5) commit the next part
6) repeat steps #4 and #5 until you're done
7) finish

not sure what more coordination we need. josh k, it seems like you're volunteering yourself to lead the charge. lovely. simplymenotu, if you want to help, just find josh in IRC or his contact tab or whatever, to make sure you don't duplicate effort.

there's really not much to it, i just don't personally have time to do it all myself, and i'm trying to be better about facilitating other people working on project* (which takes a little more short term effort than just doing it myself, but widens the pool of folks who can work on it in the long term).

thanks,
-derek

i'd like to work on this as

drewish's picture

i'd like to work on this as well. have you gotten started yet? feel free to pm me

Another alternative

BioALIEN's picture

Derek, while this sounds good, I think the best way to go about this (given the problem you're trying to address) is by distributing a package as a virtual machine rather than a profile. Of course, of direct relevance would be this SoC proposal: http://groups.drupal.org/node/3299


BioALIEN
Buy, sell and trade with other webmasters: WebMasterTrader.com

profile handles evolution of code, virtual machines do not

dww's picture

the reason i like an install profile for this is that as core and the contribs evolve, the install profile can still work, and generate the right test site with little or not maintainence work. plus, anyone with drupal 5.x can help, they don't need VM-specific software.

if you do it as a virtual machine, you have to a) completely rebuild the virtual machine image anytime you change any code and b) only people who have the right VM client software can help.

VM + install script

Boris Mann's picture

And, really, you can make the VM and then run a post install script that, say, pulls the latest tagged release of the profile from Drupal CVS :P

scripting from CVS

discursives's picture

can i have a small hint on what that script might look like if it were to, say, take an input for the release, or the latest release? I have been trying to figure out how to get the latest release but it seems to be a manual operation, and not friendly for mass instances.

I suppose, in this case you are mostly talking about HEAD, in which case the script text doesn't need to change.

http://peerproducers.com - Peer Production Praxis

off topic

dww's picture

this is sort of getting off topic, but i think you're asking about how to write a script that gets the latest official releases of modules directly from CVS, right? if so, you must read this:

http://drupal.org/node/124661#comment-211008

otherwise, maybe you're talking about how to get the profile packaging script to include core and all the necessary contribs in the downloadable packages for profiles, which is an entirely other discussion. for now, the profiles just include the profile-specific code, and users still have to download everything else separately.

if you're talking about neither of those things, please clarify what you mean (and how it relates to this post about an install profile for drupal.org testing).

thanks,
-derek

Pardon my ignorance here but ....

TexasNomad's picture

What are you trying to create?

A software dev system for drupal with all the modules needed for such a task?

So that one could install this profile and now they have a collab site ready to go?

Help me out here gang,

Thanks

i think the post is pretty clear

dww's picture

just read the post (again). i thought i was clear enough:

"we could really use an install profile that setup a test site similarly to how drupal.org is configured (especially the project* modules and CVS integration). obviously, it wouldn't have the bluebeach theme, but otherwise, it would look fairly similar to d.o in terms of structure, content, permissions, etc.
...
this would greatly help people who wanted to reproduce bugs and test patches for the project* family of modules, which is something we desperately need more of.
...
so, you download all the right versions of things, install this profile, and you're ready to start testing patches for the d.o infrastructure."

what part of that is ambiguous?

TexasNomad's picture

This is commonly needed? I would think that the devs of the project* modules would have this. Sorry for being so dense.

I think....

Tresler's picture

I think I get what TexasNomad is asking. dww made a rather poignant, impassioned plea for help on the project* family of modules at OSCMS, and Dries definitely, backed him up there; although all that might not be apparent to someone not at OSCMS.

A project like this would make it A LOT easier for people who aren't dev's of the project* family of modules be able to set up a test environment for them to help test patches and take some of the strain off the project dev's.

Drupal.org is HIGHLY dependent upon this family of modules and ANY help would be highly appreciated. This is an effort to make it easy for people who aren't dev's to help, but requires the initial effort to make an install profile and maintain it; ideally this initial effort would be paid back many fold by people not needing to "go find out" all that is required to properly test project* patches.

Its not something that the dev's would 'just have' as most of them can CVS a fresh copy and reload a DB in seconds, but for new users that are just testing patches a tool like this would be a great way to 'jump in'

Does that clarify things?


Tresler Designs

exactly

dww's picture

Tresler nailed it perfectly here.

The only thing i'd add is that even devs like me sometimes need to manually go through the steps i outlined above when setting up a new test site for project* development. so, it'd save me time, too. ;) you can't always just start from a DB dump, since sometimes what you need to test is in hook_install(), for example.

all done

drewish's picture

i made a copy of the development profile, committed it to CVS and created a project node: http://drupal.org/project/drupalorg_testing

now i'm waiting on dww for d.o info. the list goes something like:

  • a list of installed modules
  • roles
  • permissions
  • a big chunk of the variables table?
  • taxonomy vocabularies, terms, and the nodes they're on

updated the wiki with details

dww's picture

see the new Details section. that should be enough to keep you busy for a while. ;)
i'll solicit feedback from other senior infrastructure folks to see how much of this they're comfortable with.
thanks!
-derek

Ideal hosts for testing this setup?

mikey_p's picture

What's an ideal hosting provider for using this setup, ideally one would want one that allows CVS and pserver to be run, correct? My current hosting solution allows the former, but not the latter, which I believe will cause be some troubles in testing this setup. Or could the cvslog module be configured to use cvs.drupal.org from a third party site successfully?

I'm very interested in running the whole project* family with cvslog and possibly even packaging scripts and such on one of my sites, and I'd love to be able to add features and test properly, but I don't know of a good cvs solution, short of getting a separate CVS host ($$$).

-Mikey P

don't worry about cvs

dww's picture
  1. most of what needs to be tested isn't the CVS repo itself
  2. the profile will (hopefully) include a tarball of a pre-configured CVS repository that you install on your local filesystem. this repo will be configured during installation to point to the drupal DB, so pserver access isn't an issue as far as drupal is concerned.
  3. since the point is testing the drupal side of things, you don't really need to pretend this is a fully functional drupal clone where folks from all over the world will be accessing your copy of this dummy, test CVS repo. during testing, you can access this local repo using the filesystem, instead of pserver. this will be documented in the README for the profile.

so, don't worry about the cvs repo and dedicated CVS hosting options. so long as your site has the CVS CLI installed, it'll all work fine. even if it doesn't, there's still an awful lot that can be tested without the CVS repo integration at all.

cheers,
-derek

Test data versus real data for Drupal.org

Amazon's picture

There seems to be two communities of interest. One community is interested in having data to test the software that runs Drupal.org. There is a second community, not represented in this thread, which is interested in the content of Drupal.org and how to build software to work on the Drupal communities content.

For the first community I suggest we extend developer module's generate scripts.

<

ol><a href='http://cvs.drupal.org/viewcvs/drupal/contributions/modules/devel/generate/?only_with_tag=DRUPAL-4-7">Existing scripts

  • There are generator scripts to create users already for a specific domains. e.g. create 200, 000 users at mytestingdomain.com
  • Generate forum posts and comment scripts are available now
    1. New scripts needed
    2. Generate scripts for project types, module categories, project nodes, project releases, project issues

    I assume that a combination of system, variable, access, role table dumps could lead to Drupal.org project modules being configured by default.

    The second community is interested in developing software to make better use of Drupal.org content. These are the people who want to re-arrange blocks, re-categorized the handbooks, change module categories, re-organize the forums etc. They want to count and measure search terms, posting rates, internal reference links etc. These people want a raw data dump of Drupal.org that has been scrubbed for privacy issues. This data would be useful to social scientists, information architects, usability professionals, and user experience designers.

    To seek, to strive, to find, and not to yield

    New Drupal career! Drupal profile builders.
    Try pre-configured and updatable profiles on CivicSpaceOnDemand

    I must be missing something

    WorldFallz's picture

    I must be missing something somewhere. I frequently blow away and restore my dev environment. All I use is a tarball of my entire drupal site and an sqldump of my database. It takes me all of a few minutes to create a fresh site.

    Instead of maintaining an install profile, the dev team could just periodically post updated tarball and slqdump files somewhere.

    Also, I recently came across server2go (self contained WAMP stack) and configured it to run my drupal dev site from a flash key. I haven't tried it yet, but now there should be no reason a completely new dev env can't be as simple as 1 tarball for WAMP. Unfortunately, there's no linux version but a lot of the people you're targetting probably have WAMP at home anyway.

    That would make creating a new d.o. test env as simple as 1 tarball for WAMP users and 1 tarball + sqldump for LAMP users.

    But even without the wamp/lamp split it just seems easier to do it this way-- or am I missing something stupid simple that would prevent this?

    dww's picture

    A) see my comment above profile handles evolution of code, virtual machines do not

    B) As I pointed out in exactly above, "you can't always just start from a DB dump, since sometimes what you need to test is in hook_install(), for example.".

    C) An install profile is database independent, while an SQL dump is not. Having this profile has enabled us to work on PostgreSQL compatibility bugs, etc.

    D) There are already efforts at automating the entire setup of the software stack and all the drupal code, and then installing this profile. See the DAST project for more.

    ...