MCPcopy
hub / github.com/basecamp/once / Equal

Method Equal

internal/docker/application_settings.go:76–101  ·  view source on GitHub ↗
(other ApplicationSettings)

Source from the content-addressed store, hash-verified

74}
75
76func (s ApplicationSettings) Equal(other ApplicationSettings) bool {
77 if s.Name != other.Name || s.Image != other.Image || s.Host != other.Host || s.DisableTLS != other.DisableTLS {
78 return false
79 }
80 if s.Resources != other.Resources {
81 return false
82 }
83 if s.SMTP != other.SMTP {
84 return false
85 }
86 if s.AutoUpdate != other.AutoUpdate {
87 return false
88 }
89 if s.Backup != other.Backup {
90 return false
91 }
92 if len(s.EnvVars) != len(other.EnvVars) {
93 return false
94 }
95 for k, v := range s.EnvVars {
96 if other.EnvVars[k] != v {
97 return false
98 }
99 }
100 return true
101}
102
103func (s ApplicationSettings) BuildEnv(vol ApplicationVolumeSettings) []string {
104 env := []string{

Calls

no outgoing calls