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

Error: unable to get createdBy for the node: generating checksum for directory "${_INPUTPATH_1:?}" in "/var/tmp/libpod_builder3320502583/build": lstat /var/tmp/libpod_builder3320502583/build/${_INPUTPATH_1:?}: no such file or directory #25425

Open
sanmai-NL opened this issue Feb 28, 2025 · 4 comments
Labels
kind/bug Categorizes issue or PR as related to a bug. macos MacOS (OSX) related regression remote Problem is in podman-remote v5.4

Comments

@sanmai-NL
Copy link
Contributor

sanmai-NL commented Feb 28, 2025

Issue Description

Build args seem to no longer be resolved under some condition.

Steps to reproduce the issue

Steps to reproduce the issue

  1. Create Containerfile:
FROM scratch
ARG DISTRO=ubuntu
ARG _INPUTPATH_1=_template/k8s/${DISTRO:?}/packages_production_1.txt
RUN \
  --mount=type=tmpfs,destination=/tmp/,tmpfs-size=128m \
  --mount=type=bind,source=${_INPUTPATH_1:?},target=/tmp/${_INPUTPATH_1:?}${SELINUXRELABEL} \
  echo Test
  1. podman build .

Describe the results you received

[Error: unable to get createdBy for the node: generating checksum for directory "${_INPUTPATH_1:?}" in "/var/tmp/libpod_builder3320502583/build": lstat /var/tmp/libpod_builder3320502583/build/${_INPUTPATH_1:?}: no such file or directory](https://github.com/containers/podman/issues/25425#top)

Describe the results you expected

Build args resolved.

podman info output

Client:
  APIVersion: 5.4.0
  BuildOrigin: brew
  Built: 1739290083
  BuiltTime: Tue Feb 11 17:08:03 2025
  GitCommit: ""
  GoVersion: go1.23.6
  Os: darwin
  OsArch: darwin/arm64
  Version: 5.4.0
host:
  arch: arm64
  buildahVersion: 1.39.0
  cgroupControllers:
  - cpuset
  - cpu
  - io
  - memory
  - pids
  - rdma
  - misc
  cgroupManager: systemd
  cgroupVersion: v2
  conmon:
    package: conmon-2.1.12-3.fc41.aarch64
    path: /usr/bin/conmon
    version: 'conmon version 2.1.12, commit: '
  cpuUtilization:
    idlePercent: 98.09
    systemPercent: 0.87
    userPercent: 1.04
  cpus: 6
  databaseBackend: sqlite
  distribution:
    distribution: fedora
    variant: coreos
    version: "41"
  eventLogger: journald
  freeLocks: 2048
  hostname: localhost.localdomain
  idMappings:
    gidmap: null
    uidmap: null
  kernel: 6.12.9-200.fc41.aarch64
  linkmode: dynamic
  logDriver: journald
  memFree: 11649462272
  memTotal: 12502654976
  networkBackend: netavark
  networkBackendInfo:
    backend: netavark
    dns:
      package: aardvark-dns-1.13.1-1.fc41.aarch64
      path: /usr/libexec/podman/aardvark-dns
      version: aardvark-dns 1.13.1
    package: netavark-1.13.1-1.fc41.aarch64
    path: /usr/libexec/podman/netavark
    version: netavark 1.13.1
  ociRuntime:
    name: crun
    package: crun-1.19.1-1.fc41.aarch64
    path: /usr/bin/crun
    version: |-
      crun version 1.19.1
      commit: 3e32a70c93f5aa5fea69b50256cca7fd4aa23c80
      rundir: /run/crun
      spec: 1.0.0
      +SYSTEMD +SELINUX +APPARMOR +CAP +SECCOMP +EBPF +CRIU +LIBKRUN +WASM:wasmedge +YAJL
  os: linux
  pasta:
    executable: /usr/bin/pasta
    package: passt-0^20241211.g09478d5-1.fc41.aarch64
    version: |
      pasta 0^20241211.g09478d5-1.fc41.aarch64-pasta
      Copyright Red Hat
      GNU General Public License, version 2 or later
        <https://www.gnu.org/licenses/old-licenses/gpl-2.0.html>
      This is free software: you are free to change and redistribute it.
      There is NO WARRANTY, to the extent permitted by law.
  remoteSocket:
    exists: true
    path: unix:///run/podman/podman.sock
  rootlessNetworkCmd: pasta
  security:
    apparmorEnabled: false
    capabilities: CAP_CHOWN,CAP_DAC_OVERRIDE,CAP_FOWNER,CAP_FSETID,CAP_KILL,CAP_NET_BIND_SERVICE,CAP_SETFCAP,CAP_SETGID,CAP_SETPCAP,CAP_SETUID,CAP_SYS_CHROOT
    rootless: false
    seccompEnabled: true
    seccompProfilePath: /usr/share/containers/seccomp.json
    selinuxEnabled: true
  serviceIsRemote: true
  slirp4netns:
    executable: /usr/bin/slirp4netns
    package: slirp4netns-1.3.1-1.fc41.aarch64
    version: |-
      slirp4netns version 1.3.1
      commit: e5e368c4f5db6ae75c2fce786e31eef9da6bf236
      libslirp: 4.8.0
      SLIRP_CONFIG_VERSION_MAX: 5
      libseccomp: 2.5.5
  swapFree: 0
  swapTotal: 0
  uptime: 0h 6m 58.00s
  variant: v8
plugins:
  authorization: null
  log:
  - k8s-file
  - none
  - passthrough
  - journald
  network:
  - bridge
  - macvlan
  - ipvlan
  volume:
  - local
registries:
  search:
  - docker.io
store:
  configFile: /usr/share/containers/storage.conf
  containerStore:
    number: 0
    paused: 0
    running: 0
    stopped: 0
  graphDriverName: overlay
  graphOptions:
    overlay.additionalImageStores:
    - /usr/lib/containers/storage
    overlay.imagestore: /usr/lib/containers/storage
    overlay.mountopt: nodev,metacopy=on
  graphRoot: /var/lib/containers/storage
  graphRootAllocated: 240633720832
  graphRootUsed: 7091646464
  graphStatus:
    Backing Filesystem: xfs
    Native Overlay Diff: "false"
    Supports d_type: "true"
    Supports shifting: "true"
    Supports volatile: "true"
    Using metacopy: "true"
  imageCopyTmpDir: /var/tmp
  imageStore:
    number: 1
  runRoot: /run/containers/storage
  transientStore: false
  volumePath: /var/lib/containers/storage/volumes
version:
  APIVersion: 5.4.0
  BuildOrigin: Fedora Project
  Built: 1739232000
  BuiltTime: Tue Feb 11 00:00:00 2025
  GitCommit: ""
  GoVersion: go1.23.5
  Os: linux
  OsArch: linux/arm64
  Version: 5.4.0

podman version

Client:        Podman Engine
Version:       5.4.0
API Version:   5.4.0
Go Version:    go1.23.6
Built:         Tue Feb 11 17:08:03 2025
Build Origin:  brew
OS/Arch:       darwin/arm64

Server:       Podman Engine
Version:      5.4.0
API Version:  5.4.0
Go Version:   go1.23.5
Built:        Tue Feb 11 01:00:00 2025
OS/Arch:      linux/arm64

Podman in a container

No

Privileged Or Rootless

None

Upstream Latest Release

Yes

Additional environment details

Additional environment details

Additional information

This started occurring once I initialized the Podman machine. But that could be a coincidence.

[
     {
          "ConfigDir": {
               "Path": "/Users/sanderhan/.config/containers/podman/machine/applehv"
          },
          "ConnectionInfo": {
               "PodmanSocket": {
                    "Path": "/var/folders/zc/xlgtzcwj0xvd9p8h4_mh3b0w0000gn/T/podman/podman-machine-default-api.sock"
               },
               "PodmanPipe": null
          },
          "Created": "2025-02-28T16:41:22.082682+01:00",
          "LastUp": "0001-01-01T00:00:00Z",
          "Name": "podman-machine-default",
          "Resources": {
               "CPUs": 6,
               "DiskSize": 225,
               "Memory": 12288,
               "USBs": []
          },
          "SSHConfig": {
               "IdentityPath": "/Users/myuser/.local/share/containers/podman/machine/machine",
               "Port": 60507,
               "RemoteUsername": "core"
          },
          "State": "running",
          "UserModeNetworking": true,
          "Rootful": true,
          "Rosetta": true
     }
]
@sanmai-NL sanmai-NL added the kind/bug Categorizes issue or PR as related to a bug. label Feb 28, 2025
@github-actions github-actions bot added macos MacOS (OSX) related remote Problem is in podman-remote labels Feb 28, 2025
@Luap99
Copy link
Member

Luap99 commented Feb 28, 2025

Are you saying this is a new issue? And it worked in previous versions? If you created a new VM it would pull the new machine image with podman 5.4.0 and AFAIK the checksum caching logic was just recently added there.

@flouthoc PTAL Looks like the new cache is not expanding the args?

@baude
Copy link
Member

baude commented Feb 28, 2025

if you ssh into the machine and run your reproducer, what happens ?

@sanmai-NL
Copy link
Contributor Author

@baude

That seems to work normally:

$ podman machine ssh
Connecting to vm podman-machine-default. To close connection, use `~.` or `exit`
Fedora CoreOS 41.20250117.3.0
Tracker: https://github.com/coreos/fedora-coreos-tracker
Discuss: https://discussion.fedoraproject.org/tag/coreos

Last login: Fri Feb 28 15:41:55 2025
root@localhost:~# nano Containerfile
root@localhost:~# podman build .
STEP 1/4: FROM scratch
STEP 2/4: ARG DISTRO=ubuntu
--> f715eb5a8598
STEP 3/4: ARG _INPUTPATH_1=_template/k8s/${DISTRO:?}/packages_production_1.txt
--> 25a39bc1f3ab
STEP 4/4: RUN   --mount=type=tmpfs,destination=/tmp/,tmpfs-size=128m   --mount=type=bind,source=${_INPUTPATH_1:?},target=/tmp/${_INPUTPATH_1:?}${SELINUXRELABEL}   echo Test
Error: building at STEP "RUN --mount=type=tmpfs,destination=/tmp/,tmpfs-size=128m --mount=type=bind,source=${_INPUTPATH_1:?},target=/tmp/${_INPUTPATH_1:?}${SELINUXRELABEL} echo Test": resolving mountpoints for container "9e65f7621444cd3fce1ac45fd28769cfc96812bc7e686fd3e9ab2b7493bf1ef4": sanitizing bind subdirectory "/root/_template/k8s/ubuntu/packages_production_1.txt": opening directory "_template/k8s/ubuntu/packages_production_1.txt" under "/root": no such file or directory: no such file or directory

@sanmai-NL
Copy link
Contributor Author

Are you saying this is a new issue? And it worked in previous versions? If you created a new VM it would pull the new machine image with podman 5.4.0 and AFAIK the checksum caching logic was just recently added there.

@flouthoc PTAL Looks like the new cache is not expanding the args?

@Luap99: Yes, it's a new issue. The Containerfile is identical to the one I've used many times over last few versions of Podman.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Categorizes issue or PR as related to a bug. macos MacOS (OSX) related regression remote Problem is in podman-remote v5.4
Projects
None yet
Development

No branches or pull requests

3 participants