GoogleCloudPlatform / gcsfuse

A user-space file system for interacting with Google Cloud Storage

Home Page:https://cloud.google.com/storage/docs/gcs-fuse

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Error Encountered When Mounting GCS Bucket using gcsfuse on Cloud Run following Official Tutorial

kojima-takeo opened this issue · comments

I have been following the official tutorial Using Cloud Storage FUSE with Cloud Run to mount a Google Cloud Storage bucket using gcsfuse on Cloud Run, and encountered an error during the deployment process.

Here's the Dockerfile snippet based on the tutorial:

Dockerfile

FROM python:3.11-buster

Install system dependencies

RUN set -e;
apt-get update -y && apt-get install -y
tini
lsb-release;
gcsFuseRepo=gcsfuse-lsb_release -c -s;
echo "deb http://packages.cloud.google.com/apt $gcsFuseRepo main" |
tee /etc/apt/sources.list.d/gcsfuse.list;
curl https://packages.cloud.google.com/apt/doc/apt-key.gpg |
apt-key add -;
apt-get update;
apt-get install -y gcsfuse
&& apt-get clean

Set fallback mount directory

ENV MNT_DIR /mnt/gcs
...

During the deployment, I received the following error:

E: Failed to fetch http://packages.cloud.google.com/apt/pool/gcsfuse-buster/gcsfuse_1.2.0_amd64_0e91d38c68c91349633d37c17e1586e6.deb 502 Bad Gateway [IP: xxx.xxx.xx.xxx 80]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?

The error log suggests a failure in fetching the gcsfuse package due to a 502 Bad Gateway error. I tried running apt-get update and --fix-missing as suggested by the error message, but the issue persists.

Any help to resolve this issue would be greatly appreciated as it's crucial for our application to have a mounted GCS bucket for storing and accessing data.

This should more likely be called, unable to install gcsFuse from the repo. In any case it's happening to me as well, and is breaking my ability to deploy workloads based on the docker image. I'm surprisedf the internet is not BLOWING up about this!

@rmoskal Thank you for sharing your experience, and I appreciate the suggestion to rephrase the issue to highlight the problem with installing gcsfuse from the repo. It seems like this is a recent occurrence as the Dockerfile worked perfectly up until a week ago, with the issue starting around 2-3 days ago.

I share your surprise regarding the lack of widespread discussion on this matter, which may indeed suggest a limited number of users mounting GCS on Cloud Run with gcsfuse. However, the impact is significant for those of us relying on this setup for our applications.

I hope this issue gains the necessary attention for a prompt resolution. In the meantime, if anyone has discovered a workaround or alternative approach to mount GCS on Cloud Run, sharing it here would be immensely beneficial. Thank you again for your input and shared concern.

There may be another reason why the internet is quiet. If you had previously built the docker image on a machine then the earlier stages like installing gcsfuse would be in your docker cache and wouldn't be run again unless you specified --no-cache when building.

Many people building locally wouldn't be affected. Folks doing it for the first time or in a CI/CD environment, would. I'm affected because I recently changed computers.

Thanks @kojima-takeo & @rmoskal for reporting the issue. We are investigating the issue and update here with fix as soon as possible.
Meanwhile, could you please try using the below code for installing GCSFuse in your Ubuntu/Debian based Dockerfile:

ENV GCSFUSE_VERSION=1.2.0

RUN apt-get update -y && \
    curl -LJO "https://github.com/GoogleCloudPlatform/gcsfuse/releases/download/v${GCSFUSE_VERSION}/gcsfuse_${GCSFUSE_VERSION}_amd64.deb" && \
    apt-get -y install fuse && \
    apt-get clean && \
    dpkg -i "gcsfuse_${GCSFUSE_VERSION}_amd64.deb"

@kojima-takeo for your use-case, the Dockerfile mentioned in #1424 (comment) would look like:

# Use the official lightweight Python image.
# https://hub.docker.com/_/python
FROM python:3.11-buster

