Merged the projects
This commit is contained in:
parent
b83c448573
commit
7f9cf79a21
46
AISApp/Dockerfile
Normal file
46
AISApp/Dockerfile
Normal file
@ -0,0 +1,46 @@
|
||||
# Multi-stage build for ASP.NET Core application
|
||||
FROM mcr.microsoft.com/dotnet/sdk:9.0 AS build
|
||||
WORKDIR /app
|
||||
|
||||
# Copy project files
|
||||
COPY AISApp.csproj .
|
||||
COPY . .
|
||||
|
||||
# Restore dependencies
|
||||
RUN dotnet restore AISApp.csproj
|
||||
|
||||
# Build the application
|
||||
RUN dotnet build AISApp.csproj -c Release -o /app/build
|
||||
|
||||
# Publish the application
|
||||
RUN dotnet publish AISApp.csproj -c Release -o /app/publish
|
||||
|
||||
# Runtime stage
|
||||
FROM mcr.microsoft.com/dotnet/aspnet:9.0 AS runtime
|
||||
WORKDIR /app
|
||||
|
||||
# Install curl for health checks
|
||||
RUN apt-get update && apt-get install -y curl && rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Copy published application
|
||||
COPY --from=build /app/publish .
|
||||
|
||||
# Copy prompt.txt file
|
||||
COPY prompt.txt .
|
||||
|
||||
# Create directory for static files
|
||||
RUN mkdir -p static
|
||||
|
||||
# Expose port
|
||||
EXPOSE 80
|
||||
|
||||
# Set environment variables
|
||||
ENV ASPNETCORE_URLS=http://+:80
|
||||
ENV ASPNETCORE_ENVIRONMENT=Production
|
||||
|
||||
# Health check
|
||||
HEALTHCHECK --interval=30s --timeout=10s --start-period=40s --retries=3 \
|
||||
CMD curl -f http://localhost/api/chat || exit 1
|
||||
|
||||
# Run the application
|
||||
ENTRYPOINT ["dotnet", "AISApp.dll"]
|
||||
10
TODO.md
10
TODO.md
@ -20,7 +20,7 @@ Integrate the ASP.NET chatbot service into the existing Node.js backend system t
|
||||
### 1.3 Create Chatbot Service Dockerfile
|
||||
- **Status**: ✅ Completed
|
||||
- **Description**: Create proper Dockerfile for the ASP.NET chatbot service
|
||||
- **Files**: `tuna/tuna/Dockerfile`
|
||||
- **Files**: `AISApp/Dockerfile`
|
||||
- **Details**: Multi-stage build with proper .NET 9.0 runtime and configuration
|
||||
|
||||
## Phase 2: Backend Service Integration
|
||||
@ -54,25 +54,25 @@ Integrate the ASP.NET chatbot service into the existing Node.js backend system t
|
||||
### 3.1 Add MySQL Database Support
|
||||
- **Status**: ✅ Completed
|
||||
- **Description**: Replace SQLite with MySQL database connection in ASP.NET service
|
||||
- **Files**: `tuna/tuna/AISApp/AIS.cs`, `tuna/tuna/AISApp/Program.cs`
|
||||
- **Files**: `AISApp/AISApp/AIS.cs`, `AISApp/AISApp/Program.cs`
|
||||
- **Details**: Add MySQL connection string and update database operations
|
||||
|
||||
### 3.2 Add Interview Context Endpoints
|
||||
- **Status**: ✅ Completed
|
||||
- **Description**: Create endpoints for interview initialization and context management
|
||||
- **Files**: `tuna/tuna/AISApp/Program.cs`
|
||||
- **Files**: `AISApp/AISApp/Program.cs`
|
||||
- **Details**: Add endpoints for interview start, status, and completion
|
||||
|
||||
### 3.3 Implement Conversation Sync
|
||||
- **Status**: ✅ Completed
|
||||
- **Description**: Sync conversation data between ASP.NET service and MySQL database
|
||||
- **Files**: `tuna/tuna/AISApp/AIS.cs`
|
||||
- **Files**: `AISApp/AISApp/AIS.cs`
|
||||
- **Details**: Update conversation persistence to use MySQL instead of SQLite
|
||||
|
||||
### 3.4 Add Interview-Specific Prompts
|
||||
- **Status**: ✅ Completed
|
||||
- **Description**: Modify system prompts based on job requirements and interview context
|
||||
- **Files**: `tuna/tuna/AISApp/prompt.txt`, `tuna/tuna/AISApp/AIS.cs`
|
||||
- **Files**: `AISApp/AISApp/prompt.txt`, `AISApp/AISApp/AIS.cs`
|
||||
- **Details**: Dynamic prompt generation based on job details and interview stage
|
||||
|
||||
## Phase 4: Database Integration
|
||||
|
||||
@ -22,7 +22,7 @@ services:
|
||||
|
||||
chatbot:
|
||||
build:
|
||||
context: ../../tuna/tuna
|
||||
context: ../../AISApp
|
||||
dockerfile: Dockerfile
|
||||
image: candidat/chatbot:latest
|
||||
container_name: backend-chatbot
|
||||
|
||||
@ -82,7 +82,7 @@ services:
|
||||
# Frontend Service
|
||||
frontend:
|
||||
build:
|
||||
context: ./frontend/candidat-frontend
|
||||
context: ./frontend
|
||||
dockerfile: Dockerfile
|
||||
image: candidat/frontend:${APP_VERSION:-latest}
|
||||
container_name: candidat-frontend
|
||||
@ -93,7 +93,7 @@ services:
|
||||
- "${FRONTEND_PORT:-3000}:3000"
|
||||
volumes:
|
||||
# Development hot reloading (only if NODE_ENV=development)
|
||||
- ./frontend/candidat-frontend/src:/app/src:ro
|
||||
- ./frontend/src:/app/src:ro
|
||||
depends_on:
|
||||
backend:
|
||||
condition: service_healthy
|
||||
@ -116,7 +116,7 @@ services:
|
||||
# Chatbot Service
|
||||
chatbot:
|
||||
build:
|
||||
context: ./tuna/tuna
|
||||
context: ./AISApp
|
||||
dockerfile: Dockerfile
|
||||
image: candidat/chatbot:${APP_VERSION:-latest}
|
||||
container_name: candidat-chatbot
|
||||
|
||||
@ -29,7 +29,7 @@ A stunning, responsive frontend built with Next.js 15, TypeScript, and Tailwind
|
||||
## 🏗️ **Project Structure**
|
||||
|
||||
```
|
||||
frontend/candidat-frontend/
|
||||
frontend/
|
||||
├── src/
|
||||
│ ├── app/
|
||||
│ │ ├── page.tsx # Main landing page
|
||||
|
||||
Loading…
Reference in New Issue
Block a user