Elastic Beanstalk has error with .NET Core files zipped on mac

0

I am having issues with Elastic Beanstalk and my .NET Core web service that I'm attempting to build and deploy from my mac.

I downloaded the dotnet-core-tutorial-bundle.zip from this page: https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/dotnet-core-tutorial.html and confirmed that I can upload and deploy this zip.

When I unzip that folder using Finder and rezip using Finder or the zip command line tool, the deployment fails with message "Error during deployment: Application test-dotnet-core is missing web.config file."

I downloaded the same zip on a Windows computer, unzipped using Explorer, and rezipped using Explorer and the deployment succeeds.

Does anyone know a way to zip on a mac that will make Elastic Beanstalk happy? I did find several tutorials and forum posts that indicated that the commands I am running to zip have worked in the past.

My zip script:

zip -r -X site.zip site/
zip my-service.zip site.zip aws-windows-deployment-manifest.json

Edited by: christis on Apr 9, 2019 4:16 AM

已提问 5 年前590 查看次数
1 回答
0

Mac's zip function was adding an extra site folder to my archive. This isn't the most beautiful script but it works.

dotnet publish -o site -c Release
cd site
zip -r -X ../site.zip .
cd ..
zip my-service.zip site.zip aws-windows-deployment-manifest.json

Edited by: christis on Apr 9, 2019 5:02 PM

已回答 5 年前

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则