-
-
Notifications
You must be signed in to change notification settings - Fork 96
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
Use docker arguments in FluentAPI or Builder? #88
Comments
thanks for the really good description! - I'll try to make it to this weekends release.
cheers,
mario
Get Outlook for Android<https://aka.ms/ghei36>
…________________________________
From: Štefan Jarina <notifications@github.com>
Sent: Wednesday, July 17, 2019 9:30:28 PM
To: mariotoffia/FluentDocker
Cc: Subscribed
Subject: [mariotoffia/FluentDocker] Use docker arguments in FluentAPI or Builder? (#88)
Hello,
first of all, thank you for this library, it covers almost all my needs.
However, I was wondering if it is possible to somehow specify some docker arguments using Builder or Fluent API?
For example to set a --ulimit argument.
From documentation it is not clear at all, how to add it, if for example I build my container like:
var container = new Builder()
.UseContainer()
.WithName($"{_configuration.Prefix}-{service.Name}")
.UseImage(image)
.UseNetwork(networkName).Build();
for example, I am trying to replicate this command:
* When creating Clickhouse --ulimit is advised to use
docker create --net servers -v clickhouse-data:/var/lib/clickhouse --ulimit nofile=262144:262144 --name clickhouse-server -p 8123:8123 -p 9000:9000 yandex/clickhouse-server:$Version
Cheers,
Stefan
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub<#88?email_source=notifications&email_token=AANDCL46E564YJMHZESVLETP75XNJA5CNFSM4IETYDM2YY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4G72RAFQ>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AANDCL3A67UBA3HPCDZFHU3P75XNJANCNFSM4IETYDMQ>.
[https://www.dataductus.com/wp-content/uploads/2018/01/dataductus_logo.png]<http://www.dataductus.com>
Mario Toffia
CTO
Data Ductus | Grynbodgatan 3 | 211 33 Malmö | SE
Phone: +46 40 643 07 71
www.dataductus.com<http://www.dataductus.com>
|
mariotoffia
pushed a commit
that referenced
this issue
Jul 24, 2019
The bug is when docker-machine was created using --generic-ip-address=docker where it will have docker as the ipaddress. Now it is possible to set ulimit on ContainerCreateParams and on the fluent API.
@stefanjarina It is in the repo now but I've got a bug that I've fixed that I wanted to be tested before releasing... But now it is possible to write e.g. var container =
Fd.UseContainer()
.UseImage("postgres:latest", force: true)
.UseUlimit(Ulimit.NoFile,2048, 2048)
.WithEnvironment("POSTGRES_PASSWORD=mysecretpassword")
.Build()
.Start() |
@mariotoffia Brilliant! This helps a lot, thanks for implementing it so soon. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hello,
first of all, thank you for this library, it covers almost all my needs.
However, I was wondering if it is possible to somehow specify some docker arguments using Builder or Fluent API?
For example to set a --ulimit argument.
From documentation it is not clear at all, how to add it, if for example I build my container like:
for example, I am trying to replicate this command:
--ulimit
is advised to useCheers,
Stefan
The text was updated successfully, but these errors were encountered: