Skip to content

Commit 0ba0402

Browse files
committed
test
1 parent 7b17bb6 commit 0ba0402

File tree

3 files changed

+30
-1
lines changed

3 files changed

+30
-1
lines changed

.github/workflows/test.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Build release Docker Images
2+
3+
on:
4+
push:
5+
branches:
6+
- 'fraz/test-ymax-planner-build'
7+
8+
jobs:
9+
docker-ymax:
10+
runs-on: 'depot-ubuntu-latest'
11+
steps:
12+
- uses: actions/checkout@v4
13+
- uses: depot/setup-action@v1
14+
with:
15+
oidc: true # to set DEPOT_TOKEN for later steps
16+
- run: depot configure-docker
17+
- name: Build and Push ymax-planner
18+
uses: depot/build-push-action@v1
19+
id: build
20+
with:
21+
file: services/ymax-planner/Dockerfile
22+
context: ./
23+
platforms: ${{ env.DOCKER_PLATFORMS }}
24+
push: false
25+
tags: |
26+
${{ env.REGISTRY }}/agoric/agoric-sdk:ymax-planner-test

services/ymax-planner/Dockerfile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,9 @@ LABEL org.opencontainers.image.title="ymax-planner" \
4242
# Copy built application from builder stage
4343
COPY --from=builder /build/services/ymax-planner/dist/entrypoint.js /app/entrypoint.js
4444

45+
# Copy better-sqlite3 bindings
46+
COPY --from=builder /build/services/ymax-planner/build /build
47+
4548
# Copy built highs.wasm file from builder stage
4649
COPY --from=builder /build/node_modules/highs/build/highs.wasm /app/highs.wasm
4750

services/ymax-planner/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
"start:deps": "docker compose up --scale app=0",
1212
"dev": "nodemon --ext js,ts --exec 'node --import ts-blank-space/register ./src/entrypoint.ts '$@' || touch ./src/entrypoint.ts'",
1313
"debug": "node --inspect ./dist/entrypoint.js",
14-
"build": "yarn run codegen && yarn run -T run-s 'build:*'",
14+
"build": "yarn run codegen && yarn run -T run-s 'build:*' && yarn rebuild better-sqlite3 && mkdir -p ./build && cp -r ../../node_modules/better-sqlite3/build/Release/*.node ./build/",
1515
"build:esbuild": "node ./esbuild.config.mjs",
1616
"codegen": "ls -d ./src/graphql/api-* | xargs -n 1 yarn run graphql-dir-codegen",
1717
"graphql-dir-validate": "cd $0 && echo '#' $0 request-documents/*.graphql && graphql-inspector validate request-documents/*.graphql api.graphql",

0 commit comments

Comments
 (0)