基于docker image
编译.NET应用程序
- .NET Core SDK
- Nodejs
- Npm
- Yarn
- bower
- glup
- webpack
一个build.sh
工程构建脚本
#!/bin/sh
set -e
basepath=$(cd `dirname $0`; pwd)
dotnet restore ${basepath}
dotnet build ${basepath}
dotnet pack -c release ${basepath}
定义docker-build.sh
脚本,挂载到容器上执行build.sh
操作
basepath=$(cd `dirname $0`; pwd)
docker run --rm \
-v ${basepath}:/dotnet-build \
eswork/dotnet-build \
sh -c "chmod 755 /dotnet-build/build.sh && /dotnet-build/build.sh "