For example, you want to perform this
tee /root/.pip/pip.conf <<-'EOF'
[global]
index-url = https://pypi.douban.com/simple/
EOF
How to write in dockerfile, direct writing is not acceptable. If it is written in the following form, it will become a single line and cannot meet the original format requirements
RUN tee /root/.pip/pip.conf <<-'EOF' \
[global] \
index-url = https://pypi.douban.com/simple/ \
EOF
Please advise
Use line breaks
\n
echo "[global]\nindex-url = https://pypi.douban.com/simple/\n" > /root/.pip/pip.conf