Skip to content

Commit 5c7d5ee

Browse files
authored
Merge pull request #11 from maevsi/beta
ci(release)!: v2
2 parents 1d09287 + e2da9a9 commit 5c7d5ee

20 files changed

Lines changed: 3639 additions & 12 deletions

.dockerignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
node_modules
2+
.eslintcache

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
node_modules
2+
.eslintcache

.prettierrc.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"semi": false,
3+
"singleQuote": true
4+
}

.releaserc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
}
1616
],
1717
"@semantic-release/changelog",
18+
"@semantic-release/npm",
1819
"@semantic-release/github",
1920
"@semantic-release/git"
2021
],

.renovaterc.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
{
22
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
3-
"extends": ["github>dargmuesli/renovate-config"],
4-
"semanticCommitType": "fix"
3+
"extends": ["github>dargmuesli/renovate-config"]
54
}

.vscode/extensions.json

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
11
{
2-
"recommendations": ["editorconfig.editorconfig"]
2+
"recommendations": [
3+
"dbaeumer.vscode-eslint",
4+
"editorconfig.editorconfig",
5+
"esbenp.prettier-vscode",
6+
"timonwong.shellcheck"
7+
]
38
}

.vscode/settings.json

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,4 @@
11
{
2-
"[json]": {
3-
"editor.defaultFormatter": "esbenp.prettier-vscode"
4-
},
5-
"[jsonc]": {
6-
"editor.defaultFormatter": "esbenp.prettier-vscode"
7-
}
2+
"editor.defaultFormatter": "esbenp.prettier-vscode",
3+
"shellcheck.customArgs": ["-x"]
84
}

AGENTS.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
---
2+
applyTo: '**'
3+
---
4+
# Project Instructions
5+
This project is a PostGraphile v5 server that converts PostgreSQL schemas into a GraphQL API. It defines one of many services of `vibetype`, an event community platform. The PostgreSQL schemas used by this service are applied as SQL migrations by the `sqitch` service.
6+
7+
## Files
8+
- `src/graphile.config.ts` contains the main PostGraphile configuration.
9+
- `src/graphile.ts` contains scripted logic.
10+
- `src/environment.ts` contains type-safe environment variable utilities.
11+
12+
## JWT
13+
- Algorithm: ES256
14+
- Audience, issuer: postgraphile
15+
- PostgreSQL composite type: `vibetype.jwt`
16+
17+
## Workflow
18+
- Lint with `pnpm run lint`.
19+
20+
## General
21+
- Code style
22+
- Sort any elements (imports, object properties, functions, ...), e.g. alphabetically, except when it doesn't make sense.
23+
- Agents
24+
- After making changes to the codebase, ensure AGENTS.md is in sync with your knowledge of the project.