# Install system dependencies
ENV GCSFUSE_VERSION=1.2.0

RUN apt-get update -y && \
    curl -LJO "https://github.com/GoogleCloudPlatform/gcsfuse/releases/download/v${GCSFUSE_VERSION}/gcsfuse_${GCSFUSE_VERSION}_amd64.deb" && \
    apt-get -y install fuse tini && \
    apt-get clean && \
    dpkg -i "gcsfuse_${GCSFUSE_VERSION}_amd64.deb"

# Set fallback mount directory
ENV MNT_DIR /mnt/gcs

# Copy local code to the container image.
ENV APP_HOME /app
WORKDIR $APP_HOME
COPY . ./

# Install production dependencies.
RUN pip install -r requirements.txt

# Ensure the script is executable
RUN chmod +x /app/gcsfuse_run.sh

# Use tini to manage zombie processes and signal forwarding
# https://github.com/krallin/tini
ENTRYPOINT ["/usr/bin/tini", "--"]

# Pass the startup script as arguments to Tini
CMD ["/app/gcsfuse_run.sh"]

Please reach out if you face issues with above installations.

That did the trick. We're back in business, literally!

Dear @sethiay and @rmoskal,

Thank you for your prompt responses and the provided workaround. I am grateful to report that by employing the given trick, the deployment was successfully completed following the official tutorial. As @rmoskal pointed out, the quietness on this issue might be due to cached stages from previous builds, which makes a lot of sense.

However, I am still hoping for a resolution that would allow the deployment to proceed smoothly with the previous code, as it's proven to be reliable until the recent hiccup.

On a side note, while the provided trick worked well for this particular project, I am encountering an error in a different project despite applying the same trick. Below is the snippet of the Dockerfile where I replaced the # Install gcsfuse section with the provided trick, but an error occurs:

FROM python:3.11 as builder
ENV PYTHONDONTWRITEBYTECODE=1 \
    PIP_NO_CACHE_DIR=off \
    POETRY_HOME="/opt/poetry"
ENV PATH="${POETRY_HOME}/bin:${PATH}"
RUN python -c 'from urllib.request import urlopen; print(urlopen("https://install.python-poetry.org").read().decode())' | python -
RUN poetry config virtualenvs.create false
WORKDIR /app
COPY pyproject.toml /app/
COPY poetry.lock /app/
RUN poetry install --no-interaction --no-ansi --no-root -vvv
# --without dev 

FROM python:3.11-slim

# Install system dependencies
ENV PYTHONUNBUFFERED=1 \
    PYTHONIOENCODING="UTF-8"

# Install gcsfuse
RUN apt-get update && apt-get install -y curl gnupg lsb-release
RUN echo "deb http://packages.cloud.google.com/apt gcsfuse-buster main" > /etc/apt/sources.list.d/gcsfuse.list
RUN curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key add -
RUN apt-get update && apt-get install -y gcsfuse

WORKDIR /app
COPY . /app/

COPY startup.sh /startup.sh
RUN chmod 744 /startup.sh
CMD ["/startup.sh"]

Error Log:

Step 13/21 : RUN apt-get update -y &&     curl -LJO "https://github.com/GoogleCloudPlatform/gcsfuse/releases/download/v${GCSFUSE_VERSION}/gcsfuse_${GCSFUSE_VERSION}_amd64.deb" &&     apt-get -y install fuse tini &&     apt-get clean &&     dpkg -i "gcsfuse_${GCSFUSE_VERSION}_amd64.deb"
 ---> Running in 810e793ab318
