Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Is there a way of caching the output of docker-php-ext-install in BitBucket Pipelines?

alnorth March 27, 2018

We've just started using Pipelines for some of our PHP projects, and a major amount of the pipeline time is going on running docker-php-ext-install to install the required PHP extensions. I know I can define my own docker image that includes these extensions but I'd rather use the built in caching on Pipelines if possible. Is there any way to use Pipelines caching to save the results of docker-php-ext-install?

2 answers

1 vote
Grant Lucas June 29, 2018

@alnorth did you end up with a solution that worked for you?

alnorth June 30, 2018

No, I didn't. I'd still be interested if anyone else works it out. However, I think the proper solution is just to bite the bullet and define your own custom Docker image. I'm not that familiar with Docker so I haven't taken the time to do it yet.

Grant Lucas July 10, 2018

Ah, looks like we're in the same boat then :) I'll be sure to update here should I figure anything out.

0 votes
Philip Hodder
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
April 3, 2018

Hi Alasdair,

You can define a custom Pipelines cache by following the instructions here: https://confluence.atlassian.com/bitbucket/caching-dependencies-895552876.html

Thanks,

Phil

Grant Lucas July 10, 2018

Do you have any more information on what might be needed for this. At this time I've tried the following but it doesn't seem to be working

 

definitions:
caches:
php-ext-source: /usr/src/php/ext
php-ext: /usr/local/lib/php/extensions

And then these cache definitions were added to my pipelines. Am I correct in that I'd just need to add locations where stuff is installed to add a new cache? 

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events