Faster environment setup with wordpress


#1

It seems to take 3 minutes to setup our test environment. is there a way we can better cache this process? are we doing things in the wrong places and therefore things are not caches properly?

I’m doing half the setup in dependencies: pre: and then the remainder in post:


#2

Can you share your build URL and Circle.yml file so we can see what steps you are taking?


#3

Hi, Here is the build: https://circleci.com/gh/dwenaus/programs/1733
There may be private info in the yml file, so I’d rather not share it here.
(I preferred your in-app support system rather than this separate community site. I get no notification from it.)


#4

I posted the circle.yml file to Intercom.


#5

Hmm… you should be notified via email whenever someone responds to one of your topics. Could do me a favor and check spam to make sure you didn’t get an email.


#6

I’m flooded with email, hench the beauty of the in-app intercom. Any help with this? How can I privately get the circle.yml file to you? I posted it in intercom but no one has seen it yet.


#7

Hi @dwenaus,

I’m not familiar with the WordPress CLI, so I’m not sure what can be done to cache its output. If you can figure out where the output is being stored (i.e. via SSH), you can cache it by adding it to dependencies: cache_directories in your circle.yml.

Caching aside, it looks like you’re firing off a lot of commands that individually don’t take very long. I believe you could get a significant improvement in your build times by combining the commands into one or more scripts.

Hope this helps!

-Frank


#8

We added a script that runs many of the wp-cli commands. That shaved more than 2 minutes of our build time. :smile:


#9