Questions tagged [powershell]

PowerShell is a command line and scripting utility for use with Windows.

Filter by
Sorted by
Tagged with
0 votes
0 answers
7 views

Verify Latest SSM Agent Installer On Disk

Sometimes the SSM Agent installer (an exe file), fails to download or becomes corrupted. Currently, we have the following script that examines the size and downloads if the file is too small on disk. ...
Wesley Rolnick's user avatar
0 votes
1 answer
333 views

how to run powershell script as windows administrator user using ansible

i want to run a power shell script on remote windows machine. The PowerShell script will install software on C drive. The user which used to login is already in administrator group. But when the ...
heyloitsmeraj's user avatar
2 votes
2 answers
4k views

Ansible: How to run local powershell script on remote hosts

I'm trying to write a play that will take a locally stored powershell script from my Ansible server and run it on Windows hosts. I have been using the "win_shell" module to run scripts ...
James T Snell's user avatar
0 votes
1 answer
1k views

Trying to run a simple API GET request for private Gitlab account

I am trying to run a simple API request to GitLab through powershell 5.1. After generating an access token with all privileges using the Web UI I tried to run the following: invoke-restmethod https://...
user32882's user avatar
  • 111
0 votes
1 answer
2k views

What is the difference between CMD and terminal in Windows machine?

While using the Windows machine we face soo much trouble running the command line scripts on CMD(command prompt). Few commands run successfully but some are not. Why is there any difference between ...
Rashid's user avatar
  • 101
3 votes
2 answers
6k views

Azure Devops Pipeline variables in Powershell

I've tried to figure this out and I can't see why my ipaddress is not getting set. I've checked code samples and they all suggest I am doing everything correct. ip variable defined here: This is my ...
cdsln's user avatar
  • 151
1 vote
1 answer
1k views

REST API: create project with powershell returns unspecified internal error

I'm creating a a project with the code below. The response is always an unspecified error. Invoke-RestMethod : {"$id":"1","innerException":null,"message":"...
Brtrnd's user avatar
  • 113
1 vote
1 answer
513 views

Azure Pipeline PowerShell@2 Task can't run 'invoke-build' command as inline script (build PowerShell Module)

I'm trying to build a PowerShell module in an Azure pipeline (dev.azure.com). I've setup an initial pipeline and then building it up incrementally in small steps, because inexplicable errors are ...
Plastikfan's user avatar
1 vote
1 answer
2k views

Stop Multiple Windows Service Simultaneously

I have multiple windows service and there are no dependencies between them. I want to stop all the windows services at the same time. I don't want to stop all the services one by one. How can I ...
ankit thakkar's user avatar
1 vote
4 answers
2k views

Why will my container run in Docker, but will not run in Kubernetes?

Background I have a container that I have defined with an CMD and an ENTRYPOINT in Docker. When I run the following command my container runs with no issues whatsoever. docker run --rm -ti custom-...
Dodzi Dzakuma's user avatar
2 votes
1 answer
3k views

Azure Powershell DSC or Ansible

I wanted to find out what are you using for Desired State Configuration on your end. I am thinking to start introducing Azure Powershell DSC or Ansible for DSC of our on-prem environment and cloud ...
bluehatgeek's user avatar
4 votes
1 answer
605 views

I'm trying to run `vagrant provision` on PowerShell Window for Ansible playbook

Here is what it replies: Windows is not officially supported for the Ansible Control Machine. Please check https://docs.ansible.com/intro_installation.html#control-machine-requirements What should I ...
Thi Nguyen Hoang's user avatar
1 vote
1 answer
328 views

How to pass variables between build/deploy tasks in a TaskGroup in VSTS 16.131.28601.4

I have a multi-configuration web application I'm using parallel deployments, leveraging Task Groups for reusing my deployment code. I've been using Powershell tasks and the ##vso[task.setvariable ...
Pxtl's user avatar
  • 111
0 votes
1 answer
297 views

Problem with Vagrant : Nothing happens on vagrant up command

Versions Vagrant: 1.9.5 Provider: Virtualbox 5.2.30 Guest: precise32 Host: windows 7 -32bit, build:7600 Powershell: 2.0 Vagrant destroy & up output nothing happens here...just an empty directory ...
Ganesh Redd's user avatar
2 votes
0 answers
1k views

Running a powershell script via Jenkins on a Linux host [closed]

I have a powershell script cloned into my workspace from a bitbucket repository. If I login to the Jenkins server cli I can run it by doing cd /var/lib/jenkins/workspace/powershell pwsh ./psscript....
CEamonn's user avatar
  • 213
2 votes
1 answer
3k views

Powershell script in jenkins is hanging

I'm building a process to automate deploys using Jenkins and I have an issue getting the code on the server I have a powershell script on the deploy server that all it does is do an hg update command....
Eman's user avatar
  • 123
8 votes
2 answers
578 views

Application to run PowerShell scripts

I've created a number of scripts in PowerShell that require a number of parameters to be manually entered. Unfortunately, until we have our Jenkins server setup to support these additional tasks I ...
KJQ's user avatar
  • 83
3 votes
1 answer
376 views

Why is my build script only failing when it is run in a vNext build?

I am running a build process on an on-prem server with TFS 2017 and vNext. The build works, but it takes 20+ minutes. This is an application that does msbuild, ngc, yarn, and karma. I would be totally ...
Aaron's user avatar
  • 41
1 vote
0 answers
49 views

VSO Release launch published exe [closed]

I have hosted VSO build agents building our exe and that pipeline setup. I am trying to deploy the produced exe to a dev testing environment. I have a deployment group set up and the files are being ...
xtreampb's user avatar
  • 433
5 votes
2 answers
5k views

How to automate Powershell's interactive Get-Credential method?

I am trying to write a python script which automates the powershell's Get-Credential method. Here is something i wrote: import subprocess COMMAND_LINE = 'powershell' powershell = subprocess.Popen(...
Vivek Lohiya's user avatar
4 votes
1 answer
13k views

Configure Docker to use SSL for a private registry on Windows 10?

Trying to use a customer registry from a Windows 10 system - a native Docker client in PowerShell. PS > docker --version Docker version 17.06.0-ce, build 02c1287 PS > docker pull REPO_URL/...
Ta Mu's user avatar
  • 6,792
8 votes
2 answers
2k views

Ansible sporadic errors with Windows machines

I'm running into some on and off issues when using windows hosts in my Ansible playbooks. I'm running Ansible 2.3 with pywinrm 0.2.2 installed. I'm using basic authentication with the local ...
Asaf Haim's user avatar
  • 161