CHANGELOG.md

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,67 @@
1+
## [2.0.0-beta.9](https://github.com/maevsi/postgraphile/compare/2.0.0-beta.8...2.0.0-beta.9) (2026-04-02)
2+
3+
### Features
4+
5+
* **package:** update description ([8ca4eae](https://github.com/maevsi/postgraphile/commit/8ca4eae7077cb47685c8bb0386e8461102b94232))
6+
7+
## [2.0.0-beta.8](https://github.com/maevsi/postgraphile/compare/2.0.0-beta.7...2.0.0-beta.8) (2026-04-02)
8+
9+
### Bug Fixes
10+
11+
* **ci:** update package version ([2cee61d](https://github.com/maevsi/postgraphile/commit/2cee61d162d4be6d14cfe218c013c464f8fe05a8))
12+
* **docker:** streamline entrypoint ([652fd00](https://github.com/maevsi/postgraphile/commit/652fd00895437de3f8be89c025d49381ee356854))
13+
14+
## [2.0.0-beta.7](https://github.com/maevsi/postgraphile/compare/2.0.0-beta.6...2.0.0-beta.7) (2026-04-02)
15+
16+
### Bug Fixes
17+
18+
* schedule release ([65f684f](https://github.com/maevsi/postgraphile/commit/65f684f7db2e3997f68dba3ff36f5b4eb82430f3))
19+
* schedule release ([5f7b799](https://github.com/maevsi/postgraphile/commit/5f7b79993efba96442d7aad7f5e09ca63043e63f))
20+
21+
## [2.0.0-beta.6](https://github.com/maevsi/postgraphile/compare/2.0.0-beta.5...2.0.0-beta.6) (2026-03-14)
22+
23+
### ⚠ BREAKING CHANGES
24+
25+
* **jwt:** use ecdsa key
26+
27+
### Features
28+
29+
* **jwt:** use ecdsa key ([65b70d1](https://github.com/maevsi/postgraphile/commit/65b70d1365b8f5871042fc8e562d09b234116408))
30+
31+
## [2.0.0-beta.5](https://github.com/maevsi/postgraphile/compare/2.0.0-beta.4...2.0.0-beta.5) (2026-03-14)
32+
33+
### Bug Fixes
34+
35+
* **deps:** update postgraphile ([b84ee8c](https://github.com/maevsi/postgraphile/commit/b84ee8cce462bf0573408fc436163934715ae71b))
36+
37+
## [2.0.0-beta.4](https://github.com/maevsi/postgraphile/compare/2.0.0-beta.3...2.0.0-beta.4) (2026-02-26)
38+
39+
### Bug Fixes
40+
41+
* **grafast:** correct context claim value encoding ([369cfe9](https://github.com/maevsi/postgraphile/commit/369cfe9981f87fc85e14f2496af13c94877c6592))
42+
43+
## [2.0.0-beta.3](https://github.com/maevsi/postgraphile/compare/2.0.0-beta.2...2.0.0-beta.3) (2026-02-24)
44+
45+
### Bug Fixes
46+
47+
* **postgis:** update plugin with geojson/srid fix ([59bf0c5](https://github.com/maevsi/postgraphile/commit/59bf0c5415e07617160475d8398e25ecd4d3f2e7))
48+
49+
## [2.0.0-beta.2](https://github.com/maevsi/postgraphile/compare/2.0.0-beta.1...2.0.0-beta.2) (2026-02-20)
50+
51+
### Bug Fixes
52+
53+
* **postgres:** readd connection string ([f3f7d82](https://github.com/maevsi/postgraphile/commit/f3f7d82cbf2dc363c76b2f2c198e2015746dc6f5))
54+
55+
## [2.0.0-beta.1](https://github.com/maevsi/postgraphile/compare/1.0.19...2.0.0-beta.1) (2026-02-20)
56+
57+
### ⚠ BREAKING CHANGES
58+
59+
* **postgraphile:** upgrade to v5
60+
61+
### Features
62+
63+
* **postgraphile:** upgrade to v5 ([892c80b](https://github.com/maevsi/postgraphile/commit/892c80bde0d35725a01f204f87fd8d78159682b8))
64+
165
## [1.0.21](https://github.com/maevsi/postgraphile/compare/1.0.20...1.0.21) (2026-03-26)
266

367
### Bug Fixes

Dockerfile

Lines changed: 97 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,98 @@
1-
FROM graphile/postgraphile:4.14.1 AS development
1+
# syntax=docker/dockerfile:1
22

3-
RUN yarn add @graphile/postgis
3+
# <DEPENDENCIES>
4+
FROM ghcr.io/maevsi/sqitch:11.0.0-beta.1
5+
# </DEPENDENCIES>
6+
7+
########################
8+
# Create base.
9+
10+
FROM node:24.13.1-alpine AS base
11+
12+
# The `CI` environment variable must be set for pnpm to run in headless mode
13+
ENV CI=true
14+
15+
WORKDIR /srv/app/
16+
17+
RUN corepack enable
18+
19+
20+
########################
21+
# Serve development.
22+
23+
FROM base AS development
24+
25+
ENV GRAPHILE_ENV=development
26+
27+
RUN mkdir \
28+
/srv/.pnpm-store \
29+
/srv/app/node_modules \
30+
&& chown node:node \
31+
/srv/.pnpm-store \
32+
/srv/app/node_modules
33+
VOLUME /srv/.pnpm-store
34+
VOLUME /srv/app
35+
VOLUME /srv/app/node_modules
36+
37+
USER node
38+
ENTRYPOINT ["/srv/app/docker-entrypoint.sh"]
39+
CMD ["pnpm", "exec", "postgraphile", "--config", "./src/graphile.config.ts", "-n", "0.0.0.0"]
40+
EXPOSE 5678
41+
HEALTHCHECK --interval=30s --timeout=5s --start-period=10s --retries=3 CMD wget -q --spider http://127.0.0.1:5678/ || exit 1
42+
43+
44+
########################
45+
# Prepare environment.
46+
47+
FROM base AS prepare
48+
49+
COPY ./pnpm-lock.yaml ./package.json ./graphile-postgis-v0.2.0.tgz ./
50+
51+
RUN --mount=type=cache,id=pnpm-store,target=/root/.local/share/pnpm/store \
52+
pnpm fetch
53+
54+
COPY ./ ./
55+
56+
RUN pnpm install --offline
57+
58+
59+
########################
60+
# Lint code.
61+
62+
FROM prepare AS lint
63+
64+
RUN pnpm run lint
65+
66+
67+
########################
68+
# Build for production.
69+
70+
FROM prepare AS build
71+
72+
RUN pnpm install --offline --prod
73+
74+
75+
########################
76+
# Collect results.
77+
78+
FROM base AS collect
79+
80+
COPY --from=prepare /srv/app/src ./src
81+
COPY --from=prepare /srv/app/docker-entrypoint.sh /srv/app/package.json ./
82+
COPY --from=build /srv/app/node_modules ./node_modules
83+
COPY --from=lint /srv/app/package.json /dev/null
84+
85+
86+
########################
87+
# Serve production.
88+
89+
FROM collect AS production
90+
91+
ENV NODE_ENV=production
92+
93+
USER node
94+
ENTRYPOINT ["/srv/app/docker-entrypoint.sh"]
95+
CMD ["pnpm", "exec", "postgraphile", "--config", "./src/graphile.config.ts", "-n", "0.0.0.0"]
96+
EXPOSE 5678
97+
HEALTHCHECK --interval=30s --timeout=5s --start-period=10s --retries=3 CMD wget -q --spider http://127.0.0.1:5678/ || exit 1
98+
LABEL org.opencontainers.image.description="PostGraphile GraphQL API for the Vibetype platform; includes @graphile/postgis, Amber preset, Grafast optimizations, and JWT authentication."

0 commit comments

Comments
 (0)