timoa / terraform-oci-vscode-server

Terraform project that deploys VSCode Server on Oracle Cloud Infrastructure (free tier) and protect the access with Cloudflare Zero Trust (optional) or an SSH tunnel
https://timoa.com
Apache License 2.0
26 stars 1 forks source link

Optional dependencies install are executed in parallel and can fail (dpkg lock) #11

Open timoa opened 2 years ago

timoa commented 2 years ago

Optional dependencies like Cloudflare Zero Trust or the DevOps dependencies are installed by Ansible with the local-exec provider.

The issue is that Terraform is executing them in parallel since they are optional and can't be linked with depends_onfor example.

If multiple executions of apt or dpkg are run simultaneously, the first execution will lock the execution for the other commands (dpkg lock file).

The sequence of the optional dependencies installation needs to be changed by a single script with args or something else.