ssh-agent forwarding and sudo to another user

As you mentioned, the environment variables are removed by sudo, for security reasons. But fortunately sudo is quite configurable: you can tell it precisely which environment variables you want to keep thanks to the env_keep configuration option in /etc/sudoers. For agent forwarding, you need to keep the SSH_AUTH_SOCK environment variable. To do so, simply edit … Read more

How to use vmImage on pipeline using Azure DevOps Server?

We can’t use ubuntu-latest in Azure DevOps Server. Those VmImages are only for Microsoft-hosted agents and Microsoft-hosted agents are only for Azure Devops Service. Please check the statement from the documentation: Microsoft-hosted agents are only available with Azure DevOps Services, which is hosted in the cloud. You cannot use Microsoft-hosted agents or the Azure Pipelines agent pool with on-premises TFS or Azure DevOps Server. With these on-premises … Read more