jordansissel/fpm · error · FPM::InvalidPackageConfiguration

Cannot package the path '#{File.join(chdir, source)}', does

Error message

Cannot package the path '#{File.join(chdir, source)}', does it exist?

What it means

Error "Cannot package the path '#{File.join(chdir, source)}', does it exist?" thrown in jordansissel/fpm.

Source

Thrown at lib/fpm/package/dir.rb:73

        source = File.basename(origin)
      end
    else
      source, destination = path, "/"
    end

    if attributes[:prefix]
      destination = File.join(attributes[:prefix], destination)
    end

    destination = File.join(staging_path, destination)

    logger["method"] = "input"
    begin
      ::Dir.chdir(chdir) do
        begin
          clone(source, destination)
        rescue Errno::ENOENT => e
          raise FPM::InvalidPackageConfiguration,
            "Cannot package the path '#{File.join(chdir, source)}', does it exist?"
        end
      end
    rescue Errno::ENOENT => e
      raise FPM::InvalidPackageConfiguration,
        "Cannot chdir to '#{chdir}'. Does it exist?"
    end

    # Set some defaults. This is useful because other package types
    # can include license data from themselves (rpms, gems, etc),
    # but to make sure a simple dir -> rpm works without having
    # to specify a license.
    self.license ||= "unknown"
    self.vendor ||= [ENV["USER"], Socket.gethostname].join("@")
  ensure
    # Clean up any logger context we added.
    logger.remove("method")
  end # def input

View on GitHub (pinned to b6d77ba72a)

When it happens

Trigger: Thrown at lib/fpm/package/dir.rb:73 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of jordansissel/fpm@b6d77ba72a (2026-08-21). Data as JSON: /api/errors/8ce1b917557580fb. Report an issue: GitHub.