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

Generate Dockerfile into .cnab/ directory #1545

Merged
merged 2 commits into from
Apr 27, 2021

Conversation

carolynvs
Copy link
Member

@carolynvs carolynvs commented Apr 26, 2021

What does this change

  • Generate a Dockerfile at .cnab/Dockerfile instead of in the root of the bundle directory. This avoids us overwriting a file that isn't owned by the bundle (e.g. they have the bundle defined at the root of their repo and also have their own Dockerfile). It also keeps all the rando files generated by Porter in a single tidy location we can all ignore.
  • Cleanup the entire .cnab/ directory between builds instead of just the Dockerfile. Otherwise we copy in old mixins that may not be used anymore and generally open ourselves up to non-repeatable builds.

What issue does it fix

Closes #1162

Notes for the reviewer

Checklist

  • Unit Tests
  • Documentation
  • Schema (porter.yaml)

* Generate a Dockerfile at .cnab/Dockerfile instead of in the root of
the bundle directory. This avoids us overwriting a file that isn't owned
by the bundle (e.g. they have the bundle defined at the root of their
repo and also have their own Dockerfile).
* Cleanup the entire .cnab/ directory between builds instead of just the
Dockerfile. Otherwise we copy in old mixins that may not be used anymore
and generally open ourselves up to non-repeatable builds.

Signed-off-by: Carolyn Van Slyck <me@carolynvanslyck.com>
I can't reproduce this error on my windows machine so I throwing stuff
at the build server.

Signed-off-by: Carolyn Van Slyck <me@carolynvanslyck.com>
@carolynvs carolynvs marked this pull request as ready for review April 26, 2021 21:01
@carolynvs
Copy link
Member Author

I will squash when this is merged.

@carolynvs carolynvs added this to In Progress in Porter and Mixins via automation Apr 26, 2021
Copy link
Member

@vdice vdice left a comment

Choose a reason for hiding this comment

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

LGTM!

@carolynvs carolynvs merged commit b1d7b9d into getporter:main Apr 27, 2021
Porter and Mixins automation moved this from In Progress to Done Apr 27, 2021
@carolynvs carolynvs deleted the move-dockerfile branch April 27, 2021 14:05
vdice added a commit to vdice/porter that referenced this pull request May 12, 2021
Signed-off-by: Vaughn Dice <vadice@microsoft.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Development

Successfully merging this pull request may close these issues.

Rename, move, and hide Porter's generated Dockerfile
2 participants