Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rootless: tagging of built image doesn't seem to work #2636

Closed
dustymabe opened this issue Mar 13, 2019 · 10 comments
Closed

rootless: tagging of built image doesn't seem to work #2636

dustymabe opened this issue Mar 13, 2019 · 10 comments
Labels
kind/bug Categorizes issue or PR as related to a bug. locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments.

Comments

@dustymabe
Copy link
Contributor

/kind bug

Description

I run podman build . -t sync2jira I expect the resulting image to get the tag. It doesn't. For example I saw:

STEP 25: FROM a2ca749662b4fbe156cef473e586072f3c56cfd94d42c74ae968b3b5441911f0
STEP 26: CMD ["/usr/local/bin/sync2jira"]
--> cf2c605849dc1442f2783e9337d4bcb9578ed1319fa05c52242e089ed2226095
STEP 27: COMMIT
[dustymabe@media sync2jira (dusty *%)]$ podman images
REPOSITORY                                 TAG      IMAGE ID       CREATED             SIZE
<none>                                     <none>   cf2c605849dc   52 seconds ago      924 MB
<none>                                     <none>   8c3a9bb5bf74   About an hour ago   439 MB
localhost/sync2jira                        latest   0ed4a4f539e2   About an hour ago   439 MB

Steps to reproduce the issue:

  1. podman build . -t sync2jira

  2. podman images

Output of podman version:

[dustymabe@media sync2jira (dusty *%)]$ rpm -q podman
podman-1.1.2-1.git0ad9b6b.fc29.x86_64
[dustymabe@media sync2jira (dusty *%)]$ podman version
Version:            1.1.2
RemoteAPI Version:  1
Go Version:         go1.11.5
Git Commit:         a95a49d3038462d033f84ac314ec8a3064a99cff
Built:              Tue Mar  5 13:10:31 2019
OS/Arch:            linux/amd64

Output of podman info --debug:

[dustymabe@media sync2jira (dusty *%)]$ podman info --debug
debug:
  compiler: gc
  git commit: a95a49d3038462d033f84ac314ec8a3064a99cff
  go version: go1.11.5
  podman version: 1.1.2
host:
  BuildahVersion: 1.7.1
  Conmon:
    package: podman-1.1.2-1.git0ad9b6b.fc29.x86_64
    path: /usr/libexec/podman/conmon
    version: 'conmon version 1.12.0-dev, commit: a95a49d3038462d033f84ac314ec8a3064a99cff'
  Distribution:
    distribution: fedora
    version: "29"
  MemFree: 2131562496
  MemTotal: 20999905280
  OCIRuntime:
    package: runc-1.0.0-68.dev.git6635b4f.fc29.x86_64
    path: /usr/bin/runc
    version: |-
      runc version 1.0.0-rc6+dev
      commit: ef9132178ccc3d2775d4fb51f1e431f30cac1398-dirty
      spec: 1.0.1-dev
  SwapFree: 4294963200
  SwapTotal: 4294963200
  arch: amd64
  cpus: 8
  hostname: media
  kernel: 4.20.14-200.fc29.x86_64
  os: linux
  rootless: true
  uptime: 8h 19m 18.88s (Approximately 0.33 days)
insecure registries:
  registries: []
registries:
  registries:
  - docker.io
  - registry.fedoraproject.org
  - quay.io
  - registry.access.redhat.com
  - registry.centos.org
store:
  ConfigFile: /home/dustymabe/.config/containers/storage.conf
  ContainerStore:
    number: 18
  GraphDriverName: overlay
  GraphOptions:
  - overlay.mount_program=/usr/bin/fuse-overlayfs
  GraphRoot: /var/b/dustymabe-config-containers/storage
  GraphStatus:
    Backing Filesystem: extfs
    Native Overlay Diff: "false"
    Supports d_type: "true"
    Using metacopy: "false"
  ImageStore:
    number: 32
  RunRoot: /run/user/1001
  VolumePath: /home/dustymabe/.local/share/containers/storage/volumes

@openshift-ci-robot openshift-ci-robot added the kind/bug Categorizes issue or PR as related to a bug. label Mar 13, 2019
@rhatdan
Copy link
Member

rhatdan commented Mar 14, 2019

Am I missing something?

localhost/sync2jira latest 0ed4a4f539e2 About an hour ago 439 MB
Looks like the tag?

@dustymabe
Copy link
Contributor Author

