mirror of
https://github.com/docker/compose.git
synced 2025-07-23 13:45:00 +02:00
Remove service.Build and service.PullPolicy fields when generating the config hash
Signed-off-by: aiordache <anca.iordache@docker.com>
This commit is contained in:
parent
cd4a08d0d6
commit
44d2b29d0f
@ -26,6 +26,9 @@ import (
|
|||||||
// ServiceHash compute configuration has for a service
|
// ServiceHash compute configuration has for a service
|
||||||
// TODO move this to compose-go
|
// TODO move this to compose-go
|
||||||
func ServiceHash(o types.ServiceConfig) (string, error) {
|
func ServiceHash(o types.ServiceConfig) (string, error) {
|
||||||
|
// remove the Build config when generating the service hash
|
||||||
|
o.Build = nil
|
||||||
|
o.PullPolicy = ""
|
||||||
bytes, err := json.Marshal(o)
|
bytes, err := json.Marshal(o)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return "", err
|
return "", err
|
||||||
|
Loading…
x
Reference in New Issue
Block a user