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

Support for custom named Dockerfiles #246

Open
tonur opened this issue Mar 15, 2022 · 2 comments
Open

Support for custom named Dockerfiles #246

tonur opened this issue Mar 15, 2022 · 2 comments
Labels
Milestone

Comments

@tonur
Copy link

tonur commented Mar 15, 2022

In FileBuilder, when RenderDockerfile gets called, it always renderes a Dockerfile to the _workingFolder with the name of "Dockerfile".

When multiple Docker containers is build simultaneous, this means that the file gets overwritten multiple times, and often results in some FluentDocker Fd services locking the file and reading from other instances.

A solution could be to allow for a TemplateString input for a private config field, fx private TemplateString _renderedDockerfileName = "Dockerfile".
Then it would be able to set the _renderedDockerfileName to "${RND}", and thus solve the problem.

A separate problem is that the file isn't cleaned up after use. In my usecase, it's frustrating with multiple projects and multiple runs that it generates an extra Dockerfile at the working folder, when I already have "Service1.Dockerfile" and "Service2.Dockerfile". But this is a seperate issue, even though it would make custom rendered Dockerfile names a lot easier to manage.

@mariotoffia
Copy link
Owner

Hi @tonur - I totally agree. This needs to be fixed - I saw that you've done a PR - thanks!! :)

Cheers,
Mario :)

@mariotoffia mariotoffia added this to the 3.0.0-RELEASE milestone Mar 16, 2022
@tonur
Copy link
Author

tonur commented Aug 29, 2023

Hi there. I sadly was not able to fix this issue in the following PR: #248
If this issue should be closed, then please, feel free to.
I sadly do not work with C# anymore, so I lack the motivation for doing this :(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants