raf
raf
Explore posts from servers
SSolidJS
Created by raf on 8/30/2024 in #support
Cannot build SSG
So i'm trying to build SSG instead of SPA so it works better with SEO, however during prerendering, it always return this error
SyntaxError: The requested module 'file://C:/Users/RAFLYMAULANA/Documents/Github/@takodotid/v2-frontend/node_modules/.pnpm/[email protected]/node_modules/solid-js/web/dist/server.js' does not provide an export
SyntaxError: The requested module 'file://C:/Users/RAFLYMAULANA/Documents/Github/@takodotid/v2-frontend/node_modules/.pnpm/[email protected]/node_modules/solid-js/web/dist/server.js' does not provide an export
during building everything fine, if i compile to SPA everything is working fine too, however when trying to build SSG, it just fail, if the result output index.html, it just empty <div id="#app"></div> with no content my app.config.ts
export default defineConfig({
vite: {
resolve: {
alias: {
"@": resolve(dirname(fileURLToPath(import.meta.url)), "src"),
"@assets": resolve(dirname(fileURLToPath(import.meta.url)), "assets"),
},
},
},
server: {
static: true,
prerender: {
routes: ["/", "/about"],
},
},
});
export default defineConfig({
vite: {
resolve: {
alias: {
"@": resolve(dirname(fileURLToPath(import.meta.url)), "src"),
"@assets": resolve(dirname(fileURLToPath(import.meta.url)), "assets"),
},
},
},
server: {
static: true,
prerender: {
routes: ["/", "/about"],
},
},
});
5 replies
RRailway
Created by raf on 8/4/2024 in #✋|help
weird cpu usage
No description
11 replies
RRailway
Created by raf on 8/2/2024 in #✋|help
cannot pay invoice
No description
31 replies
RRailway
Created by raf on 8/1/2024 in #✋|help
My card was declined
I'm using online debit, previous billing was paid successfully, however this time, the card was declined, does Railway offer another way for paying instead using Stripe? Please let me know ASAP, we don't want our service to be shut down
6 replies
RRailway
Created by raf on 7/29/2024 in #✋|help
Cloudflare tunnel as VPN to access resources
This topics is outside Railway, so i'm happy if anyone willing to help me with it Before we start, i'm pretty new to cloudflare tunnel, so if there's something wrong about my statement please let me know So i'm trying to configure cloudflare tunnel to allow me accessing database on railway private network without having to use the public networking, why? of course, security. With CF zero trust, i see that i can limit who can access specified resources and so on So i've been reading cf tunnel docs and this article https://community.hetzner.com/tutorials/connect-over-pvt-net-with-cloudflare-access, however it turns out that at the end i need to configure the public hostname at the cf tunnel to access specific resources So my question is, how do i can connect to specific resource (e.g. postgresql) without needing to use public networking/hostname, perhaps like connecting directly via ip or maybe private network url like postgres.railway.internal via my computer? is that possible or am i missing something? Please let me know, any help is appreciated. Thank you!
templates used: https://railway.app/new/template/cf-tunnel
8 replies
RRailway
Created by raf on 7/26/2024 in #✋|help
Cannot delete volume or wipe its data
need team to access this, the volume has been deattached and located in singapore, i've named it "CANNOT BE DELETED TF" as you can see by the name...
9 replies
RRailway
Created by raf on 7/25/2024 in #✋|help
Postgresql Read Replicas
Hi, is it possible to do a postgresql read replicas in railway? since i think 1 volume can only be attached to single application Do anyone have guide or tutorial on here? If yes, please let me know here 😄 I need it to setup to reduce possible downtime by attacks like ddos, and prevent unwanted breaking things
18 replies
RRailway
Created by raf on 7/22/2024 in #✋|help
how to expose port in docker run?
No description
5 replies
RRailway
Created by raf on 7/22/2024 in #✋|help
Stuck on Healthcheck
No description
17 replies
RRailway
Created by raf on 7/19/2024 in #✋|help
why deploying takes too long?
No description
6 replies
RRailway
Created by raf on 7/18/2024 in #✋|help
Railway might as well deploy/having their own DDOS protection service for user
No description
14 replies
RRailway
Created by raf on 7/9/2024 in #✋|help
Is Project Member is billed to account billing?
So i need to add some of my team member to my Pro Plan account, however they only need to join at specific project so i'll only invite them as project member Is project member is counted as Team Member? especially who had Can Edit role? since i do not found this anywhere in the docs
6 replies
RRailway
Created by raf on 7/9/2024 in #✋|help
Abort signal on SSE not working
So I've been rewriting my polling code with Server-sent-events (SSE) to reduce egress fees to railway, and on the server side I've add a abort signal listener to stop the running interval. (I'm using NextJS App directory) here's the code
request.signal.addEventListener("abort", async () => {
console.info("Client disconnected");
clearInterval(interval);
await closeStream();
});
request.signal.addEventListener("abort", async () => {
console.info("Client disconnected");
clearInterval(interval);
await closeStream();
});
On my local computer and on other VPS, it works fine, when the client is closing the EventSource, the server received abort signal directly. However on Railway, the server cannot get the abort signal, and another bug that I found is that SSE connection only can works for around 2 minutes before the server automatically close the connection. Please keep in mind that in another machine everything works normally and there's no connection duration limit, it only happens on Railway. So I suspect that it has to do with Railway Edge Proxy, can anyone clarify and possibly help me with the solution to this problem? Thanks!
47 replies
RRailway
Created by raf on 6/29/2024 in #✋|help
Considering Migrating from Vercel
Hi i'm currently considering to migrate from Vercel for my apps, but i need some feedbacks and clarifications for some things since i could not (or have not) found the answer. To start, my apps is a new public SaaS that use NextJS which has over 3-5k daily users, while using Vercel is okay, but i find that Vercel charged for their Edge Request. My app has at least 1 mil request per day, and the included limit is only 10 mil, which i need to pay for extra 30-40 mil request (every 1m additional request charged for $2) I found out that Railway has different pricing scheme than vercel, and from what i see, i can save a lot from migrating to Railway, and the plus point is Railway is serverful! But there's a catch for me to consider this migration, my service has been attacked by various attack pattern ranged from DDOS attack, SYN Flood, SQL Injection, Code Exploit, etc for this past 4 months. I have also migrate from various platform before Vercel until i found that Vercel have protection for that, i now mark Vercel as our safe place (until i found out the pricing). So now i requires platform that at least have protection for DDOS attack, does Railway provide this? And please do not underestimating the DDOS attack, since my infra can be down for at least 30 minutes before i can even recover (yes i also use cloudflare pro and additional ddos protection from the cloud provider at that point, but still...) So can anyone with the same experience or know the answer to this help me to this question? 1. Do Railway has DDOS Protection? - we are afraid that incoming attack will be charged to our RAM & CPU usage 2. The railway pricing is basically subscription + usage right? i need to pay for the subscription first, then the usage? 3. Is my project on Railway is put into shared instance? since i found out that pro subscription server has 32 GB RAM / 32 vCPU per service, and if so, is the shared instance has protection for DDOS protection, or does any attack to any service on the shared instance will be affecting my service? 4. Do i need to setup my own CDN like cloudflare? Since on vercel, they basically have everything set up, we just need to put our apps and run 5. For anyone who hosts nextjs on Railway, how's your experience using it? What's the pros and cons? Thank you!
25 replies