LoginSignup
0
1

More than 5 years have passed since last update.

ansible で Syntax Error

Posted at

普段とは別の環境で playbook を書いていたら Syntax Error でハマったのでメモ。

$ ansible-playbook --version|head -1
ansible-playbook 2.4.1.0

$ ansible-playbook pg.yml
ERROR! Syntax Error while loading YAML.

exception type: <class 'yaml.reader.ReaderError'>
exception: unacceptable character #x001b: control characters are not allowed
  in "<unicode string>", position 117

ググってみると一応似たような報告はあるものの、解決には至っていない模様:

10分ほどハマってから気づきました。

~/linux-config/roles/postgresql/tasks$ nkf -g *
createdb.yml: ISO-2022-JP
main.yml: ISO-2022-JP
package.yml: ASCII

ファイルが ISO-2022-JP (ぉぃぉぃ

それにしても、どのファイルでエラーが起こったかくらいは出して欲しいなぁ。

0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1