diff --git a/docker-compose.yml b/docker-compose.yml index da0aa90..34d082b 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -3,7 +3,13 @@ name: podsteadr services: podsteadr: build: . - container_name: podsteadr + # Container/DNS-alias name deliberately NOT "podsteadr" — on hosts whose own hostname is + # "podsteadr" (e.g. a VPS named after the app), the host's own /etc/hosts self-hostname + # entry (127.0.1.1 podsteadr, added by cloud-init) shadows the container network's DNS + # alias for other containers looking up "podsteadr", so mediamtx's auth-webhook callback + # resolved to the host's loopback instead of this container and every RTMP publish got + # rejected with "connection refused" (observed on podsteadr.atobitcoin.io, 2026-07-30). + container_name: podsteadr-app restart: unless-stopped ports: - "8095:8095" diff --git a/frontend/src/components/EpisodeSources.vue b/frontend/src/components/EpisodeSources.vue index a4ff581..9982332 100644 --- a/frontend/src/components/EpisodeSources.vue +++ b/frontend/src/components/EpisodeSources.vue @@ -37,6 +37,9 @@ const confirming = ref(false); const confirmError = ref(''); const purchased = ref(false); +const tokenInput = ref(''); +const redeemingToken = ref(false); + const sortedRows = computed(() => [...rows.value].sort((a, b) => { if (sortKey.value === 'latencyMs') return (a.latencyMs ?? Infinity) - (b.latencyMs ?? Infinity); @@ -123,10 +126,28 @@ async function checkPaid() { } } +async function payWithToken(row: Row) { + confirmError.value = ''; + redeemingToken.value = true; + try { + await api.post(`/api/podcasts/${props.podcastId}/episodes/${props.episodeId}/purchase/token`, { + source: row.type === 'producer' ? 'producer' : row.pubkey, + token: tokenInput.value.trim(), + }); + purchased.value = true; + emit('purchased'); + } catch (err) { + confirmError.value = (err as Error).message; + } finally { + redeemingToken.value = false; + } +} + function cancelBuy() { buyingPubkey.value = null; invoice.value = ''; quoteId.value = ''; + tokenInput.value = ''; confirmError.value = ''; } @@ -172,6 +193,23 @@ function cancelBuy() { {{ confirming ? 'Checking…' : "I've paid — unlock" }} + +
+

— or pay with a Cashu token instead —

+