Skip to content

Commit a84eded

Browse files
authored
Merge pull request #463 from it-at-m/langflow
MUCGPT 2.0
2 parents f9d69d5 + 1caa740 commit a84eded

File tree

343 files changed

+48983
-9404
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

343 files changed

+48983
-9404
lines changed

.devcontainer/devcontainer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"ghcr.io/devcontainers/features/azure-cli:1.2.7": {},
1414
"ghcr.io/devcontainers/features/node:1.6.3": {
1515
"nodeGypDependencies": false,
16-
"version": "22.17.1"
16+
"version": "22.18.0"
1717
},
1818
"ghcr.io/devcontainers/features/powershell:1.5.1": {}
1919
},
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
permissions:
2+
contents: read
3+
name: Frontend build test
4+
5+
on: [push, workflow_dispatch]
6+
7+
jobs:
8+
test_frontend:
9+
name: Test Frontend on ${{ matrix.os }} Node ${{ matrix.node_version }}
10+
runs-on: ${{ matrix.os }}
11+
strategy:
12+
fail-fast: false
13+
matrix:
14+
os: ["ubuntu-22.04"]
15+
node_version: ["20"]
16+
steps:
17+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
18+
- name: Setup node
19+
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
20+
with:
21+
node-version: ${{ matrix.node_version }}
22+
- name: Install dependencies
23+
run: |
24+
cd ./mucgpt-frontend
25+
npm install
26+
- name: Build frontend
27+
run: |
28+
cd ./mucgpt-frontend
29+
npm run build
Lines changed: 102 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,102 @@
1+
name: Deploy to GitHub Pages
2+
3+
on:
4+
push:
5+
tags:
6+
- "mucgpt-frontend-*" # Triggers only on mucgpt-frontend tags
7+
workflow_dispatch: # Allows manual triggering
8+
inputs:
9+
tag:
10+
description: "Frontend tag to deploy (e.g., mucgpt-frontend-1.0.0)"
11+
required: true
12+
default: "mucgpt-frontend-latest"
13+
14+
permissions:
15+
contents: write # Changed from read to write for gh-pages deployment
16+
pages: write
17+
id-token: write
18+
19+
concurrency:
20+
group: "pages"
21+
cancel-in-progress: false
22+
23+
jobs:
24+
build:
25+
runs-on: ubuntu-latest
26+
outputs:
27+
version: ${{ steps.vars.outputs.version }}
28+
full_tag: ${{ steps.vars.outputs.full_tag }}
29+
steps:
30+
- name: Checkout
31+
uses: actions/checkout@v4
32+
with:
33+
ref: ${{ github.ref }}
34+
35+
- name: Extract version from mucgpt-frontend tag
36+
id: vars
37+
run: |
38+
if [[ "${{ github.event_name }}" == "workflow_dispatch" ]]; then
39+
FULL_TAG="${{ github.event.inputs.tag }}"
40+
else
41+
FULL_TAG=${GITHUB_REF#refs/tags/}
42+
fi
43+
44+
# Extract version from mucgpt-frontend-* tag (e.g., mucgpt-frontend-1.0.0 -> 1.0.0)
45+
if [[ "$FULL_TAG" =~ ^mucgpt-frontend-(.+)$ ]]; then
46+
VERSION="${BASH_REMATCH[1]}"
47+
else
48+
echo "Error: Tag must start with 'mucgpt-frontend-'"
49+
exit 1
50+
fi
51+
52+
echo "full_tag=${FULL_TAG}" >> $GITHUB_OUTPUT
53+
echo "version=${VERSION}" >> $GITHUB_OUTPUT
54+
echo "Extracted version: ${VERSION} from tag: ${FULL_TAG}"
55+
56+
- name: Update version in package.json
57+
run: |
58+
cd mucgpt-frontend
59+
npm version ${{ steps.vars.outputs.version }} --no-git-tag-version
60+
echo "Updated package.json to version ${{ steps.vars.outputs.version }}"
61+
62+
- name: Setup Node.js
63+
uses: actions/setup-node@v4
64+
with:
65+
node-version: '20'
66+
cache: 'npm'
67+
cache-dependency-path: mucgpt-frontend/package-lock.json
68+
69+
- name: Install dependencies
70+
run: |
71+
cd mucgpt-frontend
72+
npm ci
73+
74+
- name: Build for GitHub Pages
75+
run: |
76+
cd mucgpt-frontend
77+
npm run build:ghpages
78+
79+
- name: Setup Pages
80+
uses: actions/configure-pages@v4
81+
82+
- name: Upload artifact
83+
uses: actions/upload-pages-artifact@v3
84+
with:
85+
path: './mucgpt-frontend/dist'
86+
87+
deploy:
88+
environment:
89+
name: github-pages
90+
url: ${{ steps.deployment.outputs.page_url }}
91+
runs-on: ubuntu-latest
92+
needs: build
93+
steps:
94+
- name: Deploy to GitHub Pages
95+
id: deployment
96+
uses: actions/deploy-pages@v4
97+
98+
- name: Display deployment info
99+
run: |
100+
echo "🚀 Deployed mucgpt-frontend version ${{ needs.build.outputs.version }}"
101+
echo "📦 From tag: ${{ needs.build.outputs.full_tag }}"
102+
echo "🌐 URL: ${{ steps.deployment.outputs.page_url }}"
Lines changed: 83 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,83 @@
1+
name: Build and Release Assistant Docker Image
2+
permissions:
3+
contents: read
4+
5+
on:
6+
push:
7+
tags:
8+
- "mucgpt-assistant-*" # Triggers only on mucgpt-assistant tags
9+
workflow_dispatch: # Allows manual triggering of the workflow
10+
inputs:
11+
tag:
12+
description: "Assistant tag to release (e.g., mucgpt-assistant-1.0.0)"
13+
required: true
14+
default: "mucgpt-assistant-latest"
15+
16+
jobs:
17+
build-and-push-assistant-service:
18+
runs-on: ubuntu-latest
19+
permissions:
20+
actions: write
21+
packages: write
22+
steps:
23+
- name: Harden the runner (Audit all outbound calls)
24+
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
25+
with:
26+
egress-policy: audit
27+
- name: Checkout code
28+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
29+
- name: Set up QEMU
30+
uses: docker/setup-qemu-action@29109295f81e9208d7d86ff1c6c12d2833863392 # v3.6.0
31+
- name: Set up Docker Buildx
32+
uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1
33+
- name: Log in to GitHub Container Registry
34+
uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4.0
35+
with:
36+
registry: ghcr.io
37+
username: ${{ github.actor }}
38+
password: ${{ secrets.GITHUB_TOKEN }}
39+
- name: Extract version from mucgpt-assistant tag
40+
id: vars
41+
run: |
42+
if [[ "${{ github.event_name }}" == "workflow_dispatch" ]]; then
43+
FULL_TAG="${{ github.event.inputs.tag }}"
44+
else
45+
FULL_TAG=${GITHUB_REF#refs/tags/}
46+
fi
47+
48+
# Extract version from mucgpt-assistant-* tag (e.g., mucgpt-assistant-1.0.0 -> 1.0.0)
49+
if [[ "$FULL_TAG" =~ ^mucgpt-assistant-(.+)$ ]]; then
50+
VERSION="${BASH_REMATCH[1]}"
51+
else
52+
echo "Error: Tag must start with 'mucgpt-assistant-'"
53+
exit 1
54+
fi
55+
56+
echo "full_tag=${FULL_TAG}" >> $GITHUB_OUTPUT
57+
echo "version=${VERSION}" >> $GITHUB_OUTPUT
58+
echo "repo_lowercase=$(echo '${{ github.repository }}' | tr '[:upper:]' '[:lower:]')" >> $GITHUB_OUTPUT
59+
- name: Set build timestamp
60+
id: build_ts
61+
run: echo "BUILD_TS=$(date -u +%Y-%m-%dT%H:%M:%SZ)" >> "$GITHUB_ENV"
62+
- name: Build and push mucgpt-assistant Docker image
63+
uses: docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83 # v6.18.0
64+
with:
65+
context: ./mucgpt-assistant-service
66+
file: ./mucgpt-assistant-service/Dockerfile
67+
push: true
68+
sbom: true
69+
provenance: true
70+
tags: |
71+
ghcr.io/${{ steps.vars.outputs.repo_lowercase }}/mucgpt-assistant:${{ steps.vars.outputs.version }}
72+
ghcr.io/${{ steps.vars.outputs.repo_lowercase }}/mucgpt-assistant:latest
73+
cache-from: type=gha
74+
cache-to: type=gha,mode=max
75+
build-args: |
76+
IMAGE_CREATED=${{ github.event.repository.pushed_at || env.BUILD_TS }}
77+
IMAGE_REVISION=${{ github.sha }}
78+
IMAGE_VERSION=${{ steps.vars.outputs.version }}
79+
- name: Image digest
80+
run: |
81+
echo "mucgpt-assistant image built and pushed:"
82+
echo " ghcr.io/${{ github.repository }}/mucgpt-assistant:${{ steps.vars.outputs.version }}"
83+
echo " ghcr.io/${{ github.repository }}/mucgpt-assistant:latest"
Lines changed: 83 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,83 @@
1+
name: Build and Release Core Docker Image
2+
permissions:
3+
contents: read
4+
5+
on:
6+
push:
7+
tags:
8+
- "mucgpt-core-*" # Triggers only on mucgpt-core tags
9+
workflow_dispatch: # Allows manual triggering of the workflow
10+
inputs:
11+
tag:
12+
description: "Core tag to release (e.g., mucgpt-core-1.0.0)"
13+
required: true
14+
default: "mucgpt-core-latest"
15+
16+
jobs:
17+
build-and-push-core-service:
18+
runs-on: ubuntu-latest
19+
permissions:
20+
actions: write
21+
packages: write
22+
steps:
23+
- name: Harden the runner (Audit all outbound calls)
24+
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
25+
with:
26+
egress-policy: audit
27+
- name: Checkout code
28+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
29+
- name: Set up QEMU
30+
uses: docker/setup-qemu-action@29109295f81e9208d7d86ff1c6c12d2833863392 # v3.6.0
31+
- name: Set up Docker Buildx
32+
uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1
33+
- name: Log in to GitHub Container Registry
34+
uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4.0
35+
with:
36+
registry: ghcr.io
37+
username: ${{ github.actor }}
38+
password: ${{ secrets.GITHUB_TOKEN }}
39+
- name: Extract version from mucgpt-core tag
40+
id: vars
41+
run: |
42+
if [[ "${{ github.event_name }}" == "workflow_dispatch" ]]; then
43+
FULL_TAG="${{ github.event.inputs.tag }}"
44+
else
45+
FULL_TAG=${GITHUB_REF#refs/tags/}
46+
fi
47+
48+
# Extract version from mucgpt-core-* tag (e.g., mucgpt-core-1.0.0 -> 1.0.0)
49+
if [[ "$FULL_TAG" =~ ^mucgpt-core-(.+)$ ]]; then
50+
VERSION="${BASH_REMATCH[1]}"
51+
else
52+
echo "Error: Tag must start with 'mucgpt-core-'"
53+
exit 1
54+
fi
55+
56+
echo "full_tag=${FULL_TAG}" >> $GITHUB_OUTPUT
57+
echo "version=${VERSION}" >> $GITHUB_OUTPUT
58+
echo "repo_lowercase=$(echo '${{ github.repository }}' | tr '[:upper:]' '[:lower:]')" >> $GITHUB_OUTPUT
59+
- name: Set build timestamp
60+
id: build_ts
61+
run: echo "BUILD_TS=$(date -u +%Y-%m-%dT%H:%M:%SZ)" >> "$GITHUB_ENV"
62+
- name: Build and push mucgpt-core Docker image
63+
uses: docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83 # v6.18.0
64+
with:
65+
context: ./mucgpt-core-service
66+
file: ./mucgpt-core-service/Dockerfile
67+
push: true
68+
sbom: true
69+
provenance: true
70+
tags: |
71+
ghcr.io/${{ steps.vars.outputs.repo_lowercase }}/mucgpt-core:${{ steps.vars.outputs.version }}
72+
ghcr.io/${{ steps.vars.outputs.repo_lowercase }}/mucgpt-core:latest
73+
cache-from: type=gha
74+
cache-to: type=gha,mode=max
75+
build-args: |
76+
IMAGE_CREATED=${{ github.event.repository.pushed_at || env.BUILD_TS }}
77+
IMAGE_REVISION=${{ github.sha }}
78+
IMAGE_VERSION=${{ steps.vars.outputs.version }}
79+
- name: Image digest
80+
run: |
81+
echo "mucgpt-core image built and pushed:"
82+
echo " ghcr.io/${{ github.repository }}/mucgpt-core:${{ steps.vars.outputs.version }}"
83+
echo " ghcr.io/${{ github.repository }}/mucgpt-core:latest"
Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
name: Build and Release Frontend Docker Image
2+
3+
permissions:
4+
contents: read
5+
6+
on:
7+
push:
8+
tags:
9+
- "mucgpt-frontend-*" # Triggers only on mucgpt-frontend tags
10+
workflow_dispatch: # Allows manual triggering of the workflow
11+
inputs:
12+
tag:
13+
description: "Frontend tag to release (e.g., mucgpt-frontend-1.0.0)"
14+
required: true
15+
default: "mucgpt-frontend-latest"
16+
17+
jobs:
18+
build-and-push-frontend:
19+
runs-on: ubuntu-latest
20+
permissions:
21+
actions: write
22+
packages: write
23+
steps:
24+
- name: Harden the runner (Audit all outbound calls)
25+
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
26+
with:
27+
egress-policy: audit
28+
- name: Checkout code
29+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
30+
- name: Set up QEMU
31+
uses: docker/setup-qemu-action@29109295f81e9208d7d86ff1c6c12d2833863392 # v3.6.0
32+
- name: Set up Docker Buildx
33+
uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1
34+
- name: Log in to GitHub Container Registry
35+
uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4.0
36+
with:
37+
registry: ghcr.io
38+
username: ${{ github.actor }}
39+
password: ${{ secrets.GITHUB_TOKEN }}
40+
- name: Extract version from mucgpt-frontend tag
41+
id: vars
42+
run: |
43+
if [[ "${{ github.event_name }}" == "workflow_dispatch" ]]; then
44+
FULL_TAG="${{ github.event.inputs.tag }}"
45+
else
46+
FULL_TAG=${GITHUB_REF#refs/tags/}
47+
fi
48+
49+
# Extract version from mucgpt-frontend-* tag (e.g., mucgpt-frontend-1.0.0 -> 1.0.0)
50+
if [[ "$FULL_TAG" =~ ^mucgpt-frontend-(.+)$ ]]; then
51+
VERSION="${BASH_REMATCH[1]}"
52+
else
53+
echo "Error: Tag must start with 'mucgpt-frontend-'"
54+
exit 1
55+
fi
56+
57+
echo "full_tag=${FULL_TAG}" >> $GITHUB_OUTPUT
58+
echo "version=${VERSION}" >> $GITHUB_OUTPUT
59+
echo "repo_lowercase=$(echo '${{ github.repository }}' | tr '[:upper:]' '[:lower:]')" >> $GITHUB_OUTPUT
60+
- name: Set build timestamp
61+
id: build_ts
62+
run: echo "BUILD_TS=$(date -u +%Y-%m-%dT%H:%M:%SZ)" >> "$GITHUB_ENV"
63+
- name: Build and push mucgpt-frontend Docker image
64+
uses: docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83 # v6.18.0
65+
with:
66+
context: ./mucgpt-frontend
67+
file: ./mucgpt-frontend/Dockerfile
68+
push: true
69+
sbom: true
70+
provenance: true
71+
tags: |
72+
ghcr.io/${{ steps.vars.outputs.repo_lowercase }}/mucgpt-frontend:${{ steps.vars.outputs.version }}
73+
ghcr.io/${{ steps.vars.outputs.repo_lowercase }}/mucgpt-frontend:latest
74+
cache-from: type=gha
75+
cache-to: type=gha,mode=max
76+
build-args: |
77+
IMAGE_CREATED=${{ github.event.repository.pushed_at || env.BUILD_TS }}
78+
IMAGE_REVISION=${{ github.sha }}
79+
IMAGE_VERSION=${{ steps.vars.outputs.version }}
80+
- name: Image digest
81+
run: |
82+
echo "mucgpt-frontend image built and pushed:"
83+
echo " ghcr.io/${{ github.repository }}/mucgpt-frontend:${{ steps.vars.outputs.version }}"
84+
echo " ghcr.io/${{ github.repository }}/mucgpt-frontend:latest"

0 commit comments

Comments
 (0)