npm install -g @angular/cligit clone https://github.com/glorylabs/recruitment-platform.git
cd recruitment-platform
cd backend
mvn clean install
mvn spring-boot:run
Backend will run on: http://localhost:8080/api
cd frontend/recruitment-portal
npm install
npm start
Frontend will run on: http://localhost:4200
cd website/website
npm install
npm run dev
CMS will run on: http://localhost:4321
Create .env file in backend root:
# Firecrawl API
FIRECRAWL_API_KEY=your-firecrawl-api-key-here
# Database (for production)
DB_HOST=localhost
DB_PORT=5432
DB_NAME=recruitment
DB_USER=your-db-user
DB_PASSWORD=your-db-password
# JWT Secret (generate a secure key)
JWT_SECRET=your-very-secure-jwt-secret-key-here
# Application
SERVER_PORT=8080
SPRING_PROFILES_ACTIVE=dev
cd backend
mvn clean install
No setup required. H2 runs in-memory automatically.
Access H2 Console: http://localhost:8080/api/h2-console
jdbc:h2:mem:testdbsa-- Create database
CREATE DATABASE recruitment;
-- Create user
CREATE USER recruitment_user WITH PASSWORD 'secure_password';
-- Grant privileges
GRANT ALL PRIVILEGES ON DATABASE recruitment TO recruitment_user;
Update application.yml:
spring:
datasource:
url: jdbc:postgresql://localhost:5432/recruitment
username: recruitment_user
password: secure_password
mvn test
mvn clean package
java -jar target/recruitment-backend-0.0.1-SNAPSHOT.jar
cd frontend/recruitment-portal
npm install
Edit src/environments/environment.ts:
export const environment = {
production: false,
apiUrl: 'http://localhost:8080/api',
firecrawlEnabled: true
};
Edit src/environments/environment.prod.ts:
export const environment = {
production: true,
apiUrl: 'https://api.glorylabs.nl/api',
firecrawlEnabled: true
};
npm start
# or
ng serve
npm run build
# or
ng build --configuration production
# Unit tests
npm test
# E2E tests
npm run e2e
# Generate component
ng generate component components/job-list
# Generate service
ng generate service services/job
# Generate module
ng generate module features/jobs
cd website/website
npm install
npm run dev
npm run build
npm run preview
# Test if backend is running
curl http://localhost:8080/api/jobs
# Search jobs
curl "http://localhost:8080/api/jobs/search?query=developer"
# Get job details
curl http://localhost:8080/api/jobs/1
/docs/postman-collection.jsonbase_url to http://localhost:8080/apihttp://localhost:8080/api/h2-consolejdbc:h2:mem:testdbsa-- Insert sample jobs
INSERT INTO jobs (title, company, location, type, category, level, description, active, created_at, published_at, expires_at)
VALUES
('Senior Java Developer', 'Tech Corp', 'Amsterdam', 'Full-time', 'IT', 'Senior', 'Great opportunity for experienced Java developer', true, NOW(), NOW(), NOW() + INTERVAL '30 days'),
('Marketing Manager', 'Marketing Pro', 'Rotterdam', 'Full-time', 'Marketing', 'Manager', 'Lead our marketing team', true, NOW(), NOW(), NOW() + INTERVAL '30 days'),
('Data Analyst', 'Data Company', 'Remote', 'Contract', 'Data', 'Mid-level', 'Analyze business data and create insights', true, NOW(), NOW(), NOW() + INTERVAL '30 days');
-- Insert sample users
INSERT INTO users (username, email, password, first_name, last_name, role, enabled, created_at)
VALUES
('admin', 'admin@glorylabs.nl', '$2a$10$encrypted_password_here', 'Admin', 'User', 'ADMIN', true, NOW()),
('recruiter', 'recruiter@glorylabs.nl', '$2a$10$encrypted_password_here', 'Recruiter', 'User', 'RECRUITER', true, NOW());
# Find process using port 8080
lsof -i :8080 # Mac/Linux
netstat -ano | findstr :8080 # Windows
# Kill the process or change port in application.yml
server:
port: 8081
# Clear Maven cache
rm -rf ~/.m2/repository
mvn clean install -U
pg_isreadynpm install -g @angular/cli
# Use Node Version Manager (nvm)
nvm install 18
nvm use 18
Ensure backend CORS configuration includes frontend URL:
cors:
allowed-origins: http://localhost:4200
# Backend
mvn clean install -X # Verbose output
# Frontend
npm ci # Clean install
npm run build -- --verbose
# Create feature branch
git checkout -b feature/job-recommendations
# Make changes
# Test locally
# Commit changes
git add .
git commit -m "Add job recommendation feature"
# Push to remote
git push origin feature/job-recommendations
# Run linter
mvn checkstyle:check
# Run tests with coverage
mvn test jacoco:report
# Run linter
npm run lint
# Run tests with coverage
npm test -- --code-coverage
When Flyway is configured:
# Create migration
touch src/main/resources/db/migration/V1__Create_jobs_table.sql
# Run migrations
mvn flyway:migrate
Install extensions:
Configure settings.json:
{
"java.configuration.updateBuildConfiguration": "automatic",
"java.home": "/path/to/java17",
"editor.formatOnSave": true,
"prettier.singleQuote": true
}
FROM openjdk:17-jdk-slim
COPY target/recruitment-backend-0.0.1-SNAPSHOT.jar app.jar
ENTRYPOINT ["java","-jar","/app.jar"]
FROM node:18-alpine AS build
WORKDIR /app
COPY package*.json ./
RUN npm ci
COPY . .
RUN npm run build
FROM nginx:alpine
COPY --from=build /app/dist/recruitment-portal /usr/share/nginx/html
version: '3.8'
services:
backend:
build: ./backend
ports:
- "8080:8080"
environment:
- SPRING_PROFILES_ACTIVE=docker
- FIRECRAWL_API_KEY=${FIRECRAWL_API_KEY}
depends_on:
- postgres
frontend:
build: ./frontend/recruitment-portal
ports:
- "4200:80"
depends_on:
- backend
postgres:
image: postgres:14
environment:
- POSTGRES_DB=recruitment
- POSTGRES_USER=recruitment_user
- POSTGRES_PASSWORD=secure_password
volumes:
- postgres_data:/var/lib/postgresql/data
volumes:
postgres_data:
# Backend logs
tail -f backend/logs/application.log
# Frontend build logs
npm run build -- --verbose
/actuator/*Never commit sensitive data
.env to .gitignoreUpdate dependencies regularly
# Backend
mvn versions:display-dependency-updates
# Frontend
npm audit
npm audit fix
For issues or questions:
Reacties