Skip to content

Commit

Permalink
Update (#56)
Browse files Browse the repository at this point in the history
  • Loading branch information
haiphucnguyen authored Jan 26, 2025
1 parent 4d2a5a5 commit 2ec6c9d
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 3 deletions.
13 changes: 13 additions & 0 deletions .env.local.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# BACK_END_URL: The base URL of the backend API that the Next.js application communicates with.
# Typically used for server-side API calls in your application. Example: http://localhost:8080
BACK_END_URL=

# NEXT_PUBLIC_BASE_URL: A publicly exposed base URL for the backend API.
# Variables prefixed with NEXT_PUBLIC_ are exposed to the browser and used for client-side API calls.
# Example: http://localhost:8080
NEXT_PUBLIC_BASE_URL=

# AUTH_SECRET: A secret key used by the authentication library (`auth.js`) for securing tokens.
# This was automatically added by running `npx auth`.
# For production, it is recommended to use a securely generated key. Learn more: https://cli.authjs.dev
AUTH_SECRET=
17 changes: 14 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,20 +89,27 @@ And Many More: FlowInquiry leverages various open-source components, including t

### Setup Instructions

**1. Clone the repository:**
#### 1. Clone the repository:

```bash
git clone [email protected]:flowinquiry/flowinquiry-frontend.git
cd flowinquiry-frontend
```

**2. Install dependencies**
#### 2. Install dependencies

```bash
pnpm install
```

**3. Configure application parameters**
#### 3. Configure application parameters\*

To run the FlowInquiry frontend, users need to provide their input in the local configuration file .env.local. FlowInquiry offers two options for creating this configuration file:

Using Bash Scripts: Users can run provided Bash scripts, which prompt for inputs, validate the information, and then automatically generate the configuration file.
Editing a Template Manually: A template configuration file (.env.local.example) is provided, allowing users to manually edit and create their .env.local file. This option is recommended for users who cannot run Bash scripts.

##### 3.1 Creating config file using script

Set up the application environment variables by running the following script:

Expand All @@ -118,6 +125,10 @@ BACK_END_URL=http://localhost:8080

We recommend running the `scripts/all.sh` script, as it streamlines the process by checking your environment settings and performing all necessary configurations, removing the need to execute multiple scripts manually.

##### 3.2 Edit config file manually

Rename the file [.env.local.example](./.env.local.example) to .env.local, and edit the file content per instructions inline

**4. Start the development server**

```bash
Expand Down

0 comments on commit 2ec6c9d

Please sign in to comment.