Create Three Instance
- Frontend-Server
- Backend-Server
- Database-Server
-
standard create
-
Mariadb
-
Free tier
-
Username & Password
-
Connect to EC2 instance
-
Security group select
- install mariadb and start mariadb.
yum install mariadb105-server -y
systemctl start mariadb.service
- install git and clone the Project Repo.
yum install git -y
git clone https://github.com/guru6910/Project-Angular-App
mysql -h <endpoint> -u admin -ppasswd123
create database springbackend;
exit
cd Project-Angular-App/database
mysql -h <endpoint> -u admin -ppasswd123 springbackend < springbackend.sql
mysql -h <endpoint> -u admin -ppasswd123
use springbackend;
select * from tbl_workers;
describe springbackend;
exit
- Install java
yum install java -y
- Install Maven
yum install maven -y
- install git and clone Project Repo
yum install git -y
git clone https://github.com/guru6910/Project-Angular-App
- Create Database Connection with backend
cd Project-Angular-App/spring-backend
vim src/main/resources/application.properties
- Build the project using Maven
mvn clean package -Dmaven.test.skip=true
- Run the application:
java -jar target/spring-backend-v1.jar
- install git and clone
yum install git -y
git clone https://github.com/guru6910/Project-Angular-App
- enter the angular-frontend
cd Project-Angular-App/angular-frontend/
- install nodejs and npm
yum install nodejs npm -y
- Check Node.js and npm versions
node -v
npm -v
- Install Angular CLI globally
sudo npm install -g @angular/cli@14.2.1
- Verify Angular CLI installation
ng version
- Connect with Backend Server
cd src/app/services
vim worker.service.ts
- Install project dependencies.
npm install
ng build
ng serve --host 0.0.0.0 --port=80


