[英]Unable to run shell script from AzureDevops pipeline
I am new to AzureDevops pipelines.我是 AzureDevops 管道的新手。 I have a simple task, I want to run a shell script which is residing in my azure git repo.
我有一个简单的任务,我想运行一个驻留在我的 azure git repo 中的 shell 脚本。
steps:
- task: Bash@3
inputs:
targetType: 'inline' # Optional. Options: filePath, inline
#filePath: ./TestProject
#arguments: # Optional
- script:
pwd
set +x token.sh
sh token.sh
Build is getting successful but I don't see it has picked the sh file:构建正在成功,但我没有看到它选择了 sh 文件:
Generating script.
10(node:3269) Warning: Use Cipheriv for counter mode of aes-256-ctr
11(node:3269) Warning: Use Cipheriv for counter mode of aes-256-ctr
12(node:3269) Warning: Use Cipheriv for counter mode of aes-256-ctr
13Script contents:
14pwd set +x token.sh sh token.sh
15(node:3269) Warning: Use Cipheriv for counter mode of aes-256-ctr
16========================== Starting Command Output ===========================
17(node:3269) Warning: Use Cipheriv for counter mode of aes-256-ctr
18(node:3269) Warning: Use Cipheriv for counter mode of aes-256-ctr
19(node:3269) Warning: Use Cipheriv for counter mode of aes-256-ctr
20/bin/bash --noprofile --norc /home/vsts/work/_temp/33bdee3d-19de-47b6-8eab-01124cb0a0ed.sh
21/home/vsts/work/1/s
22Finishing: CmdLine
Build is successful but there is no log for sh execution.构建成功但是没有执行sh的日志。
I tested it in three tasks(Command line ,Shell Exec ,Bash ) with a simple .sh
file sample , every thing work well in these tasks , sh file executes normally.我用一个简单的
.sh
文件示例在三个任务(命令行、Shell Exec、Bash)中对其进行了测试,在这些任务中每件事都运行良好,sh 文件正常执行。
So can you share the token.sh
sample file for further investigation?那么您可以共享
token.sh
示例文件以供进一步调查吗? If there is any personal privacy information, please protect it.如果有任何个人隐私信息,请予以保护。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.