Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

Archive /

Our old forums are still available as a read-only archive.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo

Deployment/Content Export?


Go to End


15 Posts   10386 Views

Avatar
phptek

Community Member, 15 Posts

26 March 2008 at 10:18am

Hi folks,

I am new to Silverstripe and according to cmsmatrix.org, Silverstripe is capable of static content export i.e. Query database for content --> "Cook" into .html files --> Export to target server(s) in the public internet. I'd really like to know if there's any documentation/knowledge regarding static content export.

I believe the script/module used to do this is called "publishsite" but there doesn't seem to be much information regarding how to use it, how to run it or exactly how it does it (rsync? FTP? etc). Is this something that is detailed in the docs when you download Silverstripe?

Thanks a lot.

Avatar
Willr

Forum Moderator, 5523 Posts

26 March 2008 at 10:53am

Sam has started a class called StaticExporter which exports the site into html files - http://doc.silverstripe.com/doku.php?id=staticexporter

Not too much documentation on it just yet but If you visit http://www.yoursite.com/StaticExporter/ and log in as an admin, it will let you download a .tar.gz with a complete static dump.

Avatar
Tim

Community Member, 201 Posts

26 March 2008 at 2:08pm

We are planning on extending the capabilities of the HTML export quite significantly in the next few months... stay tuned.

Avatar
phptek

Community Member, 15 Posts

26 March 2008 at 2:55pm

Hi guys and thanks for the replies. I checked out the /StaticExporter. This is quite crude but sort of does the job. What I'm really after and what you're probably working on now I'd wager is something like this:

* A specific CMS admin screen allows one to configure the username, host and target directory to statically deploy to using rsync. (Secure rsync will of course depend on the user having an SSH agent running in the background (Unix-like systems)).
* In the CMS view the "Save and Publish" button has a checkbox next to it labeled "deploy".
* Checking this box and pushing this button (Admin/editor users only) securely rsyncs static content to predetermined target server(s).

We currently use Zope/Plone to deploy to 3 public-facing webservers as Plone is dog slow and a bit of a resource-hogger (The CMS itself sits behind our LAN) but it's required a bit of Python hacking to get it to work as above. If this sort of functionality could be offered by Sliverstripe out of the box, you'd be blowing most of the other CMS's out of the water in terms of functionality.

A would-like-to-have would be switches (checkboxes) next to each listed target deployment server so that you can arbitrarily choose not to deploy to specific machines...

Thanks heaps guys.

Avatar
Tim

Community Member, 201 Posts

26 March 2008 at 6:21pm

Edited: 26/03/2008 6:23pm

What you have described above is at a high level what we are working towards. Our need is to support two sites which are going be serving several tens of millions of pages per day, and serving static HTML is the only feasible way to handle this sort of load.

All going well, you'll be able to plug it directly into a CDN for even greater performance if you need it.

Once it's been developed it will become part of the core product.

My condolences about being stuck on Plone... its performance is so bad it's near on criminal :P

Avatar
phptek

Community Member, 15 Posts

27 March 2008 at 9:04am

Cheers Tim,

When you say "Our need is to support two sites" what exactly do you mean?

1). The CMS itself and and a static HTML, exported version?
2). Two exported versions of the same website?
3). Two exported versions of 2 different websites?

If 2)., why stick to 2?, just allow any number of target servers to deploy to? Although I grant you I may have the wrong end of the stick..it's only just gone 9am...

Avatar
phptek

Community Member, 15 Posts

27 March 2008 at 9:06am

PS...what's the best way of keeping tabs on the development of this specific functionality?

Ta :-)

Avatar
Tim

Community Member, 201 Posts

27 March 2008 at 9:46am

Edited: 27/03/2008 9:47am

I'll make a point of updating this post when this functionality is ready. Reply to this post and select "subscribe to this topic" so you can follow this by email as well.

In relation to the "two sites", what I meant is we have two clients, each with their own site which needs this capability. This means that by the time we release it it will have been pretty well battle tested.

Go to Top