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
9 changes: 8 additions & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
target
data
staging
staging
frontend/node_modules
frontend/dist
frontend/build.zip
frontend/build.zip.sha1
frontend/playwright-report
frontend/test-results
frontend/storybook-static
1 change: 1 addition & 0 deletions .github/workflows/build-push-edge-debug.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ jobs:
- name: Clean up builder cache
run: docker builder prune -f

# The Dockerfile builds frontend/ with Node 24 before embedding it in Rust.
- name: Build and push
uses: docker/build-push-action@v6
with:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/build-push-edge-kafka.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ jobs:
- name: Clean up builder cache
run: docker builder prune -f

# The Dockerfile builds frontend/ with Node 24 before embedding it in Rust.
- name: Build and push x86_64
uses: docker/build-push-action@v6
with:
Expand All @@ -52,6 +53,7 @@ jobs:
build-args: |
LIB_DIR=x86_64-linux-gnu

# The Dockerfile builds frontend/ with Node 24 before embedding it in Rust.
- name: Build and push aarch64
uses: docker/build-push-action@v6
with:
Expand All @@ -61,4 +63,4 @@ jobs:
tags: quay.io/parseablehq/parseable:edge-kafka-arm64
platforms: linux/arm64
build-args: |
LIB_DIR=aarch64-linux-gnu
LIB_DIR=aarch64-linux-gnu
1 change: 1 addition & 0 deletions .github/workflows/build-push-edge.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ jobs:
- name: Clean up builder cache
run: docker builder prune -f

# The Dockerfile builds frontend/ with Node 24 before embedding it in Rust.
- name: Build and push
uses: docker/build-push-action@v6
with:
Expand Down
39 changes: 38 additions & 1 deletion .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ on:
- assets/**
- "**.md"

# Cross preserves this absolute workspace path inside its build container.
env:
NEXT_ASSETS_PATH: ${{ github.workspace }}/frontend/dist

jobs:
# Default build without Kafka
build-default:
Expand Down Expand Up @@ -38,6 +42,17 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '24'
cache: npm
cache-dependency-path: frontend/package-lock.json

- name: Build frontend
working-directory: frontend
run: npm ci && npm run build

- name: Setup Rust toolchain
uses: dtolnay/rust-toolchain@stable
with:
Expand All @@ -51,7 +66,7 @@ jobs:

- name: Install cross
if: matrix.use_cross
run: cargo install cross --git https://github.com/cross-rs/cross
run: cargo install cross --git https://github.com/cross-rs/cross --locked

- name: Cache dependencies
uses: actions/cache@v4
Expand Down Expand Up @@ -82,6 +97,17 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '24'
cache: npm
cache-dependency-path: frontend/package-lock.json

- name: Build frontend
working-directory: frontend
run: npm ci && npm run build

- name: Install Linux dependencies
run: |
sudo apt-get update
Expand Down Expand Up @@ -144,6 +170,17 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '24'
cache: npm
cache-dependency-path: frontend/package-lock.json

- name: Build frontend
working-directory: frontend
run: npm ci && npm run build

- name: Install macOS dependencies
run: |
brew install \
Expand Down
15 changes: 15 additions & 0 deletions .github/workflows/coverage.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ on:
- "**.md"

name: Lint, Test and Coverage Report
# Cross preserves this absolute workspace path inside its build container.
env:
NEXT_ASSETS_PATH: ${{ github.workspace }}/frontend/dist

jobs:
community-ui:
runs-on: ubuntu-latest
Expand All @@ -22,6 +26,17 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '24'
cache: npm
cache-dependency-path: frontend/package-lock.json

- name: Build frontend
working-directory: frontend
run: npm ci && npm run build
- uses: dtolnay/rust-toolchain@stable
with:
components: clippy
Expand Down
40 changes: 40 additions & 0 deletions .github/workflows/frontend.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: Frontend
on:
pull_request:
paths: ['frontend/**', 'build.rs', '.github/workflows/frontend.yaml']
push:
paths: ['frontend/**', 'build.rs', '.github/workflows/frontend.yaml']
permissions:
contents: read
jobs:
frontend:
runs-on: ubuntu-latest
defaults:
run:
working-directory: frontend
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '24'
cache: npm
cache-dependency-path: frontend/package-lock.json
- run: npm ci && npm run build
- run: npm run package
- name: Upload frontend package
uses: actions/upload-artifact@v4
with:
name: parseable-frontend
path: |
frontend/build.zip
frontend/build.zip.sha1
if-no-files-found: error
- run: npx playwright install --with-deps chromium
- run: npm run check
Comment thread
VibeSWE marked this conversation as resolved.
- uses: actions/upload-artifact@v4
if: failure()
with:
name: frontend-browser-results
path: |
frontend/playwright-report
frontend/test-results
119 changes: 114 additions & 5 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,54 @@ on:
- "assets/**"
- "**.md"

# Cross preserves this absolute workspace path inside its build container.
env:
NEXT_ASSETS_PATH: ${{ github.workspace }}/frontend/dist

jobs:
build-frontend:
name: Package frontend
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '24'
cache: npm
cache-dependency-path: frontend/package-lock.json

- name: Build frontend
working-directory: frontend
run: npm ci && npm run build

- name: Package frontend
working-directory: frontend
run: npm run package

- name: Upload frontend artifact
uses: actions/upload-artifact@v4
with:
name: parseable-frontend
path: |
frontend/build.zip
frontend/build.zip.sha1
if-no-files-found: error

- name: Attach frontend to release
uses: softprops/action-gh-release@v0.1.15
with:
draft: false
files: |
frontend/build.zip
frontend/build.zip.sha1
fail_on_unmatched_files: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

build-linux:
name: Build for ${{matrix.target}}
runs-on: self-hosted
Expand All @@ -35,18 +82,36 @@ jobs:
use-cross: true
steps:
- uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '24'
cache: npm
cache-dependency-path: frontend/package-lock.json

- name: Build frontend
working-directory: frontend
run: npm ci && npm run build

- uses: actions-rs/toolchain@v1
with:
toolchain: stable
profile: minimal # minimal component installation (ie, no documentation)
target: ${{matrix.target}}
override: true

- uses: actions-rs/cargo@v1
with:
use-cross: ${{ matrix.use-cross }}
command: build
args: --profile release-lto --target ${{matrix.target}}
- name: Install cross
if: matrix.use-cross
run: cargo install cross --git https://github.com/cross-rs/cross --locked

- name: Build with cross
if: matrix.use-cross
run: cross build --profile release-lto --target ${{ matrix.target }}

- name: Build native
if: ${{ !matrix.use-cross }}
run: cargo build --profile release-lto --target ${{ matrix.target }}

- name: Rename binary
run: |
Expand Down Expand Up @@ -82,6 +147,17 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '24'
cache: npm
cache-dependency-path: frontend/package-lock.json

- name: Build frontend
working-directory: frontend
run: npm ci && npm run build

- name: Install latest rust toolchain
uses: actions-rs/toolchain@v1
with:
Expand Down Expand Up @@ -132,6 +208,17 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '24'
cache: npm
cache-dependency-path: frontend/package-lock.json

- name: Build frontend
working-directory: frontend
run: npm ci && npm run build

- name: Install latest rust toolchain
uses: actions-rs/toolchain@v1
with:
Expand Down Expand Up @@ -180,6 +267,17 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '24'
cache: npm
cache-dependency-path: frontend/package-lock.json

- name: Build frontend
working-directory: frontend
run: npm ci && npm run build

- name: Install Linux dependencies
run: |
sudo apt-get update
Expand Down Expand Up @@ -259,6 +357,17 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '24'
cache: npm
cache-dependency-path: frontend/package-lock.json

- name: Build frontend
working-directory: frontend
run: npm ci && npm run build

- name: Install macOS dependencies
run: |
brew install \
Expand Down
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,7 @@ parseable_*
parseable-env-secret
cache
.idea

# Local credentials and review notes
*.pem
pr-*.md
6 changes: 5 additions & 1 deletion Cross.toml
Original file line number Diff line number Diff line change
@@ -1,2 +1,6 @@
[build.env]
# Cross mounts the workspace at its original absolute path inside the container.
passthrough = ["NEXT_ASSETS_PATH"]

[target.aarch64-unknown-linux-gnu]
image = "ghcr.io/cross-rs/aarch64-unknown-linux-gnu@sha256:1e2a0291f92a4372cbc22d8994e735473045383f1ce7fa44a16c234ba00187f4"
image = "ghcr.io/cross-rs/aarch64-unknown-linux-gnu@sha256:1e2a0291f92a4372cbc22d8994e735473045383f1ce7fa44a16c234ba00187f4"
Loading
Loading