Initial stage
This commit is contained in:
@@ -0,0 +1,46 @@
|
||||
# CLProject Development Environment
|
||||
|
||||
This workspace now contains a containerized local development setup based on Node.js, MariaDB, phpMyAdmin, Docker Compose, and VS Code Dev Containers.
|
||||
|
||||
## Services
|
||||
|
||||
- `app`: Node.js development container built from `bitnami/node`
|
||||
- `db`: MariaDB container built from `bitnami/mariadb`
|
||||
- `phpmyadmin`: phpMyAdmin container for database inspection
|
||||
|
||||
## Open In VS Code
|
||||
|
||||
1. Open this workspace in VS Code.
|
||||
2. Run `Dev Containers: Reopen in Container`.
|
||||
3. Wait for the `app` service to install dependencies and start the server.
|
||||
|
||||
The mounted workspace remains editable from VS Code while running inside the container.
|
||||
|
||||
## Ports
|
||||
|
||||
- App: `http://localhost:3000`
|
||||
- phpMyAdmin: `http://localhost:8080`
|
||||
- MariaDB: `localhost:3306`
|
||||
|
||||
## Validate The Environment
|
||||
|
||||
After the containers are up, run:
|
||||
|
||||
```bash
|
||||
npm run test:environment
|
||||
```
|
||||
|
||||
The test checks that:
|
||||
|
||||
- the Node.js app is reachable
|
||||
- the app can talk to MariaDB
|
||||
- the seed table was created successfully
|
||||
|
||||
## Database Login
|
||||
|
||||
- Server: `db`
|
||||
- Database: `app_db`
|
||||
- User: `app_user`
|
||||
- Password: `app_password`
|
||||
|
||||
Root password is configured in `.env` for local development.
|
||||
Reference in New Issue
Block a user