question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

How to give extra privileges to the runner over the self-hosted Windows server?

See original GitHub issue

It looks like the runner uses the nt authority\network service account to run PowerShell commands (checked using whoami within the workflow).

This isn’t useful when trying to deploy my app to my server. For example, I need to use schtasks.exe which gives ERROR: Access is denied.

Can I give extra privileges to the runner to avoid issues like this?

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:5

github_iconTop GitHub Comments

13reactions
JacobWrenncommented, Apr 5, 2020

I found the easiest solution for my issue was to change the account the GitHub Actions service ran under.

I achieved this by using powershell "(Get-Service actions.runner.*).name" to find the name of the GitHub Actions service.

And then running sc config "NAME_OF_YOUR_SERVICE" obj= "NT AUTHORITY\SYSTEM" type= own to update it to run as the system.

2reactions
Papoochcommented, Jan 24, 2022

@snankens you need to run the command with cmd and not powershell.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to run a GitHub Enterprise action runner as an ...
Found a solution for this here: How to give extra privileges to the runner over the self-hosted Windows server?
Read more >
CircleCI's self-hosted runner overview
Learn how CircleCI's self-hosted runners enable you to use your own ... If you set up self-hosted runners in AWS, they can be...
Read more >
Tutorial: Run GitHub Actions runners and Azure Pipelines ...
Learn to create self-hosted CI/CD runners and agents with jobs in Azure Container Apps.
Read more >
GitHub Hosted vs. Self-Hosted Runners
Having self-hosted runners means that the runner app is hosted in your environment of choice—an on-premises server or hosted via your ...
Read more >
Setting up GitHub Runners on DigitalOcean
Create a new user and grant administrative privileges ... Command execution will trigger a set of questions, like account password, full name, work...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found