You are overanalyzing this. It’s just a simple typo. Should be:
RUN apt-get update && \
apt-get upgrade -y && \
apt-get install -y git
Those are 3 separate commands.
You are overanalyzing this. It’s just a simple typo. Should be:
RUN apt-get update && \
apt-get upgrade -y && \
apt-get install -y git
Those are 3 separate commands.