airflow-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Fokko Driesprong (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (AIRFLOW-1633) docker_operator needs a way to set shm_size
Date Tue, 10 Apr 2018 07:18:00 GMT

     [ https://issues.apache.org/jira/browse/AIRFLOW-1633?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Fokko Driesprong resolved AIRFLOW-1633.
---------------------------------------
       Resolution: Fixed
    Fix Version/s: 2.0.0

Issue resolved by pull request #3199
[https://github.com/apache/incubator-airflow/pull/3199]

> docker_operator needs a way to set shm_size
> -------------------------------------------
>
>                 Key: AIRFLOW-1633
>                 URL: https://issues.apache.org/jira/browse/AIRFLOW-1633
>             Project: Apache Airflow
>          Issue Type: Improvement
>            Reporter: Gregory Benison
>            Assignee: Tao Feng
>            Priority: Major
>             Fix For: 2.0.0
>
>
> The "docker run" command line client has an option "--shm-size" that allows setting the
size of /dev/shm in the container.  The "docker" package - on which docker_operator is based
- does provide an interface for setting this property; docker.utils.create_host_config() has
a "shm_size" argument that defaults to None.  However docker_operator calls that method in
a way that does not provide a mechanism for accessing that argument:
> {noformat}
>             self.container = self.cli.create_container(
>                     command=self.get_command(),
>                     cpu_shares=cpu_shares,
>                     environment=self.environment,
>                     host_config=self.cli.create_host_config(binds=self.volumes,
>                                                             network_mode=self.network_mode),
>                     image=image,
>                     mem_limit=self.mem_limit,
>                     user=self.user
>             )
> {noformat}
> It would be useful to provide a way to pass the "shm_size" option to the call to create_host_config().
 Actually create_host_config() has a large number of options that can't be controlled through
docker_operator - perhaps it would make sense to find a way to expose all or most of them.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message