Administration Guide
Initial Configuration
Before running the project, several configuration steps need to be completed. Follow these steps carefully to ensure proper setup:
Environment Setup
- Locate the three .env.example files using CMD+P (or Ctrl+P on Windows) and typing 'example'
- Rename each file by removing the '.example' extension
- Fill in the correct information in each .env file
Note: There's an .env file in each folder (Root, Backend, and Frontend). Each folder will become a Docker container with its own environment variables.
Node Modules Installation
- Navigate to the backend folder:
cd backend - Install backend dependencies:
yarn install - Navigate to custom plugin directory:
cd src/plugins - Install custom plugin dependencies:
yarn install - Build the custom plugin:
yarn build - Return to root directory:
cd ../../.. - Navigate to frontend folder:
cd frontend - Install frontend dependencies:
yarn install
Stripe Integration
To set up Stripe for payments:
- Create a Stripe account if you haven't already
- Navigate to the Developers section in your Stripe dashboard
- Go to Webhooks and click 'Add endpoint'
- Set the webhook URL to:
https://api.{projectname}.com/api/webhook/webhook - Select the events to listen for (typically 'checkout.session.completed')
- Save the webhook configuration
Email Configuration
We use PostmarkApp for sending emails. It offers $75 in startup credit for new SaaS companies. To set it up:
- Register with PostmarkApp
- Complete their verification process
- Explain your use case (remember, only transactional emails are allowed)
Running the Project
- Ensure no other projects are running to avoid port conflicts
- Restart your computer and start Docker Desktop
- Navigate to the project root in the terminal
- Run
docker compose up
Once complete, you'll have access to:
- localhost:1337 - Backend/Strapi admin panel
- localhost:3005 - NextJS frontend
Key Takeaway
Proper configuration of environment variables, dependencies, and third-party services is crucial for the platform's functionality. Take time to verify each step before proceeding.
Pro Tip
In a development environment, you'll need to save and restart the backend for changes to take effect. In a production environment, the backend would need to be rebuilt.