Hey I am trying to run a simple Svelte-kit project on appwrite self-hosted but the logs says:
[13:56:26] [open-runtimes] Build packaging finished.
[13:56:26] [open-runtimes] Build finished.
[13:56:30] [appwrite] Deployment finished.
But than when I go to the url it says literally 404 page not found
Does anyone know what I am doing wrong? -# The sveltekit project is located in the ./frontend/web of my private gh repo
The issue is almost certainly the adapter mismatch you have Server side rendering selected, which requires @sveltejs/adapter-node, but if your svelte.config.js is still using adapter-static or any other adapter, Appwrite won't know how to serve the app correctly, hence the 404. Can you share what adapter is currently set in your svelte.config.js?
svelte.config.js
import adapter from '@sveltejs/adapter-node';
import { vitePreprocess } from '@sveltejs/vite-plugin-svelte';
/** @type {import('@sveltejs/kit').Config} */
const config = {
preprocess: vitePreprocess(),
kit: {
adapter: adapter(),
alias: { $components: 'src/components' },
},
runes: true,
vitePlugin: {
dynamicCompileOptions: ({ filename }) =>
filename.includes('node_modules') ? undefined : { runes: true },
},
};
export default config;
Your adapter config looks correct, so the issue is likely that Appwrite's SSR runtime expects the server entry point at a specific path and adapter-node outputs it differently by default. You need to set the output option in your adapter config to match what Appwrite expects.
Try updating your adapter like this:
adapter({ out: 'build' })
Also make sure your output directory in the Appwrite settings matches that it's currently set to ./build which should be right. I've actually worked through a few Appwrite + SvelteKit deployment issues before. Shoot me a DM if you want me to help you get this fully sorted quickly!
Recommended threads
- Appwrite for Education
I am writing to report an issue with my account limits. I currently have the GitHub Student Developer Pack active, which should include 10 Appwrite Pro projects...
- Getting 503 errors on a streaming respon...
I am running my Svelte site through Appwrite Sites. Everything works great, except for one page. This page uses a streaming response over a regular static res...
- Go functions cold start timeout on self-...
Hey everyone — running into a persistent cold start issue with Go functions on self-hosted Appwrite 1.9.0 (Elestio/Hetzner). Looking for how others are handling...