Right. I had previously run podman build . and podman image tag 0ed4a4f539e2 an hour before. This was a subsequent run of podman build . -t sync2jira that occured 52 seconds ago and created cf2c605849dc. It's subtle, but you can see it in the output I pasted.

@mheon
Copy link
Member

mheon commented Mar 14, 2019

@dustymabe If you remove the tagged image, is it tagged again?

I wonder if we're refusing to tag because the image in question already exists

@dustymabe
Copy link
Contributor Author

dustymabe commented Mar 14, 2019

@dustymabe If you remove the tagged image, is it tagged again?

Nope.

[dustymabe@media sync2jira (dusty *%)]$ podman images                                                                                                                                                                                                                                                                                                                    
REPOSITORY                                 TAG      IMAGE ID       CREATED        SIZE                                                                                                                                                                                                                                                                                    
<none>                                     <none>   8c3a9bb5bf74   18 hours ago   439 MB                                                                                                                                                                                                                                                                                 
docker.io/library/fedora                   latest   d09302f77cfc   2 days ago     283 MB                                                                                                                                                                                                                                                                                 
registry.fedoraproject.org/fedora          29       69c5db8b64a7   2 months ago   283 MB                                                                                                                                                                                                                                                                                 
registry.centos.org/centos                 7        719ea9c10b97   2 months ago   210 MB                                                                                                                                                                                                                                                                                 
quay.io/factory2/sync2jira-jenkins-slave   latest   55ea5c07ce83   6 months ago   1.33 GB                                                                                                                                                                                                                                                                                
[dustymabe@media sync2jira (dusty *%)]$                                                                                                                                                                                                                                                                                                                                  
[dustymabe@media sync2jira (dusty *%)]$ podman build . -t sync2jira                                                                                                                                                                                                                                                                                                      
STEP 1: FROM fedora:latest
.
.
.

STEP 26: CMD ["/usr/local/bin/sync2jira"]
--> d5a8f69516dbcf08836e99a0112656ec2ca811965e4db167fa47c76e88c09af2
STEP 27: COMMIT
[dustymabe@media sync2jira (dusty *%)]$ podman images
REPOSITORY                                 TAG      IMAGE ID       CREATED          SIZE
<none>                                     <none>   d5a8f69516db   17 seconds ago   924 MB
<none>                                     <none>   8c3a9bb5bf74   18 hours ago     439 MB
docker.io/library/fedora                   latest   d09302f77cfc   2 days ago       283 MB
registry.fedoraproject.org/fedora          29       69c5db8b64a7   2 months ago     283 MB
registry.centos.org/centos                 7        719ea9c10b97   2 months ago     210 MB
quay.io/factory2/sync2jira-jenkins-slave   latest   55ea5c07ce83   6 months ago     1.33 GB

I wonder if we're refusing to tag because the image in question already exists

If that were the case it would still be a bug, right?

@giuseppe
Copy link
Member

I added the rootless label too early, I can reproduce with root as well

@giuseppe giuseppe removed the rootless label Mar 14, 2019
@mheon
Copy link
Member

mheon commented Mar 14, 2019

@dustymabe Would definitely still have been a bug, though a different kind

@giuseppe
Copy link
Member

it is cobra messing up I think.

the order matters: podman build . -t sync2jira fails while podman build -t sync2jira . works

@mheon
Copy link
Member

mheon commented Mar 14, 2019

Is Build missing SetInterspersed?

@giuseppe
Copy link
Member

yes, I am preparing a PR right now

giuseppe added a commit to giuseppe/libpod that referenced this issue Mar 14, 2019
accept also the order "build DIR -t TAG"

Closes: containers#2636

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
@giuseppe
Copy link
Member

PR here: #2646

giuseppe added a commit to giuseppe/libpod that referenced this issue Mar 15, 2019
accept also the order "build DIR -t TAG"

Closes: containers#2636

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
giuseppe added a commit to giuseppe/libpod that referenced this issue Mar 15, 2019
accept also the order "build DIR -t TAG"

Closes: containers#2636

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
muayyad-alsadi pushed a commit to muayyad-alsadi/libpod that referenced this issue Apr 21, 2019
accept also the order "build DIR -t TAG"

Closes: containers#2636

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
@github-actions github-actions bot added the locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. label Sep 24, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 24, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
kind/bug Categorizes issue or PR as related to a bug. locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments.
Projects
None yet
Development

No branches or pull requests

5 participants