I’m unable to perform any actions with Octopus deploy from my Azure DevOps pipelines.
- I’m using a cloud free tier for the experiment
- I have a new Space created there
- I have an API key created with no expiration date as per this page
- I have created a new Azure DevOps project
- I have followed the steps and installed the extenstion
I created a new service connection and put he following data into the UI:
Server URL: https://cloud-eng.octopus.app/
API key: API-2JEPxxxxxxxxxxxxxx <- redacted for this post, but I’m pasting a full key
Service connection name: Cloud-Eng Octopus
I double checked that the api key is valid (used it with Octopus Terraform provider) and I can confirm that this token is active:
Now I’m trying to push a build artifact to Octopus. I have the following Pipeline step:
jobs: - job: octopus steps: - download: current artifact: 'drop' - task: OctopusPush@4 inputs: OctoConnectedServiceName: $(octopusConnection) Space: '$(octopusSpaces)' Package: '$(Pipeline.Workspace)/drop/$(Build.BuildId).zip' Replace: 'false'
this task fails with the error:
Octopus Deploy Command Line Tool, version 7.4.4 Detected automation environment: "AzureDevOps" The API key you provided was not valid. Please double-check your API key and try again. For instructions on finding your API key, please visit: https://g.octopushq.com/ApiKey Exit code: -5
The same problem I observe when trying to configure this step via UI: