Serendipity Databases for multi-users

Random stuff about serendipity. Discussion, Questions, Paraphernalia.
Post Reply
jimmyboy
Regular
Posts: 6
Joined: Thu Oct 26, 2006 4:22 am

Serendipity Databases for multi-users

Post by jimmyboy »

One question, you mentioned when sharing an installation of Serendipity, the setup of DBs.

How is it, each user requires a unique DB? Is it not possible to have a single DB, with a variety of tables, so each user's content is unique because of their ID!

Pre-requisite of each individual DB multi-plicitly complicates administration, and basically kills any dynamic admin plausibility.

If you required users to dynamically create their blogs, the DB would have to exist. As for dynamic creation of the USER credentials during Serendipity installation, the documentation gives no indication of what parameters we can make use of for this purpose.

It leaves the site administrator with a lot of egg on their face.

Can true dynamicism be achieved with Serendipity, because there are a few system call to be made, like "mkdir" for new user; execute SQL to create new user DB; set permissions for new user; and link / cp the relevant shared files;

Serendipity documentation does not help much along these lines. But if you can point me in the right direction, I could maybe write PHP utilities and incorporate them into the Serendipity setup, and hey-presto.

Can you comment on this please.
Jimboy
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: Serendipity Databases for multi-users

Post by garvinhicking »

Hi Jimmiboy!

Finall you made it here. *gg*
How is it, each user requires a
unique DB? Is it not possible to have a single DB, with a variety of tables, so each user's content is unique because of their ID!
Actually the shared installation does not really require unique DBs, it just requires unique Prefixes. If you put each s9y installation into a seperate Database, that'S fine - but it'S also fine if you put all in the same DB, and prefix every s9y installation differently (like s9y1_, s9y2_ and so on).
Pre-requisite of each individual DB multi-plicitly complicates administration, and basically kills any dynamic admin plausibility.
Not if the shared installation script you create keeps track of Prefixes/DB names, so that you can run administrative actions on every of those. Jannis did that for supersized.org - he can execute a SQL query that is iterated on every DB/prefix.
If you required users to dynamically create their blogs, the DB would have to exist. As for dynamic creation of the USER credentials during Serendipity installation, the documentation gives no indication of what parameters we can make use of for this purpose.
Do you mean which SQL privileges a s9y user needs?

It requires at least those: SELECT, INSERT, UPDATE, DELETE, CREATE, ALTER, INDEX
Can true dynamicism be achieved with Serendipity, because there are a few system call to be made, like "mkdir" for new user; execute SQL to create new user DB; set permissions for new user; and link / cp the relevant shared files;
We strongly believe in specific server setups where it is hard to make Serendipity build "shared installation sites" globally, thus we do not supply any global scripts to do that, and just point people into creating their own setup scripts. Usually that's only 10 lines of code or so, and those are usually very specific to your server. We admit that shared installation is only for users who know some PHP and Apache.

Having said this, we had a user that has tried to create some PERL and BASH scripts to aid in the process:

http://php-blog.cvs.sourceforge.net/php ... ins/setup/

You can create a simple PHP script that simply sets the required Serendipity variables, and then make your script include the 'include/admin/installer.inc.php' s9y file, which will then take care of the installation procedure just as if a user installed s9y on his own. Of course you can use a wrapper script that makes the output of this s9y file invisible to the user signing up on your page.

But, to answer your question: Yes, true dynamic creation of shared s9y blogs can be achieved. supersized.org and other services do it fully automatted.
Serendipity documentation does not help much along these lines. But if you can point me in the right direction, I could maybe write PHP utilities and incorporate them into the Serendipity setup, and hey-presto.
If you see a way to make such a script work on common systems (mod_php, PHP CGI, with/without VirtualHosts etc.), we would be very glad for any contribution! I fully agree that help in this area is still needed. :-)

Best regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Arnold Nijboer
Regular
Posts: 42
Joined: Mon Oct 23, 2006 7:48 pm
Contact:

supersized.org

Post by Arnold Nijboer »

ey garvin, you say that supersized.org is fully autonome isn't it an idee to put those files online, or just line uit the basics how that system runs. to use it like an manual/template for development or something.

greating
Arnold Nijboer
judebert
Regular
Posts: 2478
Joined: Sat Oct 15, 2005 6:57 am
Location: Orlando, FL
Contact:

Post by judebert »

supersized.org is one of Jannis's projects. He'd have to be the one to decide whether or not to publish the scripts. And considering the amount of effort he's put into them and building that community, I wouldn't blame him if he refused.
Judebert
---
Website | Wishlist | PayPal
Arnold Nijboer
Regular
Posts: 42
Joined: Mon Oct 23, 2006 7:48 pm
Contact:

Post by Arnold Nijboer »

And considering the amount of effort he's put into them and building that community, I wouldn't blame him if he refused.
you're absolutly right, BUT.... it's an open source blogger right? and considering the ammount of users who are asking for it! I senserly hope he will put it online?!

Greatings
Arnold nijboer
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Post by garvinhicking »

Hi Arnold!

Open source is only Serendipity, supersized (what jannis created) is his own thing.

Just ask him, right? :-)

Best regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
clander
Regular
Posts: 8
Joined: Sat Mar 11, 2006 7:15 am
Location: Luton, Bedfordshire, UK
Contact:

Post by clander »

Hi Garvin,
garvinhicking wrote:Hi Arnold!

Open source is only Serendipity, supersized (what jannis created) is his own thing.
I've been bashing the keys recently at work (it's this mind numbing job shunting trailers into IBC Luton [Vauxhall Vivaro, Renault Traffic, etc.] as I'm a truck driver), and over the last six weeks I have almost completed a new version of S9Y_Conf in PHP!

You can see a preview at <www.labbs.com/~clander/s9y_conf/php/>.

This is still a work in progress as I have some additional tasks before I'll be happy to make a release, but any feedback from the 'Gurus of Serendipity' may be helpful.

Any clues Jannis? :)

Best regards
Chris Lander <http://www.labbs.com/>
Post Reply