"The Sun Reader" project is a full-stack web application developed for study purposes. It serves as a news aggregator with an additional bookmarking functionality.
- Browsing and reading news articles from various sources.
- Registration and login functionality.
- Bookmarking articles for future reference.
- User profile page for bookmarks managing.
- Additional capabilities for moderators and administrators.
- Integration with external APIs.
- Front-end: NodeJS, ReactJS, HTML5, CSS3
- Back-end: Spring Boot (Kotlin), Mockk, JUnit5, Dokka
- Database: MySQL
- Docker: Containerization and deployment
- HTTP Client: Axios
- Version Control: Git
To quickstart The Sun Reader project, follow these steps:
-
Clone the repository to your local machine.
git clone https://github.com/watisluv1910/mirea_5s_server-side-development_course-work.git
-
Make sure you have Docker installed and enabled.
-
Build and run the Docker containers using the
docker-compose up
command in project's root directory. -
Access the application in your browser at http://localhost:3000.
To start the project locally:
-
Clone the repository to your local machine.
git clone https://github.com/watisluv1910/mirea_5s_server-side-development_course-work.git
-
Run the following command from project's root directory:
For Unix-like systems:
./mvnw clean package
For Windows:
mvnw.cmd clean package
-
Install the tools listed below if you don't already have them:
- Java Development Kit >= v17.0.9.
- MySQL Server >= v8.2.0.
- Node JS >= 20.13.1.
-
In
.env
file located in the root directory modify MYSQL_USER and MYSQL_PASSWORD to match your MySQL Server credentials. Modify other environmental variables according to your preferences and needs. Note that:- ENV_FILE variable should NOT be modified.
- Provided MYSQL_USER should at least have the following privileges:
- ALTER, CREATE, CREATE TABLESPACE, DROP, INDEX, REFERENCES;
- SELECT, UPDATE, DELETE.
-
Check MySQL Server is running at MYSQL_TCP_PORT. Change MYSQL_TCP_PORT environmental variable if needed.
-
Run backend server by executing the following commands from project's root directory:
java -jar backend/target/backend-<version>.jar
-
Run frontend server by executing the following commands from project's root directory:
cd react-ui && npm run start
-
Access the application in your browser at http://localhost:3000 (or another port if you changed FRONTEND_DEFAULT_PORT environment variable).
To ensure consistency throughout the source code, keep these rules in mind as you are working:
- All features or bug fixes must be tested by one or more specs (unit-tests).
- All public API methods must be documented with Doc comments.
- We follow Conventional Commits and Commitlint configs.
We have very precise rules over how git commit messages can be formatted. This leads to more readable messages that are easy to follow when looking through the project history.
Each commit message consists of a header, a body and a footer. The header has a special format that includes a type, a scope and a subject:
<type>(<scope1>, <scope2>): <subject>
<BLANK LINE>
<body>
<BLANK LINE>
<footer>
The header is mandatory and the scopes of the header are optional.
Samples:
refactor(env): update example .env file to match services requirements
fix(proxy)!: implemented test proxy configuration
BREAKING CHANGE!
- Make changes to the code in the respective folders.
- Run the application locally using the provided scripts or commands.
- Test your changes and verify that the application is functioning as expected.
- Commit your changes to a new branch and push them to the remote repository.
- Create a pull request for review and merge it into the main branch.
For any inquiries or questions, please contact at [email protected] with tag SunReader
.