GitHub Actions - Upload Artifact Failed: Unable to get local issuer certificate - github

We are using self-hosted runners (Windows) for GitHub actions. Recently, our company changed the proxy. We have updated the System Environment Variables to the new proxy, and we have updated the proxy details in .env file as suggested by GitHub documentation. And we have added the Root CA in the Windows Certificate Manager (Certificates - Local Computer -> Trusted Root Certification Authorities -> Certificates). But when uploading the artifact during workflow run, we got the below error message and workflow is failing.
Create Artifact Container - Attempt 1 of 5 failed with error: unable to get local issuer certificate
Error: Create Artifact Container failed: unable to get local issuer certificate
##[debug]Node Action run completed with exit code 1
How can we resolve this error? Is there anything that should be changed in runner configuration?

Related

Running into certificate errors when running puppet agent config using vault lookup

I'm running into certificate errors when I run "puppet agent -t" using a vault lookup module in my branch for the agent config. Here's the errors I get:
"Failed to apply catalog: certificate verify failed" and "The certificate for does not match its private key"
The error persists even after I swap back to the production branch for the agent, where we then have to do an SSL clean to get the prod agent config to apply successfully.
Would setting up puppet to be the intermediaery CA be a good idea? Anybody run into this before?
We also setup approle auth for vault, but to no avail. Any help would be appreciated, thanks!
Unsuccessful solutions: vault app role auth, generating new keys, defining the ssl_cert manually in the agent config, and cleaning the agent cert from the master.

Installing azure devops extension in powershell but getting error

I am trying to install an azure DevOps extension in PowerShell using the command:
az extension add --name azure-devops
. But, getting certification error.
I tried to generate a selfsigned cert and tried to ping the url mentioned in error, was able to ping the url but error remain still there. The error is as below:
Please ensure you have network connection. Error detail:
HTTPSConnectionPool(host='objects.githubusercontent.com', port=443): Max retries exceeded with url: /github-production-release-asset-2e65be/107708057/8c8c37f1-25aa-4394-9b37-ab8655c6d437?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIWNJYAX4CSVEH53A%2F20230210%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20230210T092547Z&X-Amz-Expires=300&X-Amz-Signature=e65868999583f165ce08abf46e4e192fccffcd611847d2da76c25473f27927a4&X-Amz-SignedHeaders=host&actor_id=0&key_id=0&repo_id=107708057&response-content-disposition=attachment%3B%20filename%3Dazure_devops-0.26.0-py2.py3-none-any.whl&response-content-type=application%2Foctet-stream (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self signed certificate in certificate chain (_ssl.c:997)')))
I tried generating the selfsign certificate. Tried to install on current userscope.Also, tried to ping the url mentioned in error and it was giving reply back

Azure DevOps on-premise cannot verify Kubernetess service connection

I am creating New Kubernetes service connection in Azure DevOps Server 2020 Update 1 via KubeConfig.
When I click to Verify that the connection it says that Verification Failed with the generic error:
Failed to query service connection API: 'https://ekm.mpu.cz/k8s/clusters/c-qmcrb/api/v1/nodes'. Error Message: 'An error occurred while sending the request.'
Please note that the Kubernetess instance is in the other domain.
I have the notion that the error could be with the certs are not imported somewhere on the machine, where the Azure DevOps is hosted, but I am unsure where. The MS documentation is silent about that as well.
So far I've tried to:
Import CA certs to the MMC under trusted publishers.
Import CA certs under cacerts in JAVA-HOME via keytool.
Import CA certs into azureTrustsStore.jks in JAVA-HOME via keytool.
For all 3 I've checked that the CA certs are imported correctly. But to no avail. Could you please advice or redirect me to the method, how to do it?
Additional Info:
While I cannot Verify and Save the connection, I still can Save it and then use it in the pipeline and it works OK! (sucesfully connect and execute the command).
Connection issues can occur for many reasons, but the root cause is often related to an error with one of these items: Network, Authentication, Authorization. You may refer to Basic troubleshooting of cluster connection issues for detailed troubleshooting steps.

Getting certificate error when Installing softwares through azure pipelines

When I try to run TerraformInstaller to install terraform in azure pipelines, I get the following error message.
##[error]Error: Failed to download Terraform from url https://releases.hashicorp.com/terraform/1.2.4/terraform_1.2.4_linux_amd64.zip. Error Error: self signed certificate in certificate chain
When I browse the link in server where self-hosted agent is installed, I am able to get to the link fine and download the zip file but only getting this error when I am running the pipeline in Azure DevOps. Firewall port 443 is obviously open and I think this error has to do with cert not being placed in the correct location? Do I need to configure self-hosted agent with cert?

Handshaking with Octopus server fails from a TeamCity agent

We've been successfully using TeamCity and Octopus on a single machine, and now we have added a new build agent due to growing number of simultaneous builds. I have set up a new Octopus Tentacle and verified that Tentacle is reachable from the Octopus server in Listener role. However,any build that uses Octopack fails when executed on the new TeamCity agent. Here is an extract from the build log:
Running command: octo.exe create-release --server
servername:8443 --apikey SECRET --project NRK Bridge (Legacy)
--enableservicemessages --version 0.0.0.662 --deployto Dev --waitfordeployment --package=NRK.Bridge.Web:0.0.0.662 --packageversion=0.0.0.662
[12:06:02]Creating Octopus Deploy release
[12:06:02]Octopus Deploy Command Line Tool, version 2.0.8.22
[12:06:03]Handshaking with Octopus server: servername:8443
[12:06:06]The following certificate errors were
encountered when establishing the HTTPS connection to the server:
RemoteCertificateChainErrors
[12:06:06]Certificate subject name: CN=servername
[12:06:06]Certificate thumbprint: 79C26(...)
[12:06:07]The following certificate errors were encountered when
establishing the HTTPS connection to the server:
RemoteCertificateChainErrors
[12:06:07]Certificate subject name: CN=servername
[12:06:07]Certificate thumbprint: 79C26(...)
[12:06:08]The following certificate errors were encountered when
establishing the HTTPS connection to the server:
RemoteCertificateChainErrors
What I noticed is that the certificate thumbprint in the build log is different from thumbprints shown in Octopus server machine page. I tried to generate a new API key and re-register a Tentacle. Am I overlooking something here?
Did you copy the Api key into Team City? The api key is different to thumb prints. Api Key can be found in Octopus Admin section, under users tab.