Menu

#6558 Dockerfile: Clean up ADD and RUN commands

open
nobody
2019-03-13
2019-03-08
Anonymous
No

Originally created by: joakimr-axis

Optimize by copying all files in one command (and the directory in
another) and use COPY instead of ADD. Remove the line that adds . to
the container.

Change-Id: Ia320060ae3977712ac653dee3dcf4393d66198ad
Signed-off-by: Joakim Roubert joakimr@axis.com

Resolves [#6557]

Related

Tickets: #6557

Discussion

  • Anonymous

    Anonymous - 2019-03-08

    Originally posted by: GordonTheTurtle

    Please sign your commits following these rules:
    https://github.com/moby/moby/blob/master/CONTRIBUTING.md#sign-your-work
    The easiest way to do this is to amend the last commit:

    $ git clone -b "cleanupadd" git@github.com:joakimr-axis/compose.git somewhere
    $ cd somewhere
    $ git rebase -i HEAD~842359068384
    editor opens
    change each 'pick' to 'edit'
    save the file and quit
    $ git commit --amend -s --no-edit
    $ git rebase --continue # and repeat the amend for each commit
    $ git push -f
    

    Amending updates the existing PR. You DO NOT need to open a new one.

     
  • Anonymous

    Anonymous - 2019-03-11

    Originally posted by: joakimr-axis

    This PR is superfluous if https://github.com/docker/compose/pull/6577 is merged.

     

Log in to post a comment.