Get:1 http://deb.debian.org/debian bookworm InRelease [151 kB]
Get:2 http://deb.debian.org/debian bookworm-updates InRelease [52.1 kB]
Get:3 http://deb.debian.org/debian-security bookworm-security InRelease [48.0 kB]
Get:4 http://deb.debian.org/debian bookworm/main amd64 Packages [8906 kB]
Get:5 http://deb.debian.org/debian bookworm-updates/main amd64 Packages [6408 B]
Get:6 http://deb.debian.org/debian-security bookworm-security/main amd64 Packages [74.9 kB]
Fetched 9239 kB in 2s (4742 kB/s)
Reading package lists...
/bin/sh: 1: curl: not found
The command '/bin/sh -c apt-get update -y &&     curl -LJO "https://github.com/GoogleCloudPlatform/gcsfuse/releases/download/v${GCSFUSE_VERSION}/gcsfuse_${GCSFUSE_VERSION}_amd64.deb" &&     apt-get -y install fuse tini &&     apt-get clean &&     dpkg -i "gcsfuse_${GCSFUSE_VERSION}_amd64.deb"' returned a non-zero code: 127
ERROR
ERROR: build step 0 "gcr.io/cloud-builders/docker" failed: step exited with non-zero status: 127

I would greatly appreciate any further advice or insights to resolve this issue in the different project. Your assistance has been invaluable and I look forward to any additional guidance you might have to offer.

Thank you once again for your support.

Best regards,

@kojima-takeo I think python:3-11-slim base image doesn't have curl unlike python:3-11, so it's failing with curl not found error.
Given that, could you please try with installing curl also:

FROM python:3.11 as builder
ENV PYTHONDONTWRITEBYTECODE=1 \
    PIP_NO_CACHE_DIR=off \
    POETRY_HOME="/opt/poetry"
ENV PATH="${POETRY_HOME}/bin:${PATH}"
RUN python -c 'from urllib.request import urlopen; print(urlopen("https://install.python-poetry.org").read().decode())' | python -
RUN poetry config virtualenvs.create false
WORKDIR /app
COPY pyproject.toml /app/
COPY poetry.lock /app/
RUN poetry install --no-interaction --no-ansi --no-root -vvv
# --without dev 

FROM python:3.11-slim

# Install system dependencies
ENV PYTHONUNBUFFERED=1 \
    PYTHONIOENCODING="UTF-8"

# Install gcsfuse
ENV GCSFUSE_VERSION=1.2.0

RUN apt-get update -y && \
    apt-get install -y curl && \
    curl -LJO "https://github.com/GoogleCloudPlatform/gcsfuse/releases/download/v${GCSFUSE_VERSION}/gcsfuse_${GCSFUSE_VERSION}_amd64.deb" && \
    apt-get -y install fuse && \
    apt-get clean && \
    dpkg -i "gcsfuse_${GCSFUSE_VERSION}_amd64.deb"

WORKDIR /app
COPY . /app/

COPY startup.sh /startup.sh
RUN chmod 744 /startup.sh
CMD ["/startup.sh"]

Dear @sethiay

Thank you for your continuous support and insight. It was indeed a very basic oversight on my part. I have confirmed that the original code also installs curl. After applying your suggested code once again, I was able to successfully deploy. Your guidance has been invaluable, and I am deeply appreciative.

Thank you for the persistent support which has enabled me to deploy after a week, and I am looking forward to the progression of the project with great anticipation.

Best regards,

This should more likely be called, unable to install gcsFuse from the repo. In any case it's happening to me as well, and is breaking my ability to deploy workloads based on the docker image. I'm surprisedf the internet is not BLOWING up about this!

@rmoskal Request you to please share minimal reproducer in the form of Dockerfile for the issue !

Dear @sethiay

As a temporary workaround, we've switched to an alternative installation method that you suggested. While this has resolved the immediate issue, we understand that it's not the optimal long-term solution.

Could you please notify us when the original issue with the standard installation method (Google APT Repositry Method) has been resolved? We would prefer to switch back to using the recommended installation process to ensure we are always up-to-date with the latest features and security patches.

Thank you for your assistance and looking forward to your positive response.

Best regards,

