DJ Electro
CCoder.com
•Created by DJ Electro on 4/25/2024 in #help
Multiple containers in one template
This is probably really silly but I've never used Terraform and barely used Docker before so I'm going in a bit blind. I'm trying to build a workspace template that has an application container as well as a database container. I'm trying to simply use the latest MariaDB image from docker hub.
The application container works fine, but the database container never starts. It shows up in the UI, but just shows an error that it did not start in time. I can't figure out how to debug this issue since there are no details, logs, or any further information as to how far it got in the process.
I'm also not sure if each container needs its own
coder_agent
resource or if I'm meant to reuse it. In my current tf file, I have one for each container, but I have tried reusing the "main" agent with no luck.
Attached is my tf file for the workspace.
I appreciate your help23 replies