'unknown failed when trying to push image to jfrog using Azure pipeline
that's my first code trying to build and push docker image to jfrog using Azure pipeline, I configured the service connections with basic ID and PASSWORD and verified successfully, the build was done successfully but the image never been pushed , plz help
here is my code
trigger:
- main
pool:
vmImage: 'ubuntu-latest'
variables:
imageName: 'salahdin.jfrog.io/docker-local'
dockerRegistryServiceConnection : 'Docker'
imageRepository : 'docker-local'
dockerfilePath : Dockerfile
artifactoryServiceConnection : 'jfrog'
targetRepo : 'docker-local'
imageTag : '$(Build.BuildNumber)'
steps:
- task: Docker@2
displayName: "Docker Build"
inputs:
containerRegistry: '$(dockerRegistryServiceConnection)'
repository: '$(imageRepository)'
command: 'build'
Dockerfile: '$(dockerfilePath)'
tags: '$(Build.BuildNumber)'
- task: ArtifactoryDocker@1
displayName: "Docker push"
inputs:
command: 'push'
artifactoryService: '$(artifactoryServiceConnection)'
targetRepo: '$(targetRepo)'
imageName: '$(imageName):$(imageTag)'
here is my logs the build
Starting: Docker push
==============================================================================
Task : Artifactory Docker
Description : Pull and push docker images from and to Artifactory, while allowing to collect build-info. The collected build-info can be later published to Artifactory by the "Artifactory Publish Build Info" task.
Version : 1.13.6
Author : JFrog
Help : [More Information](https://www.jfrog.com/confluence/display/JFROG/Artifactory+Azure+DevOps+Extension#ArtifactoryAzureDevOpsExtension-PushingandPullingDockerImagestoandfromArtifactory)
==============================================================================
Downloading: https://releases.jfrog.io/artifactory/jfrog-cli/v1/1.53.2/jfrog-cli-linux-386/jfrog
Caching tool: jfrog 1.53.2 x64
Running jfrog-cli from /opt/hostedtoolcache/jfrog/1.53.2/x64/jfrog.
JFrog CLI version: 1.53.2
Executing JFrog CLI Command: /opt/hostedtoolcache/jfrog/1.53.2/x64/jfrog rt dp "salahdin.jfrog.io/docker-local:20220512.22" "docker-local" --url="https://salahdin.jfrog.io/a" --user='***' --password=***
WARNING! Your password will be stored unencrypted in /home/vsts/.docker/config.json.
Configure a credential helper to remove this warning. See
https://docs.docker.com/engine/reference/commandline/login/#credentials-store
Login Succeeded
The push refers to repository [salahdin.jfrog.io/docker-local]
feb57d363211: Preparing
98c84706d0f7: Preparing
4311f0ea1a86: Preparing
6d049f642241: Preparing
3158f7304641: Preparing
fd95118eade9: Preparing
fd95118eade9: Waiting
98c84706d0f7: Retrying in 5 seconds
6d049f642241: Retrying in 5 seconds
3158f7304641: Retrying in 5 seconds98c84706d0f7: Retrying in 1 second
feb57d363211: Retrying in 1 second
unknown: Not Found
exit status 1
##[error]Error: Command failed: /opt/hostedtoolcache/jfrog/1.53.2/x64/jfrog rt dp "salahdin.jfrog.io/docker-local:20220512.22" "docker-local" --url="https://salahdin.jfrog.io/a" --user='***' --password=***
Finishing: Docker push
RESOLVED , it solved by imageName: 'salahdin.jfrog.io/docker-local/my-image' imageRepository : 'dockerlocal/my-image'
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