@sethiay Thank you for your solution, but this issue remains unresolved for me. I am encountering an error with the dpkg -i "gcsfuse_${GCSFUSE_VERSION}_amd64.deb" command, with the following output:

dpkg-deb: error: 'gcsfuse__amd64.deb' is not a Debian format archive
dpkg: error processing archive gcsfuse__amd64.deb (--install):
dpkg-deb --control subprocess returned error exit status 2
Errors were encountered while processing:
gcsfuse__amd64.deb

For more context, I am attempting to execute this in a Google Colab workbook. As with @kojima-takeo, the original deployment as shown in the original question worked well. But only recently did I begin encountering the same error as originally mentioned.

@sethiay Thank you for your solution, but this issue remains unresolved for me. I am encountering an error with the dpkg -i "gcsfuse_${GCSFUSE_VERSION}_amd64.deb" command, with the following output:

dpkg-deb: error: 'gcsfuse__amd64.deb' is not a Debian format archive
dpkg: error processing archive gcsfuse__amd64.deb (--install):
dpkg-deb --control subprocess returned error exit status 2
Errors were encountered while processing:
gcsfuse__amd64.deb

For more context, I am attempting to execute this in a Google Colab workbook. As with @kojima-takeo, the original deployment as shown in the original question worked well. But only recently did I begin encountering the same error as originally mentioned.

@burkelawlor Looking at the error, it seems like GCSFUSE_VERSION is not set. Could you please try (with version set to 1.2.0) ?

# Install gcsfuse
ENV GCSFUSE_VERSION=1.2.0

RUN apt-get update -y && \
    apt-get install -y curl && \
    curl -LJO "https://github.com/GoogleCloudPlatform/gcsfuse/releases/download/v${GCSFUSE_VERSION}/gcsfuse_${GCSFUSE_VERSION}_amd64.deb" && \
    apt-get -y install fuse && \
    apt-get clean && \
    dpkg -i "gcsfuse_${GCSFUSE_VERSION}_amd64.deb"

Re-running this from the docs sorted it for me

export GCSFUSE_REPO=gcsfuse-`lsb_release -c -s`
echo "deb https://packages.cloud.google.com/apt $GCSFUSE_REPO main" | sudo tee /etc/apt/sources.list.d/gcsfuse.list
curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo apt-key add -

Re-running this from the docs sorted it for me

export GCSFUSE_REPO=gcsfuse-`lsb_release -c -s`
echo "deb https://packages.cloud.google.com/apt $GCSFUSE_REPO main" | sudo tee /etc/apt/sources.list.d/gcsfuse.list
curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo apt-key add -

Thanks @Snaver .

@kojima-takeo Could you try if the above fixes the APT installation method for you?

We are working on fixing this issue in cloudrun on our end.

We are facing the same issue. Our pipeline fails since we deactivate the cache during the build. Testing the workaround in progress but still not a long term solution for us.

Having the same issue on Cloud Build, the official docs way of installing seems to still be broken on Cloud Build, but the workaround did fix the issue.

Pretty much all of our Docker images include this step so going back through and updating them all as mentioned is not an ideal solution.

Dear @Snaver and the team,

Thank you for the continuous support and efforts to resolve this issue. I have tried the suggested fix, yet unfortunately, the error with the APT installation method for gcsfuse persists as per the log below:

E: Failed to fetch http://packages.cloud.google.com/apt/pool/gcsfuse-buster/gcsfuse_1.2.0_amd64_0e91d38c68c91349633d37c17e1586e6.deb  502  Bad Gateway [IP: 108.177.98.138 80]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
Fetched 180 kB in 7s (24.3 kB/s)
The command '/bin/sh -c apt-get update && apt-get install -y gcsfuse' returned a non-zero code: 100
ERROR
ERROR: build step 0 "gcr.io/cloud-builders/docker" failed: step exited with non-zero status: 100

