Jump to:

23477 Posts in 18941 Topics by 2878 members

General Questions

SilverStripe Forums » General Questions » Export import between sites

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 3123 Views
  • stevo
    Avatar
    Community Member
    2 Posts

    Export import between sites Link to this post

    I am a newbie to SilverStripe but have used other CMS systems in the past. I have taken over support of our Silverstripe system, as our previous admin left suddenly leaving little documentation, so I have had a steep learning curve. One thing that has frustrated me is how to get pages from our development site into our production site. It seems that the only way to do this is to do a MySql dump of the whole database from the development site and refresh that to the production site. But what if I want to do just one page and not all pages? It seems that there should be a page export/import facility in the Admin pages of Silverstripe but that does not exist (unless I am missing something).

    Also, how do you move pages from Test to Prod in an environment where you have no CLI access to the server, only ftp/sftp. This is the situation we may be faced with as we are considering changing our hosting providers.

    Thanks,

    Steve

  • Double-A-Ron
    Avatar
    Community Member
    604 Posts

    Re: Export import between sites Link to this post

    I'm sure there is a better way than this, and one of the others may respond as such soon. I would be interested to see other methods too.

    But generally, we have phpMyAdmin running on dev, staging and production. For us, prior to launch, the content is entered on a staging server (which also has phpMyAdmin). When we are ready to launch, we simply phpMyAdmin to dump an SQL file on staging, and upload this to production.

    We don't need to touch the CLI for this. And SS's built in draft mode content building gives us the ability to work on any new content without making it live on the frontend - right in the production environment.

    Aaron

  • stevo
    Avatar
    Community Member
    2 Posts

    Re: Export import between sites Link to this post

    So what you are saying is that there is no facility to move just one page from one site to another? I have to do the whole site? And that if I don't have access to mysqldmp, I would need PHPMyAdmin? Thats a high-privilege facility, how do other folks handle it when their Silverstripe site is hosted somewhere without access to PHPMyAdmin?

    I understand what you are saying about the draft mode, but this is not the same as having a true dev/test/prod setup. I want to be able to develop a small group of pages, perhaps with some template changes and theme changes, you cannot do this easily with the Draft mode, you need an independent test system.

  • ChrisBryer
    Avatar
    Community Member
    95 Posts

    Re: Export import between sites Link to this post

    there is no straight forward way to do this, but this may get you close...

    for importing content, take a look at this:
    http://www.silverstripe.org/sitetree-importer-module/

    it looks like Sam and Ingo made a module that takes a yaml-like text file and imports it into the sitetree..

    to export the content, you may want to add some methods to sitetree or homepage to render the appropriate content in the appropriate format. I'm not sure why they ran with yaml when so much is xml based, but i may end up re-writing the module for ourselves sometime in the future anyway to import xml instead.

    i'm not sure what support for dataobjects this module provides, and i havent tried it yet, but it did capture my attention a few days ago.
    hope it helps,
    -Chris

  • inkubux
    Avatar
    Community Member
    11 Posts

    Re: Export import between sites Link to this post

    I have a lot of interest in such a feature.
    After reading the book, I see that Silverstripe have a very nice REST api, So i think my best bet would be to create a module, that does the transfer wiith this API with a POST or a PUT, but my main concern is the assets which can be transfered via rsync.. but I don't want to transfer asses wich belongs to page not ready to be on the production site.

    3123 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.