How to Run
Initializing
In this directory, run:devbox shell
This will run initdb automatically on initialization. To start the Servers + Postgres service,
run:
devbox services up
Creating the DB
You can run the creation script usingdevbox run create_db. This will create a Postgres DB based
on setup_postgres_db.sql.
Testing the Example
You can query Nginx on port 80, which will route to the PHP example.How to Recreate this Example
- Create a new project with
devbox init - Add the packages using the command below. Installing the packages with
devbox addwill ensure that the plugins are activated:
- Update
devbox.d/nginx/httpd.confto point to the directory with your PHP files. You’ll need to update therootdirective to point to your project folder - Follow the instructions above in the How to Run section to initialize your project.
.sock filepath can only be maximum 100 characters long. You can point to a different
path by setting the PGHOST env variable in your devbox.json as follows: