Skip to content

Commit

Permalink
Merge pull request #1597 from quadratichq/qa
Browse files Browse the repository at this point in the history
QA - Week of July 22
  • Loading branch information
davidkircos authored Jul 26, 2024
2 parents 4759125 + 4d89e4f commit 1e19fc2
Show file tree
Hide file tree
Showing 73 changed files with 2,037 additions and 276 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/qa-wolf-notify.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: QA Wolf Notify

on:
push:
branches:
- qa

jobs:
qa-wolf-notify:
runs-on: ubuntu-latest
concurrency:
group: qa-wolf-notify
cancel-in-progress: true
steps:
- uses: actions/checkout@v1

- name: Wait for 15 minutes
run: sleep 900

- name: Notify deploy_success
id: run_tests
run: |
curl -H "Authorization: ${{ secrets.QAW_API_KEY }}" \
-H 'Content-Type: application/json' \
-d '{"branch": "qa", "deployment_type": "new_qa", "commit_url": "https://github.com/quadratichq/quadratic/commit/${{ github.sha }}", "sha": "${{ github.sha }}"}' \
https://app.qawolf.com/api/webhooks/deploy_success
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ _Quadratic is in Beta._
- [x] Charts and graphs
- [x] Teams support
- [x] JavaScript support
- [ ] SQL database support
- [x] SQL database support (Postgres, MySQL)
- [ ] Data warehouse support (Snowflake, DataBricks, etc)
- [ ] Self-host on your infrastructure

Expand Down
58 changes: 58 additions & 0 deletions client.Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
# Use an official node image as a parent image
FROM node:18 AS build

# Install rustup
RUN echo 'Installing rustup...' && curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
ENV PATH="/root/.cargo/bin:${PATH}"

# Install wasm-pack
RUN echo 'Installing wasm-pack...' && curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh

# Install python
RUN apt-get update || : && apt-get install python-is-python3 -y && apt install python3-pip -y

# Install binaryen
RUN apt install binaryen -y

# Copy the rest of the application code
WORKDIR /app

COPY package.json .
COPY package-lock.json .
COPY updateAlertVersion.json .
COPY ./quadratic-client/. ./quadratic-client/
COPY ./quadratic-core/. ./quadratic-core/
COPY ./quadratic-kernels/python-wasm/. ./quadratic-kernels/python-wasm/
COPY ./quadratic-rust-client/. ./quadratic-rust-client/
COPY ./quadratic-shared/. ./quadratic-shared/

# Run the packaging script for quadratic_py
RUN ./quadratic-kernels/python-wasm/package.sh --no-poetry

# Build wasm
WORKDIR /app/quadratic-core
RUN rustup target add wasm32-unknown-unknown
RUN echo 'Building wasm...' && wasm-pack build --target web --out-dir ../quadratic-client/src/app/quadratic-core --weak-refs

# Export TS/Rust types
RUN echo 'Exporting TS/Rust types...' && cargo run --bin export_types

# Build the quadratic-rust-client
WORKDIR /app
ARG GIT_COMMIT
ENV GIT_COMMIT=$GIT_COMMIT
RUN echo 'Building quadratic-rust-client...' && npm run build --workspace=quadratic-rust-client

# Build the front-end
WORKDIR /app
RUN echo 'Building front-end...'
RUN npm ci
RUN npx tsc ./quadratic-shared/*.ts
RUN npm run build --workspace=quadratic-client

FROM nginx:stable-alpine
COPY --from=build /app/build /usr/share/nginx/html

EXPOSE 80 443 3000

CMD ["nginx", "-g", "daemon off;"]
Loading

0 comments on commit 1e19fc2

Please sign in to comment.