- Add comprehensive REST API at /api/v1 with modular structure - Implement authentication endpoints (register, login, logout, me) - Add converter listing and format discovery endpoints - Create job management and file download endpoints - Add health check endpoint for monitoring - Set up CORS support for browser-based API clients - Create API middleware for JWT authentication - Add environment variables for API configuration - Include comprehensive API documentation and test script Infrastructure: - Enhanced CI/CD workflow for custom Docker registries - Docker Compose setup with dev, prod, and monitoring profiles - Claude.ai integration files for development workflow - Environment-based configuration with .env.development Known limitations: - JWT authentication context needs fixing (using ALLOW_UNAUTHENTICATED=true) - Swagger UI temporarily disabled due to composition error - File upload endpoint needs multipart/form-data support The API code is isolated in src/api/ directory to maintain separation from the existing codebase, making it easy to maintain or contribute back.
50 lines
No EOL
1.2 KiB
Markdown
50 lines
No EOL
1.2 KiB
Markdown
# Build and Test Docker Image
|
|
|
|
Please build and test the Docker image with these steps:
|
|
|
|
1. **Build the Docker image**:
|
|
```bash
|
|
docker build -t convertx-openapi:local .
|
|
```
|
|
|
|
2. **Verify the build**:
|
|
- Check image size: `docker images convertx-openapi:local`
|
|
- Inspect layers: `docker history convertx-openapi:local`
|
|
|
|
3. **Run container locally**:
|
|
```bash
|
|
docker run -d \
|
|
--name convertx-test \
|
|
-p 3000:3000 \
|
|
-v $(pwd)/data:/app/data \
|
|
-e JWT_SECRET=test-secret \
|
|
-e NODE_ENV=production \
|
|
convertx-openapi:local
|
|
```
|
|
|
|
4. **Test the application**:
|
|
- Check logs: `docker logs convertx-test`
|
|
- Test health: `curl http://localhost:3000`
|
|
- Verify converters load properly
|
|
|
|
5. **Multi-platform build** (if needed):
|
|
```bash
|
|
docker buildx build \
|
|
--platform linux/amd64,linux/arm64 \
|
|
-t convertx-openapi:local \
|
|
.
|
|
```
|
|
|
|
6. **Push to custom registry** (if configured):
|
|
```bash
|
|
docker tag convertx-openapi:local ${DOCKER_REGISTRY}/convertx:latest
|
|
docker push ${DOCKER_REGISTRY}/convertx:latest
|
|
```
|
|
|
|
7. **Cleanup**:
|
|
```bash
|
|
docker stop convertx-test
|
|
docker rm convertx-test
|
|
```
|
|
|
|
Please execute these steps and report any issues. |