Intellipaat Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in DevOps and Agile by (50.2k points)

Hello guys, I have created Dockerfile and I wanted to know that how do I add comments in this file? Is there any way in docker which allows adding comment option that takes the rest of a line and ignores it?

1 Answer

0 votes
by (107k points)

Just try using '#' and it will treat the whole line as a comment in your docker file.

For example:

# Everything in this line is a comment

Related questions

0 votes
1 answer
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer
asked Sep 18, 2020 in Docker by Justin (7k points)

31k questions

32.8k answers

501 comments

693 users

Browse Categories

...