This is a full-stack social network application with a Go backend and a Next.js frontend. It's set up to be easily run with Docker.
backend/: The Go API.frontend/: The Next.js web application.docker-compose.yml: Defines the services for running the application.
To get the application running, you'll need Docker and Docker Compose installed.
-
Build and run the services:
docker-compose up --build
This command will build the Docker images for both the frontend and backend and start the containers.
-
Access the application:
- Frontend: http://localhost:3000
- Backend: http://localhost:8080
You can also run the frontend and backend services locally for development.
- Navigate to the backend directory:
cd backend - Install dependencies:
go mod tidy
- Run the server:
The backend will be running on
go run ./cmd/
http://localhost:8080.
-
Navigate to the frontend directory:
cd frontend -
Install dependencies:
npm install
-
Run the development server:
npm run dev
The frontend will be running on
http://localhost:3000.Note: When running the frontend locally, you'll need to create a
.env.localfile in thefrontenddirectory and set the API URL:NEXT_PUBLIC_API_URL=http://localhost:8080
- Run in detached mode:
docker-compose up --build -d
- Stop the services:
docker-compose down
- View logs:
docker-compose logs -f <service_name> # e.g., backend or frontend
@azraji, @abalouri, @abaid, @mennas, @ranniz, @ychatoua