Language Mode "Docker Compose" with Unknown Error "Unexpected Scalar at Node End(Unexpected_Token)"

I create a docker compose file which is correct 100%, but vscode see some error, this is very annoying

May be somebody can explain?

1

1 Answer

Reason of VSCode alert is obviously invalid YAML syntax of your file. According to specific syntax and directory name I can conclude it's template of compose file.

But, thanks to flexible YAML specification, you can try to make it valid.

Try to enclose in quotation marks your volumes items (like - "{{ ldap_...}}:/dir/"), seem it will satisfy vscode, docker compose and your template engine.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Maya Lin-Takahashi

Maya Lin-Takahashi

Consumer Tech & Gadget Reviewer

Maya is a hardware enthusiast who tests and reviews smart home devices, smartphones, wearables, and audio gear. She focuses on practical consumer value and build quality.

Share this article
Twitter Facebook Pinterest