Merge pull request #8732 from ndeloof/devies

fix support for devices
This commit is contained in:
Ulysses Souza 2021-10-02 14:16:52 +02:00 committed by GitHub
commit fdb90ca179
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -525,6 +525,9 @@ func getDeployResources(s types.ServiceConfig) container.Resources {
case 1:
src = arr[0]
}
if dst == "" {
dst = src
}
resources.Devices = append(resources.Devices, container.DeviceMapping{
PathOnHost: src,
PathInContainer: dst,