1
0

More than 3 years have passed since last update.

AWS EBで「Unhandled exception during build: invalid literal for int() with base 8: '493'」エラーの対処

Last updated at Posted at 2021-01-23

概要

AWSのElastic Beanstalkで.ebextensionsを利用時にデプロイでエラー発生
(ちなみにPHPでLaravel)

/var/log/cfn-init.log
2021-01-23 02:10:56,395 [ERROR] -----------------------BUILD FAILED!------------------------
2021-01-23 02:10:56,395 [ERROR] Unhandled exception during build: invalid literal for int() with base 8: '493'
Traceback (most recent call last):
  File "/opt/aws/bin/cfn-init", line 171, in <module>
    worklog.build(metadata, configSets)
  File "/usr/lib/python2.7/site-packages/cfnbootstrap/construction.py", line 129, in build
    Contractor(metadata).build(configSets, self)
  File "/usr/lib/python2.7/site-packages/cfnbootstrap/construction.py", line 530, in build
    self.run_config(config, worklog)
  File "/usr/lib/python2.7/site-packages/cfnbootstrap/construction.py", line 542, in run_config
    CloudFormationCarpenter(config, self._auth_config).build(worklog)
  File "/usr/lib/python2.7/site-packages/cfnbootstrap/construction.py", line 251, in build
    changes['files'] = FileTool().apply(self._config.files, self._auth_config)
  File "/usr/lib/python2.7/site-packages/cfnbootstrap/file_tool.py", line 103, in apply
    file_is_link = "mode" in attribs and stat.S_ISLNK(int(attribs["mode"], 8))
ValueError: invalid literal for int() with base 8: '493'

今回解消した方法

.ebextensions/hogehoge.configファイルの内容を修正(modeのパラメータを"で囲む)

files:
  "/hoge/fuga.txt":
    mode: 000755
files:
  "/hoge/fuga.txt":
    mode: "000755"
1
0
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
1
0