We have a .war, containing an .ebextensions folder with the storage-efs-mountfilesystem.config, which mounts the efs to the EC2 Instance. On Linux 1 it works like a charm. Now we use the same war on Linux 2 and cannot deploy it, as we get an error which says command execution failed. We got the .config from AWS' developer Guide so we dont know if it just is not updated for Linux 2 or we have to change something, not mentioned on the docs?
Here are the logs:
2022-03-25 09:43:56,732 [ERROR] Command 01_mount (/tmp/mount-efs.sh) failed
2022-03-25 09:43:56,732 [ERROR] Error encountered during build of prebuild_0_Kiwi: Command
01_mount failed
Traceback (most recent call last):
File "/usr/lib/python3.7/site-packages/cfnbootstrap/construction.py", line 576, in run_config
CloudFormationCarpenter(config, self._auth_config).build(worklog)
File "/usr/lib/python3.7/site-packages/cfnbootstrap/construction.py", line 276, in build
self._config.commands)
File "/usr/lib/python3.7/site-packages/cfnbootstrap/command_tool.py", line 127, in apply
raise ToolError(u"Command %s failed" % name)
cfnbootstrap.construction_errors.ToolError: Command 01_mount failed
2022-03-25 09:43:56,733 [ERROR] -----------------------BUILD FAILED!------------------------
2022-03-25 09:43:56,733 [ERROR] Unhandled exception during build: Command 01_mount failed
Traceback (most recent call last):
File "/opt/aws/bin/cfn-init", line 176, in
worklog.build(metadata, configSets)
File "/usr/lib/python3.7/site-packages/cfnbootstrap/construction.py", line 137, in build
Contractor(metadata).build(configSets, self)
File "/usr/lib/python3.7/site-packages/cfnbootstrap/construction.py", line 564, in build
self.run_config(config, worklog)
File "/usr/lib/python3.7/site-packages/cfnbootstrap/construction.py", line 576, in run_config
CloudFormationCarpenter(config, self._auth_config).build(worklog)
File "/usr/lib/python3.7/site-packages/cfnbootstrap/construction.py", line 276, in build
self._config.commands)
File "/usr/lib/python3.7/site-packages/cfnbootstrap/command_tool.py", line 127, in apply
raise ToolError(u"Command %s failed" % name)
cfnbootstrap.construction_errors.ToolError: Command 01_mount failed