If you’re doing the Amazon AWS workshop LAB: https://github.com/awslabs/eb-node-express-signup

ie. Upload and Deploying your Elastic Beanstalk app

and getting this PROBLEM error:

*ERROR Failed to deploy application.

*ERROR The configuration file __MACOSX/.ebextensions/._setup.config in application version 1.1.0 contains invalid YAML or JSON. YAML exception: Invalid Yaml: unacceptable character ‘�’ (0x0) special characters are not allowed in “”, position 0, JSON exception: Invalid JSON: Unexpected character (�) at position 0.. Update the configuration file.

*INFO Environment update is starting.


This is because MACOS includes some extra hidden folders which you need to exclude from your ZIP file. To do this, run this command in terminal on your zip:

  1. $ zip -d nameofyourzipfile.zip __MACOSX/\*

Now re-upload, and you should get a success message:

INFO Environment update completed successfully. INFO New application version was deployed to running EC2 instances.

Hope this solved your issue!

When you zip folders on MACOSX, it will add its own hidden files in there alongside yours.

If you want to make a zip without those invisible Mac resource files such as “_MACOSX” or “._Filename” and .ds store files, use the “-X” option in the zip command

  1. $ zip -r -X archive_name.zip folder_to_compress

If this is a pre-existing zip file, you can use the command others here have mentioned

  1. $ zip -d nameofyourzipfile.zip __MACOSX/\*

分类: web

标签:   aws