Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Give the dockerfile some love (1/x) #88

Merged
merged 1 commit into from
Jan 31, 2019

Conversation

bebehei
Copy link
Contributor

@bebehei bebehei commented Jan 30, 2019

Adapts the Dockerfile to Dockerfile "sort multiline" best practices.

Nothing more. Previous experience taught me that's the hardest part to review for a Dockerfile.

Will create additional PRs to address #60 and fix it at the end.

Copy link
Member

@humitos humitos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me! Thanks for the changes.

I left some minor comments to do and we can merge it.

Dockerfile Outdated Show resolved Hide resolved
RUN apt-get -y install python-pip && pip install -U virtualenv auxlib
RUN apt-get -y install \
python-pip \
&& pip install -U \
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe it's better to continue with the visual indentation here.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, but I don't get this. Do you want me to write it this way?!?

RUN apt-get -y install \
      python-pip \
    && pip install -U \

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

RUN apt-get -y install \
      python-pip \
   && pip install -U \

or

RUN apt-get -y install \
      python-pip \
      && pip install -U \

or

RUN apt-get -y install \
      python-pip && \
      pip install -U \

I think 1) and 3) are more readable. 1) looks nicer to me ;)

Copy link
Contributor Author

@bebehei bebehei Jan 31, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All in all, you're aligning commands to package arguments. Really?

In the current code, I've aligned the pip command to the apt-get command and moved the rest around it.

But aligning it to the pip package makes no sense to me, sorry.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh sorry, you are right. I got confused. Ignore me.

RUN apt-get -y install \
nodejs \
npm \
&& npm install --global \
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here about visual indentation.

Copy link
Member

@humitos humitos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@humitos humitos merged commit 614cb18 into readthedocs:master Jan 31, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants