Reviewed-on: #2
Liam Pietralla Porfolio
The portfolio is built using Next.JS and Payload CMS. Payload is running directly in the Next app, and can be accessed by appending /admin to the route.
Next is currently using a sqlite database and local file storage. Both are output to a portfolio-data
directory.
Development
To develop the application use pnpm to install the dependencies:
pnpm install
Once downloaded you can use pnpm to run the project:
pnpm dev
Payload CMS
Payload will require rebuilding on the types file once any changes are made:
pnpm run payload:generate:types
In local mode payload will apply any changes to the config to the database automatically. To generate a migration once changes are made, you can use the following command:
pnpm run payload:migrate:create
Deploying
Deploying the portfolio is done as a docker container. It can be built with the following command:
docker build -t liam-portfolio .
Running the Container
Once the container is built, you can run it with the following command:
docker run -p 3000:3000 -v liam-portfolio-data:/app/portfolio-data -e PAYLOAD_SECRET=your_secret liam-portfolio