You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
-**Dependencies**: Creates virtual environment and installs Python/npm packages
130
+
-**Service Launch**: Starts both backend (port 8000) and frontend (port 3000) servers
131
+
132
+
> **Note**: The script includes a 30-second wait time for the backend to initialize before starting the frontend. However, sometimes it might take more time. If you see connection errors in the frontend initially, please wait a moment for the backend to become fully ready, then reload the frontend once the backend is available.
133
+
134
+
## Running Backend and Frontend Separately
135
+
136
+
### Manually Assign Roles
107
137
108
138
To run the accelerator locally when the solution is secured by RBAC, you need to assign roles to your principal ID. You can get your principal ID from Microsoft Entra ID.
109
139
@@ -134,16 +164,16 @@ az cosmosdb sql role assignment create \
Open your terminal and navigate to the root folder of the project, then create the virtual environment:
198
228
@@ -212,7 +242,7 @@ source .venv/bin/activate
212
242
213
243
> **Note**: After activation, you should see `(.venv)` in your terminal prompt indicating the virtual environment is active.
214
244
215
-
### Step 2: Install Dependencies and Run
245
+
####Step 2: Install Dependencies and Run
216
246
217
247
To develop and run the backend API locally:
218
248
@@ -234,7 +264,7 @@ The backend API will run on `http://127.0.0.1:8000` by default.
234
264
235
265
> **Note**: Make sure your virtual environment is activated before running these commands. You should see `(.venv)` in your terminal prompt when the virtual environment is active.
236
266
237
-
## Develop & Run the Frontend Locally
267
+
###Develop & Run the Frontend Locally
238
268
239
269
To run the React frontend in development mode:
240
270
@@ -246,35 +276,6 @@ npm start
246
276
247
277
The frontend will run on `http://localhost:3000` and automatically proxy API requests to the backend.
248
278
249
-
250
-
## Running with Automated Script
251
-
252
-
For convenience, you can use the provided startup scripts that handle environment setup and start both services:
253
-
254
-
**Windows:**
255
-
```cmd
256
-
cd src
257
-
.\start.cmd
258
-
```
259
-
260
-
**macOS/Linux:**
261
-
```bash
262
-
cd src
263
-
chmod +x start.sh
264
-
./start.sh
265
-
```
266
-
267
-
### What the Scripts Do
268
-
269
-
The startup scripts automate the complete local development setup:
270
-
271
-
-**Environment & Authentication**: Copies `.env` files from Azure deployment and handles Azure login
-**Dependencies**: Creates virtual environment and installs Python/npm packages
274
-
-**Service Launch**: Starts both backend (port 8000) and frontend (port 3000) servers
275
-
276
-
> **Note**: The script includes a 30-second wait time for the backend to initialize before starting the frontend. However, sometimes it might take more time. If you see connection errors in the frontend initially, please wait a moment for the backend to become fully ready, then reload the frontend once the backend is available.
0 commit comments