Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit6f848f5

Browse files
2 parentsde04991 +be8e2ce commit6f848f5

File tree

1 file changed

+36
-13
lines changed

1 file changed

+36
-13
lines changed

‎README.md‎

Lines changed: 36 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,41 +1,56 @@
11
#Login Page
22

33
##Environment Requirements
4+
###General
5+
- Windows 10
6+
7+
###Backend
8+
- Python 3.12.4
9+
10+
###Frontend
411
- Node.js v20.11.1
512
- npm v10.5.0
6-
- Windows 10
713

814
##Installation Instructions
915

1016
1.**Clone the repository**
1117
```bash
12-
git clone https://github.com/helloworld0606/interviewProjects.git
18+
git clone https://github.com/helloworld0606/interviewPython.git
1319
```
1420

15-
2.**Runthe backend server**
21+
2.**Set upthe backend server** (cmd)
1622
```bash
17-
cd interviewProjects/backend
18-
npm install
19-
npm audit# find security vulnerabilities
20-
npm audit fix # fix any security vulnerabilities
21-
node server.js
23+
cd C:\interviewPython\backend
24+
python -m venv venv
25+
.\venv\Scripts\activate
26+
pip install -r requirements.txt
2227
```
2328

24-
3.**Run the frontend server** (open another cmd)
29+
**Install Rust** (if not already installed) Rust is needed to compile`bcrypt`
2530
```bash
26-
cd interviewProjects/frontend
31+
curl --proto'=https' --tlsv1.2 -sSf https://sh.rustup.rs| sh
32+
```
33+
34+
**Run the backend server**
35+
```bash
36+
python app.py
37+
```
38+
39+
4.**Run the frontend server** (terminal)
40+
```bash
41+
cd C:\interviewPython\frontend
2742
npm install
2843
npm audit# find security vulnerabilities
2944
npm audit fix # fix any security vulnerabilities
3045
npm run serve
3146
```
3247

33-
4.**The app will run at [http://localhost:8080/](http://localhost:8080/)**
48+
5.**The app will run at [http://localhost:8080/](http://localhost:8080/)**
3449

3550

3651

3752
## Account info in db.json
38-
(make sure backend is running)
53+
"make sure backend is running"
3954

4055
Get account
4156
```bash
@@ -47,7 +62,15 @@ curl -X POST "http://localhost:3000/users" -H "Content-Type: application/json" -
4762
```
4863
Login account
4964
```
50-
curl -X POST "http://localhost:3000/users/login" -H "Content-Type: application/json" -d "{\"account\":\"james123@gmail.com\",\"password\":\"DEF789\"}"
65+
curl -X POST "http://localhost:3000/users/login" -H "Content-Type: application/json" -d "{\"account\":\"alice123@gmail.com\",\"password\":\"ABC123456\"}"
66+
```
67+
Two Factor Auth
68+
1. When login is successful, a QR code window will pop up.
69+
2. Scan the QR code using the Authenticator app on your iPhone.
70+
3. Replace XXXXXX (6 digits) with the one-time code from MyApp.
71+
72+
```
73+
curl -X POST "http://localhost:3000/2fa/verify-otp" -H "Content-Type: application/json" -d "{\"userId\":1,\"otp\”:\”XXXXXX\”}”
5174
```
5275
5376
## Test account:

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp