Error while building the jenkins.io

$ make
./scripts/ruby pull
3.2.2: Pulling from library/ruby
Digest: sha256:db6b1e15eabeae7672ba3844471a0f1cb4eb6f6f5438fe5b8e8696a2a4376708
Status: Image is up to date for ruby:3.2.2
docker.io/library/ruby:3.2.2

What’s Next?
View a summary of image vulnerabilities and recommendations → docker scout quickview ruby:3.2.2
./scripts/ruby bundle config set --local path ‘vendor/gems’
docker: Error response from daemon: the working directory ‘C:/Users/srid0/jenkins.io’ is invalid, it needs to be an absolute path.
See ‘docker run --help’.
make: *** [build/ruby] Error 125

I Encounter this error when I build the jenkins.io using “make” command.
OS: Windows

Most of the maintainers of the www.jenkins.io site use a Unix variant for their development. You’re more likely to have a successful experience there if you choose a Unix variant. That might be Windows Subsytem for Linux. It might be a Linux virtual machine running on your Linux computer. It might be a Gitpod started from the guidance in “Getting Started”

Additionally, I recommend taking a look at make help to generate a list of commands you can use to generate the site.

Thank you, @MarkEWaite and @NotMyFault, for your insights in solving the issue. I am pleased to confirm that I have successfully resolved the problem.

I encountered the issue in the following manner:

  1. Installed a Linux distribution within Windows using WSL.
    To install follow the instructions click here
  2. Now clone the project inside the Linux terminal (ubuntu in my case) in /usr/src directory.
  3. In my initial attempt, I overlooked the use of the ‘sudo’ command to build the project.

For Building the project:

make

changed to

sudo make

For running the live server:

make run

changed to

sudo make run

Finally, the project is live on local host (PORT: 4242)

for more details visit: Contribution Page

Feel free to contact me with any questions related to this issue.

You should not need to use sudo to run the site with make run.

One of your mistakes may be your choice to clone the project into /usr/src. The /usr directory is generally considered to be a system directory that should not contain the working directories of users.

Does it behave better if you clone the repository into your home directory instead?

Initially, I mistakenly altered the permissions between the root and user in the Linux terminal, which prompted me to use sudo for certain commands. Subsequently, I decided to uninstall all my Linux distributions and then reinstall them.
I believed it would be more appropriate to clone it into /usr/src due to the specified path in the Dockerfile.

WORKDIR /usr/src/jenkinsio

I am entirely new to both the Linux environment and Docker, and I was unaware that the /usr/src directory should not contain user working directories.

To provide some clarification, the project is still running correctly even when located inside the /usr/src directory.

Thank you for guiding me, @MarkEWaite.