Skip to content
This repository has been archived by the owner on Sep 16, 2019. It is now read-only.

Using FoundationPress in production on EC2 #692

Closed
Epyon616 opened this issue Jan 22, 2016 · 5 comments
Closed

Using FoundationPress in production on EC2 #692

Epyon616 opened this issue Jan 22, 2016 · 5 comments

Comments

@Epyon616
Copy link

Hi There,

Firstly allow me to say that I've absolutely loved developing my Wordpress theme using FoundationPress, as a Ruby developer I've used the Foundation framework a few times in the past.

However I am having one slight issue with moving my theme into production. I am hosting Wordpress on an EC2 instance which is all working great however since moving my finished theme to production I've found that the assets need recompiling again, the problem comes in that I'm struggling to be able to install all the necessary components to allow me to compile them. I was wondering is there a way of compiling them in development so that In production I only have to use the static CSS and JS files?

Alternatively has anyone else used FoundationPress on an EC2 instance? and if so could you detail what I would need to do to get the theme compiled and running on my server.

Thanks

@colin-marshall
Copy link
Collaborator

Run gulp package and it will create a zip file inside a directory called packaged with all the files you need so you can place it on your server.

@toddheslin
Copy link

Hey @StealthyGecko I had a real pain in the ass getting this to work on Amazon EBS however now it's up and running and really smooth. My process (whether right or wrong) is to do all development locally in a staging branch and then merge changes into production which deploybot picks up, packages and automatically deploys to Amazon EBS.

I should note that what is packaged is the entire WP directory from root to theme, not just the theme.

The trick is that you never install plugins on your live site, only ever locally, otherwise it will be overwritten by the next package that is sent up.

I haven't optimised the package size here, so I'm likely deploying more than required but it hasn't had any performance hit that I can see (yet).

Let me know if you had any specific questions, I may be able to help.

@Epyon616
Copy link
Author

Thanks for this, I actually tried a similar although felt more hacky way of doing the same thing in that I removed the stylesheets and javascripts dirs from gitignore and after that it worked fine but I can see how using "gulp package" would have the same effect and I'm surprised that I didn't spot anything about this in the Read Me. Thanks for your help though Colin

@AdamQuadmon
Copy link

don't you think you should state this in the docs?

@colin-marshall
Copy link
Collaborator

@AdamQuadmon @StlthyLee I have put in a PR to add this to the docs. Sorry for not doing this sooner!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants