Question

Getting my application to work on the App platform

Posted August 25, 2021 248 views
PHPDigitalOcean App PlatformBuilding a SaaS

Hello!

I’ve copied and had a look at the example repo for a PHP based application, my folder structure in the repo is as follows

src/
_site/index.php
composer.json
gulpfile.js
package.json

So my actual “application” that I want apache to serve from is in under _site.

My gulpfile copies stuff from src, compiles it and puts it into _site/assets/ which i’ve got working as apart of the build process.

I did try just have it move _site/* to /workspace/* but didn’t feel like that was the best thing to do, Anyone have some suggestions or what I can do?

Currently its running heroku-php-apache2 to start it, is there a way I can easily even change the apache path rather than moving stuff?

Cheers!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

×
Submit an Answer
1 answer

Hey there!

You should be able to specify the document root folder to use in your heroku-php-apache2 run command. Something like:

heroku-php-apache2 _site/

As App Platform uses Heroku build-packs the configuration is similar.

Hope it helps!
Nate