You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Since a lambda only has read-only access the build fails as Astro tries to create a .astro directory inside the project folder instead of the specified /tmp dir. Is this a supported use-case? Can I avoid creating the .astro directory in my project folder?
I tried to read through the source and find getOutDirWithinCwd states:
/**
* Ensures the `outDir` is within `process.cwd()`. If not it will fallback to `<cwd>/.astro`.
* This is used for static `ssrBuild` so the output can access node_modules when we import
* the output files. A hardcoded fallback dir is fine as it would be cleaned up after build.
*/
I think this makes sense for most use-cases but fails for being able to use astro inside a read-only directory.
Hello @EkaanshArora. Please provide a minimal reproduction using a GitHub repository or StackBlitz. Issues marked with needs repro will be closed if they have no activity within 3 days.
Astro Info
If this issue only occurs in one browser, which browser is a problem?
No response
Describe the Bug
I'm trying to use Astro inside an AWS Lambda as a build service tool. I'm using the JS API:
Since a lambda only has
read-only
access the build fails as Astro tries to create a.astro
directory inside the project folder instead of the specified/tmp
dir. Is this a supported use-case? Can I avoid creating the .astro directory in my project folder?I tried to read through the source and find
getOutDirWithinCwd
states:I think this makes sense for most use-cases but fails for being able to use astro inside a read-only directory.
What's the expected result?
Astro uses the specified folder for build cache
Link to Minimal Reproducible Example
https://github.com/EkaanshArora/astro-build-api-cache-repro
Participation
The text was updated successfully, but these errors were encountered: