shixzie
shixzie
Explore posts from servers
RRailway
Created by shixzie on 11/7/2023 in #✋|help
Golang Monorepo
have anyone deployed a go monorepo successfuly? (I have Hobby plan) I'm using go workspaces and have multiple services/modules in the root of the project. In railway I'm trying to create a service for each executable module and setting the Root Directory to the corresponding directory. But that makes it impossible to download/install internal/local modules since the Docker environment (using Dockerfile because I'm using latest go version) is created with only the contents of the directory/service I'm trying to deploy. The code is deployed from a private github repo, so I'd be annoying to provide the Github Credentials to download the deps when they're already in the repo (aside from the fact that from what I can see on some Go docs, I'd have to specify each local module in an env var)... Is there any other way to do it? Am I doing unnecesary stuff?
9 replies
CDCloudflare Developers
Created by shixzie on 6/2/2023 in #pages-help
Next build succeeds but it fails to "find a module"?
I got a Next 13 app with Server components, everything was working fine and then I started getting errors on my builds (look at the last line)
...
09:57:35.704 - __next-on-pages-dist__/functions/api/[...path].func.js (esm)
09:57:35.864 ✨ Compiled Worker successfully
09:57:35.936 Found _routes.json in output directory. Uploading.
09:57:35.953 Validating asset output directory
09:57:36.741 Deploying your site to Cloudflare's global network...
09:57:38.765 Parsed 1 valid header rule.
09:57:40.268 Uploading... (31/45)
09:57:40.866 Uploading... (35/45)
09:57:41.007 Uploading... (40/45)
09:57:41.198 Uploading... (45/45)
09:57:41.199 ✨ Success! Uploaded 14 files (31 already uploaded) (1.52 sec)
09:57:41.199
09:57:41.929 ✨ Upload complete!
09:57:43.783 Success: Assets published!
09:57:45.014 Error: Failed to publish your Function. Got error: Uncaught Error: No such module "opt/buildhome/repo/.vercel/output/static/_worker.js/index.js".
imported from "bundledWorker-0.37093777238877634.mjs"
...
09:57:35.704 - __next-on-pages-dist__/functions/api/[...path].func.js (esm)
09:57:35.864 ✨ Compiled Worker successfully
09:57:35.936 Found _routes.json in output directory. Uploading.
09:57:35.953 Validating asset output directory
09:57:36.741 Deploying your site to Cloudflare's global network...
09:57:38.765 Parsed 1 valid header rule.
09:57:40.268 Uploading... (31/45)
09:57:40.866 Uploading... (35/45)
09:57:41.007 Uploading... (40/45)
09:57:41.198 Uploading... (45/45)
09:57:41.199 ✨ Success! Uploaded 14 files (31 already uploaded) (1.52 sec)
09:57:41.199
09:57:41.929 ✨ Upload complete!
09:57:43.783 Success: Assets published!
09:57:45.014 Error: Failed to publish your Function. Got error: Uncaught Error: No such module "opt/buildhome/repo/.vercel/output/static/_worker.js/index.js".
imported from "bundledWorker-0.37093777238877634.mjs"
28 replies
CDCloudflare Developers
Created by shixzie on 2/22/2023 in #pages-help
Next 13 `app` dir InternalServerError
Hey, I was following the steps described in here https://github.com/cloudflare/next-on-pages to deploy a Next 13 app with the app directory and the response from the server on the / route returns Internal Server Error. I dove into the function logs for the deployment and got the following:
...
"exceptions": [
{
"name": "TypeError",
"message": "undefined is not iterable (cannot read property Symbol(Symbol.iterator))",
"timestamp": 1677101532584
}
],
"logs": [
{
"message": [
"Error: Invariant: AsyncLocalStorage accessed in runtime where it is not available"
],
"level": "error",
"timestamp": 1677101532584
},
{
"message": [
"TypeError: Cannot read properties of null (reading 'default')"
],
"level": "error",
"timestamp": 1677101532584
}
],
...
...
"exceptions": [
{
"name": "TypeError",
"message": "undefined is not iterable (cannot read property Symbol(Symbol.iterator))",
"timestamp": 1677101532584
}
],
"logs": [
{
"message": [
"Error: Invariant: AsyncLocalStorage accessed in runtime where it is not available"
],
"level": "error",
"timestamp": 1677101532584
},
{
"message": [
"TypeError: Cannot read properties of null (reading 'default')"
],
"level": "error",
"timestamp": 1677101532584
}
],
...
I'm not really sure what they are so here I am. I created the project from scratch (ie. npx create-next-app@latest) the appDir experimental config is enabled and basically everything the README says. Appreciate any help.
2 replies