To set up LocalChess using Docker, follow these steps:
- Ensure Docker is installed on your machine.
- Clone the repository:
git clone https://github.com/Licent1/LocalChess.git cd LocalChess - Build the Docker image:
docker build -t localchess . - Run the Docker container:
docker run -p 3000:3000 localchess
To install the backend, perform the following:
- Navigate to the backend directory:
cd backend - Install dependencies:
npm install
- Start the backend server:
npm start
The authentication API of LocalChess allows users to register and login. It supports JWT for managing user sessions. The following endpoints are available:
-
POST /auth/register: Register a new user.
- Body:
{ "username": "string", "password": "string" }
- Body:
-
POST /auth/login: Log in a user and receive a JWT.
- Body:
{ "username": "string", "password": "string" }
- Body:
Ensure to include the JWT in the Authorization header for any protected routes.
This project is licensed under the MIT License.