美文网首页
alpine linux容器里运行powershell脚本

alpine linux容器里运行powershell脚本

作者: 9e8aeff1c70c | 来源:发表于2021-04-09 17:11 被阅读0次

    写个powershell脚本

    1+2
    $x="haha powershell"
    $x
    

    写个dockerfile

    FROM mcr.microsoft.com/powershell:7.1.3-alpine-3.11-20210316
    COPY test.ps /
    CMD ["pwsh","/test.ps"]
    

    制作docker镜像

    sudo docker build -t ps .

    运行docker容器

    sudo docker run --name ps ps

    输出结果

    3
    haha powershell

    相关文章

      网友评论

          本文标题:alpine linux容器里运行powershell脚本

          本文链接:https://www.haomeiwen.com/subject/jscwkltx.html