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
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ RUN case "${TARGETARCH}" in \
# Pinned to the latest upstream release. Bump WISP_VERSION and WISP_COMMIT to
# update (see UPDATING.md). WISP_COMMIT is the immutable commit the tag points
# to; the guard below fails the build if the tag is ever re-pointed.
ARG WISP_VERSION=v0.5.0
ARG WISP_COMMIT=fa14e1f259406b6e3560ba2ddca48645098b9525
ARG WISP_VERSION=v0.5.1
ARG WISP_COMMIT=5d5d2fdf8d63e1c484c864cb0aaccf91935d3196
RUN git clone --branch ${WISP_VERSION} --depth 1 https://github.com/privkeyio/wisp.git /src && \
HEAD_SHA="$(git -C /src rev-parse HEAD)" && \
if [ "${HEAD_SHA}" != "${WISP_COMMIT}" ]; then \
Expand Down
19 changes: 16 additions & 3 deletions startos/init/seedFiles.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,21 @@
import { sdk } from '../sdk'
import { wispToml } from '../fileModels/wisp.toml'

// Seed wisp.toml on every init so new schema defaults (fixed host/port/storage)
// are written on install and applied on upgrade.
// Seed wisp.toml on every init so schema defaults (fixed host/port/storage) are
// written on install and applied on upgrade.
//
// Behind the StartOS reverse proxy every client shares the proxy's source IP, so
// wisp's per-IP connection limit (default 10) would cap the entire relay at 10
// connections internet-wide. Like nostr-rs-relay and strfry on StartOS, this
// package does not limit by IP: global max_connections plus the event and query
// rate limits provide abuse protection. We seed a high per-IP value only when the
// operator has not set one, so the Limits action still wins on later runs. (0 is
// not "unlimited" in wisp, it rejects every connection, so we use a large number.)
export const seedFiles = sdk.setupOnInit(async (effects) => {
await wispToml.merge(effects, {})
const current = await wispToml.read().once()
const seedPerIp = current?.security?.max_connections_per_ip === undefined
await wispToml.merge(
effects,
seedPerIp ? { security: { max_connections_per_ip: 100000 } } : {},
)
})
4 changes: 2 additions & 2 deletions startos/versions/current.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import { IMPOSSIBLE, VersionInfo } from '@start9labs/start-sdk'

export const current = VersionInfo.of({
version: '0.5.0:0',
version: '0.5.1:0',
releaseNotes: {
en_US:
'Updates wisp to v0.5.0: crash-safe storage by default. Writes are now durable so the database no longer risks corruption on power loss, using a group-commit writer that batches writes so durability scales with load. Durability stays configurable for operators who want maximum throughput.',
'Updates wisp to v0.5.1 with crash-safe storage by default (durable writes that no longer risk corruption on power loss). Fixes Spider freezing your feed: productive but short-lived upstream connections no longer escalate into multi-hour reconnect blackouts. Also fixes the relay being capped at 10 connections behind the StartOS reverse proxy by no longer limiting connections per IP, matching how nostr-rs-relay and strfry are packaged.',
},
migrations: {
up: async ({ effects }) => {},
Expand Down
Loading