404 in standalone release in docker container
Answered
aa55h posted this in #help-forum
Answered by riský
for standalone, you need to copy the static+public files to standalone/public for some reason
41 Replies
aa55hOP
it doesnt find any of the resources
and the files are indeed in the container
i can send the dockerfile or any directory setup
for standalone, you need to copy the static+public files to standalone/public for some reason
Answer
@riský for standalone, you need to copy the static+public files to standalone/public for some reason
aa55hOP
what? i dont have any public/static files though, i only designed the page with tailwind inline
aa55hOP
oh nvm
im stupid
the styles are still not being applied
its supposed to be translated
maybe tailwind things are missing?
its like this in container
the css file contains tailwind though
i might have forgot to include the tailwind cfg
aa55hOP
yoo it works!!!
yay contratz!
if its solved and node more questions, you can mark this as solved by folowing https://canary.discord.com/channels/752553802359505017/1284393114689212426/1284393125363716208 :)
aa55hOP
Awesome
@riský if its solved and node more questions, you can mark this as solved by folowing https://canary.discord.com/channels/752553802359505017/1284393114689212426/1284393125363716208 :)
aa55hOP
I actually have one more question, the build takes a few seconds on pc, but in gh action in docker container, it takes a lot of time, any idea why?
Like 4 mins
maybe cache
but 4mins is crazy
@aa55h I actually have one more question, the build takes a few seconds on pc, but in gh action in docker container, it takes a lot of time, any idea why?
also when you say 4 mins, is that just build, or total like install packages?
aa55hOP
Just the next build
The container builds quickly locally, but in gh actions its this slow
id say try to cache
.next/cache if not already but maybe you just have a really beefy localgh actions have always been faster then my laptop tho
aa55hOP
Can it be because it builds on arm arch though
While my local is amd64
@aa55h Can it be because it builds on arm arch though
wait why you arent using default ubuntu runners? why do you need arm?
aa55hOP
Oh no the docker container has platform set to arm
See here
You can also take a look at the logs
The project is only a few pages though
yeah your app seems so basic
if you just run build outside docker, how fast is it?
like maybe it is making one core or something sad
@aa55h oh btw i forgot about it, but they have a "recomended" docker build: <https://github.com/vercel/next.js/blob/canary/examples/with-docker/Dockerfile