Support » Plugin: WP Offload S3 Lite » migrate existing wp-content dir to s3?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hey Chaos, I am using a git repo hosted on S3 tied to EB for my WP site. The theory is you then have a stateless version of WP that is easily load balanced. I am still building out so have not tested, but if you’re interested below is the link that I followed. I didn’t find it as easy as just following his steps, but after a fair amount of mucking around I got it working. The second link is setting up a local server which is the first step in case you need it.



    chaos1, did you ever find an answer?

    –dan

    Although I haven’t tried it, by examining the code it looks like the steps are:

    1. upload all wp-content/upload directory to s3
    2. modify wordpress database such that:
    1. for each attachment (wp_posts that has a post_type of “attachment”
      • grab the guid as old_guid
      • create the s3_new_guid as to be where the old_guid gets copied to on s3
      • create the cf_or_s3_guid to be the guid that should appear in the post
      • find the old_guid in the parent post and replace with cf_or_s3_guid
      • modify wp_posts guid to be s3_new_guid
      • create a wp_postmeta with:
      • post_id to the id in wp_posts
      • meta_key to “amazonS3_info”
      • meta_value to a:2:{s:6:”bucket”;s:BUCKET-NAME_LENGTH:BUCKET-NAME;s:3:”key”;sKEY-LENGTH:KEY;}

    that seems like it should do the trick. I’ll let you know when I try it?

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘migrate existing wp-content dir to s3?’ is closed to new replies.