forked from open-telemetry/opentelemetry-demo
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request open-telemetry#1725 from maindotmarcell/add-flagd-ui
Add flagd UI
- Loading branch information
Showing
34 changed files
with
6,327 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
# Dependency directories | ||
node_modules | ||
/.pnp | ||
.pnp.js | ||
|
||
# Next.js build output | ||
.next | ||
out | ||
|
||
# Testing | ||
/coverage | ||
|
||
# Production | ||
/build | ||
|
||
# Misc | ||
.DS_Store | ||
*.pem | ||
|
||
# Debug | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
|
||
# Local env files | ||
.env*.local | ||
|
||
# Vercel | ||
.vercel | ||
|
||
# TypeScript | ||
*.tsbuildinfo | ||
next-env.d.ts | ||
|
||
# IDE/Editor folders | ||
.idea | ||
.vscode | ||
|
||
# OS generated files | ||
Thumbs.db | ||
|
||
# Temporary files | ||
*.swp | ||
*.swo | ||
|
||
# Git related | ||
.git | ||
.gitignore | ||
|
||
# Docker related | ||
Dockerfile | ||
.dockerignore | ||
|
||
# Other | ||
README.md | ||
*.log |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"extends": "next/core-web-vitals" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. | ||
|
||
# dependencies | ||
/node_modules | ||
/.pnp | ||
.pnp.js | ||
.yarn/install-state.gz | ||
|
||
# testing | ||
/coverage | ||
|
||
# next.js | ||
/.next/ | ||
/out/ | ||
|
||
# production | ||
/build | ||
|
||
# misc | ||
.DS_Store | ||
*.pem | ||
|
||
# debug | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
|
||
# local env files | ||
.env*.local | ||
|
||
# vercel | ||
.vercel | ||
|
||
# typescript | ||
*.tsbuildinfo | ||
next-env.d.ts |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"plugins": ["prettier-plugin-tailwindcss"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# Copyright The OpenTelemetry Authors | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
FROM node:20 AS builder | ||
|
||
WORKDIR /app | ||
|
||
COPY ./src/flagd-ui/package*.json ./ | ||
|
||
RUN npm ci | ||
|
||
COPY ./src/flagd-ui/. ./ | ||
|
||
RUN npm run build | ||
|
||
# ----------------------------------------------------------------------------- | ||
|
||
FROM node:20-alpine | ||
|
||
WORKDIR /app | ||
|
||
COPY ./src/flagd-ui/package*.json ./ | ||
|
||
RUN npm ci --only=production | ||
|
||
COPY --from=builder /app/src/instrumentation.ts ./instrumentation.ts | ||
COPY --from=builder /app/next.config.mjs ./next.config.mjs | ||
|
||
COPY --from=builder /app/.next ./.next | ||
|
||
EXPOSE 4000 | ||
|
||
CMD ["npm", "start"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# Flagd-ui | ||
|
||
This application provides a user interface for configuring the feature | ||
flags of the flagd service. | ||
|
||
This is a [Next.js](https://nextjs.org/) project. | ||
|
||
## Running the application | ||
|
||
The application can be run with the rest of the demo using the documented | ||
docker compose or make commands. | ||
|
||
## Local development | ||
|
||
To run the app locally for development you must copy | ||
`src/flagd/demo.flagd.json` into `src/flagd-ui/data/demo.flagd.json` | ||
(create the directory and file if they do not exist yet). Make sure you're | ||
in the `src/flagd-ui` directory and run | ||
the following command: | ||
|
||
```bash | ||
npm run dev | ||
``` | ||
|
||
Then you must navigate to `localhost:4000/feature`. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
/** @type {import('next').NextConfig} */ | ||
const nextConfig = { | ||
experimental: { | ||
instrumentationHook: true, | ||
}, | ||
basePath: "/feature", | ||
}; | ||
|
||
export default nextConfig; |
Oops, something went wrong.