It's reassuring to know that you are working on fixing this issue on your end. I am looking forward to a resolution so as to proceed with the deployments seamlessly. If there are any alternative methods or further steps you would recommend in the meantime, I would be very eager to try them.

Thank you once again for your attention to this matter and the ongoing assistance.

Best regards,

I have same problem in docker build.

&& echo "deb http://packages.cloud.google.com/apt gcsfuse-buster main" | tee /etc/apt/sources.list.d/gcsfuse.list
&& curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key add -
&& apt-get install -y gcsfuse=0.41.12

I think its not cloud run related problem but packages.cloud.google.com problem.

Also curl -v http://packages.cloud.google.com/apt/pool/gcsfuse-buster/gcsfuse_0.41.12_amd64_7930815c25b3e7d68ea7ed07aade1764.debgives same error!

*   Trying 209.85.233.101:80...
* Connected to packages.cloud.google.com (209.85.233.101) port 80 (#0)
> GET /apt/pool/gcsfuse-buster/gcsfuse_0.41.12_amd64_7930815c25b3e7d68ea7ed07aade1764.deb HTTP/1.1
> Host: packages.cloud.google.com
> User-Agent: curl/7.81.0
> Accept: */*
> 
* Mark bundle as not supporting multiuse
< HTTP/1.1 502 Bad Gateway
< Content-Type: text/html; charset=UTF-8
< Referrer-Policy: no-referrer
< Content-Length: 1613
< Date: Thu, 12 Oct 2023 08:23:33 GMT
< 

This is a general fault. The packages disappear from packages.cloud.google.com and installing binaries from github without a security check seems a little bit crazy.

When someone from Google will put the files back ?
I mean, for debian/ubuntu, using apt is the officially documented solution (https://cloud.google.com/storage/docs/gcsfuse-install)

Hey @jaakkom & @aamarques . Apologies for the inconvenience here.
The problem is arising due to use of "http://packages.cloud.google.com/" instead of "https://packages.cloud.google.com/" in cloud run's document for installation of GCSFuse (e.g. Node.js Dockerfile).

We are working to get the Cloud run documents updated with the correct and official installation command i.e. (https://cloud.google.com/storage/docs/gcsfuse-install). e.g. we have updated the Python Dockerfile.

Meanwhile, we suggest to use the officially documented installation commands (https://cloud.google.com/storage/docs/gcsfuse-install) or the workarounds mentioned in this issue.

This fixed it for me:
-RUN echo "deb http://packages.cloud.google.com/apt gcsfuse-bionic main" | tee /etc/apt/sources.list.d/gcsfuse.list
+RUN echo "deb https://packages.cloud.google.com/apt gcsfuse-bionic main" | tee /etc/apt/sources.list.d/gcsfuse.list

This fixed it for me: -RUN echo "deb http://packages.cloud.google.com/apt gcsfuse-bionic main" | tee /etc/apt/sources.list.d/gcsfuse.list +RUN echo "deb https://packages.cloud.google.com/apt gcsfuse-bionic main" | tee /etc/apt/sources.list.d/gcsfuse.list

This worked!

http -> https is working!
http://packages.cloud.google.com/apt -> https://packages.cloud.google.com/apt
~

Install gcsfuse

RUN apt-get update && apt-get install -y curl gnupg lsb-release
RUN echo "deb https://packages.cloud.google.com/apt gcsfuse-buster main" > /etc/apt/sources.list.d/gcsfuse.list
RUN curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key add -
RUN apt-get update && apt-get install -y gcsfuse

@sethiay Thanks for your time. You're rigth and was my fault I didn't check this (and mentioned the page).

I changed deb package to https but get a different error of GPG signature.

> [service 4/6] RUN set -e;     apt-get update -y && apt-get install -y     tini     lsb-release;     gcsFuseRepo=gcsfuse-`lsb_release -c -s`;     echo "deb https://packages.cloud.google.com/apt $gcsFuseRepo main" |     tee /etc/apt/sources.list.d/gcsfuse.list;     curl https://packages.cloud.google.com/apt/doc/apt-key.gpg |     apt-key add -;     apt-get update;     apt-get install -y gcsfuse     && apt-get clean:
0.563 Get:1 http://deb.debian.org/debian bookworm InRelease [151 kB]
0.766 Get:2 http://deb.debian.org/debian bookworm-updates InRelease [52.1 kB]
0.824 Get:3 http://deb.debian.org/debian-security bookworm-security InRelease [48.0 kB]
1.299 Err:1 http://deb.debian.org/debian bookworm InRelease
1.299   At least one invalid signature was encountered.
1.728 Err:2 http://deb.debian.org/debian bookworm-updates InRelease
1.728   At least one invalid signature was encountered.
2.230 Err:3 http://deb.debian.org/debian-security bookworm-security InRelease
2.230   At least one invalid signature was encountered.
2.278 Reading package lists...
2.420 W: GPG error: http://deb.debian.org/debian bookworm InRelease: At least one invalid signature was encountered.
2.421 E: The repository 'http://deb.debian.org/debian bookworm InRelease' is not signed.
2.421 W: GPG error: http://deb.debian.org/debian bookworm-updates InRelease: At least one invalid signature was encountered.
2.421 E: The repository 'http://deb.debian.org/debian bookworm-updates InRelease' is not signed.
2.421 W: GPG error: http://deb.debian.org/debian-security bookworm-security InRelease: At least one invalid signature was encountered.
2.421 E: The repository 'http://deb.debian.org/debian-security bookworm-security InRelease' is not signed.
2.427 /bin/sh: 1: lsb_release: not found
------
Dockerfile:20
--------------------
  19 |     COPY --from=build /venv /venv
  20 | >>> RUN set -e; \
  21 | >>>     apt-get update -y && apt-get install -y \
  22 | >>>     tini \
  23 | >>>     lsb-release; \
  24 | >>>     gcsFuseRepo=gcsfuse-`lsb_release -c -s`; \
  25 | >>>     echo "deb https://packages.cloud.google.com/apt $gcsFuseRepo main" | \
  26 | >>>     tee /etc/apt/sources.list.d/gcsfuse.list; \
  27 | >>>     curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | \
  28 | >>>     apt-key add -; \
  29 | >>>     apt-get update; \
  30 | >>>     apt-get install -y gcsfuse \
  31 | >>>     && apt-get clean
  32 |     COPY . .
--------------------
ERROR: failed to solve: process "/bin/sh -c set -e;     apt-get update -y && apt-get install -y     tini     lsb-release;     gcsFuseRepo=gcsfuse-`lsb_release -c -s`;     echo \"deb https://packages.cloud.google.com/apt $gcsFuseRepo main\" |     tee /etc/apt/sources.list.d/gcsfuse.list;     curl https://packages.cloud.google.com/apt/doc/apt-key.gpg |     apt-key add -;     apt-get update;     apt-get install -y gcsfuse     && apt-get clean" did not complete successfully: exit code: 127
MAKE[1]: *** [docker-build] Error 1
make: *** [service] Error 2

E: The repository 'http://deb.debian.org/debian bookworm InRelease' is not signed.

Hi @sytranvn,

The issue you're facing seems unrelated to this thread. Please try the solutions mentioned in this Stack Overflow question: https://stackoverflow.com/questions/62473932/at-least-one-invalid-signature-was-encountered

If the mentioned solutions don't resolve the issue, please open a separate bug report with the steps to reproduce (Dockerfile).

Thanks!

Closing this issue now. since, public documentation has been updated with the trick (http -> https).

Ref - https://cloud.google.com/run/docs/tutorials/network-filesystems-fuse#cloudrun_fs_dockerfile-nodejs

Please feel free to reopen the issue if you are still experiencing this issue.

Dear @sethiay and @rmoskal,

Thank you for your prompt responses and the provided workaround. I am grateful to report that by employing the given trick, the deployment was successfully completed following the official tutorial. As @rmoskal pointed out, the quietness on this issue might be due to cached stages from previous builds, which makes a lot of sense.

However, I am still hoping for a resolution that would allow the deployment to proceed smoothly with the previous code, as it's proven to be reliable until the recent hiccup.

On a side note, while the provided trick worked well for this particular project, I am encountering an error in a different project despite applying the same trick. Below is the snippet of the Dockerfile where I replaced the # Install gcsfuse section with the provided trick, but an error occurs:

FROM python:3.11 as builder
ENV PYTHONDONTWRITEBYTECODE=1 \
    PIP_NO_CACHE_DIR=off \
    POETRY_HOME="/opt/poetry"
ENV PATH="${POETRY_HOME}/bin:${PATH}"
RUN python -c 'from urllib.request import urlopen; print(urlopen("https://install.python-poetry.org").read().decode())' | python -
RUN poetry config virtualenvs.create false
WORKDIR /app
COPY pyproject.toml /app/
COPY poetry.lock /app/
RUN poetry install --no-interaction --no-ansi --no-root -vvv
# --without dev 

FROM python:3.11-slim

# Install system dependencies
ENV PYTHONUNBUFFERED=1 \
    PYTHONIOENCODING="UTF-8"

# Install gcsfuse
RUN apt-get update && apt-get install -y curl gnupg lsb-release
RUN echo "deb http://packages.cloud.google.com/apt gcsfuse-buster main" > /etc/apt/sources.list.d/gcsfuse.list
RUN curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key add -
RUN apt-get update && apt-get install -y gcsfuse

WORKDIR /app
COPY . /app/

COPY startup.sh /startup.sh
RUN chmod 744 /startup.sh
CMD ["/startup.sh"]

Error Log:

Step 13/21 : RUN apt-get update -y &&     curl -LJO "https://github.com/GoogleCloudPlatform/gcsfuse/releases/download/v${GCSFUSE_VERSION}/gcsfuse_${GCSFUSE_VERSION}_amd64.deb" &&     apt-get -y install fuse tini &&     apt-get clean &&     dpkg -i "gcsfuse_${GCSFUSE_VERSION}_amd64.deb"
 ---> Running in 810e793ab318
Get:1 http://deb.debian.org/debian bookworm InRelease [151 kB]
Get:2 http://deb.debian.org/debian bookworm-updates InRelease [52.1 kB]
Get:3 http://deb.debian.org/debian-security bookworm-security InRelease [48.0 kB]
Get:4 http://deb.debian.org/debian bookworm/main amd64 Packages [8906 kB]
Get:5 http://deb.debian.org/debian bookworm-updates/main amd64 Packages [6408 B]
Get:6 http://deb.debian.org/debian-security bookworm-security/main amd64 Packages [74.9 kB]
Fetched 9239 kB in 2s (4742 kB/s)
Reading package lists...
/bin/sh: 1: curl: not found
The command '/bin/sh -c apt-get update -y &&     curl -LJO "https://github.com/GoogleCloudPlatform/gcsfuse/releases/download/v${GCSFUSE_VERSION}/gcsfuse_${GCSFUSE_VERSION}_amd64.deb" &&     apt-get -y install fuse tini &&     apt-get clean &&     dpkg -i "gcsfuse_${GCSFUSE_VERSION}_amd64.deb"' returned a non-zero code: 127
ERROR
ERROR: build step 0 "gcr.io/cloud-builders/docker" failed: step exited with non-zero status: 127

I would greatly appreciate any further advice or insights to resolve this issue in the different project. Your assistance has been invaluable and I look forward to any additional guidance you might have to offer.

Thank you once again for your support.

Best regards,

This is due the HTTP URL being used we need to use https
> RUN echo "deb http://packages.cloud.google.com/apt gcsfuse-buster main" > /etc/apt/sources.list.d/gcsfuse.list