Dayblox
Dayblox
Explore posts from servers
DTDrizzle Team
Created by Dayblox on 4/2/2024 in #help
prepared statements placeholder typing
Schema
const users = sqliteTable("user", {
id: text("id").primaryKey(),
text: text("text"),
})
const users = sqliteTable("user", {
id: text("id").primaryKey(),
text: text("text"),
})
const updateUser = db
.update(users)
.set({ text: sql.placeholder("text") })
.where(eq(users.id, sql.placeholder("id")))
.prepare()
const updateUser = db
.update(users)
.set({ text: sql.placeholder("text") })
.where(eq(users.id, sql.placeholder("id")))
.prepare()
On the text property I get the following
Type 'Placeholder<"text", any>' is not assignable to type 'string | SQL<unknown> | null | undefined'.
Type 'Placeholder<"text", any>' is not assignable to type 'string | SQL<unknown> | null | undefined'.
The issue only seems to occur in the set part, is there a reason? A better way?
5 replies
RRailway
Created by Dayblox on 2/18/2024 in #✋|help
Listening on $PORT with docker image
I'm trying to run https://hub.docker.com/r/sundowndev/phoneinfoga but am not able to listen on the railway PORT. While debugging, using echo $PORT as the start command just prints $PORT, which seems to indicate that $PORT is not defined?
10 replies
RRailway
Created by Dayblox on 1/20/2024 in #✋|help
Template health info
As a template creator, I would also like to know why and when my template fails, is there a way to understand the health?
16 replies
RRailway
Created by Dayblox on 11/2/2023 in #✋|help
Credits used eventhough $5.00 discount was not exceeded
The title says it all, how can I debug this?
18 replies
DTDrizzle Team
Created by Dayblox on 10/26/2023 in #help
URL_INVALID
The env variables are defined when using bun run push but not when using npm run push or pnpm run push, resulting in LibsqlError: URL_INVALID: The URL is not in a valid format because url is undefined?authToken=undefined
export default {
schema: "./src/db/schema.ts",
out: "./src/db/migrations",
driver: "libsql",
dbCredentials: {
url: `${process.env.DATABASE_URL}?authToken=${process.env.DATABASE_TOKEN}`,
},
} satisfies Config
export default {
schema: "./src/db/schema.ts",
out: "./src/db/migrations",
driver: "libsql",
dbCredentials: {
url: `${process.env.DATABASE_URL}?authToken=${process.env.DATABASE_TOKEN}`,
},
} satisfies Config
{
"scripts": {
"push": "drizzle-kit push:sqlite"
},
// ...
}
{
"scripts": {
"push": "drizzle-kit push:sqlite"
},
// ...
}
7 replies
RRailway
Created by Dayblox on 10/18/2023 in #✋|help
tailscale into private network
Hey, I'm trying to get a VPN connection into a railway private network and it seems to work because I can ping the tailscale exit node (inside the private network) but can't seem to ping any other service on the network via their railway private domain name. Has anyone fiddled with this? Could it be a dns issue?
147 replies
RRailway
Created by Dayblox on 10/14/2023 in #✋|help
Volume direct access
Is there a way to access the data of a volume? I tried detaching the volume from its original service and mounting it on Brody's file browser service, but it shows empty
21 replies
RRailway
Created by Dayblox on 10/2/2023 in #✋|help
No query tab
What is the condition to have a query tab for a database? Mine doesn't (1fccf7a5-79ac-494c-baad-16914606fd3f)
41 replies
RRailway
Created by Dayblox on 10/1/2023 in #✋|help
Estimated usage seems way off
This project (1fccf7a5-79ac-494c-baad-16914606fd3f) is a pg database with a linked volume, it has been sleeping for a day. Does sleeping interact weirdly with usage estimates?
19 replies
RRailway
Created by Dayblox on 9/30/2023 in #✋|help
PB but cannot Set Usage Limits
No "Set Usage Limits" button on the Usage page, even though I am on Priority Boarding
6 replies
RRailway
Created by Dayblox on 9/30/2023 in #✋|help
Database Sleeping
I spun up a PostgreSQL database and added some table and rows. I continue seeing some outbound traffic, causing it to never sleep even if no one is querying the database. ID: 1fccf7a5-79ac-494c-baad-16914606fd3f
12 replies
RRailway
Created by Dayblox on 9/30/2023 in #✋|help
Database pricing
If I spin up a standalone database, get some amount of traffic, depending on what resources and prices will I be charged? If I understand correctly, it would be CPU, RAM, Network egress, and $0,25 per GB per month. Am I right? Can you provide real life examples of usage?
37 replies
RRailway
Created by Dayblox on 9/29/2023 in #✋|help
Scale to Zero: ELIFECYCLE  Command failed.
Just tried out the new Scale to Zero feature, appears to work well but upon sleeping the app logged ELIFECYCLE  Command failed. which showed the deploy as crashed.
31 replies
RRailway
Created by Dayblox on 7/31/2023 in #✋|help
Developer to Hobby migration
50 replies