Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .env
Original file line number Diff line number Diff line change
@@ -1 +1 @@
NEXT_PUBLIC_API_BASE_URL=http://localhost:8070
API_BASE_URL=http://localhost:8070
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ RUN apk update
RUN apk add --no-cache libc6-compat

# Setup pnpm on the alpine base
FROM alpine as base
FROM alpine AS base
RUN npm install pnpm --global
RUN pnpm config set store-dir ~/.pnpm-store

Expand All @@ -23,7 +23,7 @@ RUN --mount=type=cache,id=pnpm,target=~/.pnpm-store pnpm install --frozen-lockfi
# Copy source code
COPY . .

ENV NEXT_TELEMETRY_DISABLED 1
ENV NEXT_TELEMETRY_DISABLED=1
RUN pnpm build

# Final image
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ The easiest way to use the Flowdapt dashboard is by simply running the Docker im
docker run --network=host ghcr.io/emergentmethods/flowdapt-dashboard:latest
```

It will run the dashboard on `http://localhost:3030` and it will look for a running Flowdapt server on `http://localhost:8070`. If you are running Flowdapt at a different location, you can specify that by controlling the environment variable `NEXT_PUBLIC_API_BASE_URL=http://localhost:8070`.
It will run the dashboard on `http://localhost:3030` and it will look for a running Flowdapt server on `http://localhost:8070`. If you are running Flowdapt at a different location, you can specify that by controlling the environment variable `API_BASE_URL=http://localhost:8070`.

### Project Setup Guide

Expand Down
3 changes: 2 additions & 1 deletion src/lib/util.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,9 @@ export const getLanguage = (props: Flowdapt.IPageParams) => {
* @returns The created Configuration object with the basePath set.
*/
export const getClient = () => {
const baseUrl = process.env.API_BASE_URL || "http://localhost:8070";
const flowdaptSDKClient = new FlowdaptSDK({
baseUrl: process.env.NEXT_PUBLIC_API_BASE_URL,
baseUrl,
});

return flowdaptSDKClient;
Expand Down
2 changes: 1 addition & 1 deletion types/global.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ interface Window {
declare namespace NodeJS {
interface ProcessEnv {
// Declare environment variables here
NEXT_PUBLIC_API_URL: string;
API_BASE_URL: string;
}
}

Expand Down
Loading