0

I have PHP application and am maintaining my frontend assets using npm (package.json). When I start build in openshift then the build have to import my static libraries into my project assets folder which I defined in package.json and move to CDN server (I have shared network location which I can share with build service account - PVC(Persistence Volume Claim) with ReadWrite access) and deploy my php app to my php container.

spapp

  • applications - folder
  • assets - my static assets such css, js, images
  • composer.json - php libraries
  • package.json - static libraries

When I request a build then the build will do the following:

  1. install my composer.json libraries (working fine now)
  2. install my package.json libraries into assets folder and move it to CDN server via network path or shared PVC ( Expecting )
  3. deploy my app to PHP container (working fine now)
zen
  • 980
  • 6
  • 18
Hari Inukollu
  • 179
  • 2
  • 10
  • How would you do (2) if you weren't using OpenShift? – Graham Dumpleton Aug 18 '18 at 03:16
  • I was doing it manually. – Hari Inukollu Aug 18 '18 at 04:49
  • You are possibly better off doing the upload of assets from the image to the CDN from a pre lifecycle hook when doing a deployment. Because the pre lifecycle hook is run on every deployment, it needs to handle assets already having been uploaded. Not possible to advise more than that since you don't explain actual manual steps you use to upload now. – Graham Dumpleton Aug 19 '18 at 04:17

0 Answers0