HappyShark
HappyShark
CCoder.com
Created by HappyShark on 1/16/2025 in #help
Should terraform init run on every deploy?
yeah that would definitely be of interest. The improved profiling has already been of help in figuring out where our time is being spent.
29 replies
CCoder.com
Created by HappyShark on 1/16/2025 in #help
Should terraform init run on every deploy?
there's very likely a good reason why coder does things the way it does that I'm not seeing right now but if our particular use case is somewhat narrow compared to most users I might be able to get some optimisations in, or contribute back if it's actually a meaningful improvement for everyone
29 replies
CCoder.com
Created by HappyShark on 1/16/2025 in #help
Should terraform init run on every deploy?
but this also seemed like a possible vector for improvement. Assumed that a terraform init would occur when a version was published if there was a lock file, then that would be skipped straight to plan on requesting a workspace
29 replies
CCoder.com
Created by HappyShark on 1/16/2025 in #help
Should terraform init run on every deploy?
currently 1s out of ~20-25s for our deployment to kubernetes. We're currently trying to get that under 20, part of which will be reducing out startup script time and pod scheduling
29 replies
CCoder.com
Created by HappyShark on 1/16/2025 in #help
Should terraform init run on every deploy?
I suppose this is the safe option, but seems like there could be some time saved by only doing this once? I'm probably in a very small minority of people for whom startup time is important, maybe when I get time I could look at trying this in a fork
29 replies
CCoder.com
Created by HappyShark on 1/16/2025 in #help
Should terraform init run on every deploy?
29 replies
CCoder.com
Created by HappyShark on 1/16/2025 in #help
Should terraform init run on every deploy?
The lock file is in the current version. I've had a quick look around the provisioner code, and I could be in the wrong place or misunderstanding things but it looks like there's a call to init in the Plan method, which is called everytime regardless of whether the providers/modules have been installed before?
29 replies
CCoder.com
Created by HappyShark on 1/16/2025 in #help
Should terraform init run on every deploy?
Though I am still a little curious as to whether an init is still necessary to run after the first deployment of a particular version? if the files can't change between published versions of a template can you get away with only running an init to cache the modules/providers the very first time?
29 replies
CCoder.com
Created by HappyShark on 1/16/2025 in #help
Should terraform init run on every deploy?
No description
29 replies
CCoder.com
Created by HappyShark on 1/16/2025 in #help
Should terraform init run on every deploy?
Can see that there's something differeing in the h1 hash in the diff, will keep this in mind in the future, think I can call this question answered
29 replies
CCoder.com
Created by HappyShark on 1/16/2025 in #help
Should terraform init run on every deploy?
maybe that was just a fluke, have done a few more tests and can get my workspaces up and connected in browser in under 25s now
29 replies
CCoder.com
Created by HappyShark on 1/16/2025 in #help
Should terraform init run on every deploy?
No description
29 replies
CCoder.com
Created by HappyShark on 1/16/2025 in #help
Should terraform init run on every deploy?
Looking back at this, I'm not sure why it's saying there's changes between the registry and my lock file when I made it within a few hours of this. Are terraform providers platform specific? Maybe I need to generate this in wsl rather than windows?
29 replies
CCoder.com
Created by HappyShark on 1/13/2025 in #help
Starting workspaces on Koyeb
I managed to fix this issue! must have either been an issue with the size of the docker file, or the download of the agent/code-server failing on start. I wrote a new dockerfile that pre-installs the agent + code-server, then has the agent as the startup command and that seems to work perfectly, and starts reeeeally fast compared to every other deployment target I've tried.
14 replies
CCoder.com
Created by HappyShark on 1/13/2025 in #help
Starting workspaces on Koyeb
seems like startup times could be much faster if the agent and code-server itself were preinstalled into the image rather than startup scripts
14 replies
CCoder.com
Created by HappyShark on 1/13/2025 in #help
Starting workspaces on Koyeb
I'm wondering if the startup script for the coder agent is taking too long for the health checks to pass at the moment, are there reasons beyond only having to maintain one enterprise-base docker image for this install to happen at startup time rather than baked into multiple platform specific images? https://github.com/coder/coder/tree/main/provisionersdk/scripts
14 replies
CCoder.com
Created by HappyShark on 1/13/2025 in #help
Starting workspaces on Koyeb
attempting to use coder with the attached terraform template to spin up code-server workspaces on koyeb
14 replies
CCoder.com
Created by HappyShark on 1/13/2025 in #help
Starting workspaces on Koyeb
unfortunately seems like the only logs I can get from koyeb are
Instance created. Preparing to start...
Internal deployment error. If the error persists, try to redeploy or contact us.
Instance stopped.
Instance created. Preparing to start...
Internal deployment error. If the error persists, try to redeploy or contact us.
Instance stopped.
14 replies