mirror of
https://github.com/arangodb/kube-arangodb.git
synced 2024-12-14 11:57:37 +00:00
ArangoDB version in membership status (#423)
* add arangodb version to member status
This commit is contained in:
parent
74232fd585
commit
9f1861c2db
3 changed files with 14 additions and 3 deletions
|
@ -1,7 +1,7 @@
|
|||
# Change Log
|
||||
|
||||
## [0.3.13]() (XXXX-XX-XX)
|
||||
-
|
||||
- Added ArangoDB version and image id to member status
|
||||
|
||||
## [0.3.12](https://github.com/arangodb/kube-arangodb/tree/0.3.12) (2019-07-04)
|
||||
- Limit source IP ranges for external services
|
||||
|
|
|
@ -25,8 +25,9 @@ package v1alpha
|
|||
import (
|
||||
"time"
|
||||
|
||||
driver "github.com/arangodb/go-driver"
|
||||
"github.com/arangodb/kube-arangodb/pkg/util"
|
||||
"k8s.io/api/core/v1"
|
||||
v1 "k8s.io/api/core/v1"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
)
|
||||
|
||||
|
@ -53,6 +54,10 @@ type MemberStatus struct {
|
|||
IsInitialized bool `json:"initialized"`
|
||||
// CleanoutJobID holds the ID of the agency job for cleaning out this server
|
||||
CleanoutJobID string `json:"cleanout-job-id,omitempty"`
|
||||
// ArangoVersion holds the ArangoDB version in member
|
||||
ArangoVersion driver.Version `json:"arango-version,omitempty"`
|
||||
//ImageId holds the members ArangoDB image ID
|
||||
ImageID string `json:"image-id,omitempty"`
|
||||
}
|
||||
|
||||
// Equal checks for equality
|
||||
|
@ -64,7 +69,9 @@ func (s MemberStatus) Equal(other MemberStatus) bool {
|
|||
s.PodName == other.PodName &&
|
||||
s.Conditions.Equal(other.Conditions) &&
|
||||
s.IsInitialized == other.IsInitialized &&
|
||||
s.CleanoutJobID == other.CleanoutJobID
|
||||
s.CleanoutJobID == other.CleanoutJobID &&
|
||||
s.ArangoVersion == other.ArangoVersion &&
|
||||
s.ImageID == other.ImageID
|
||||
}
|
||||
|
||||
// Age returns the duration since the creation timestamp of this member.
|
||||
|
|
|
@ -667,6 +667,10 @@ func (r *Resources) createPodForMember(spec api.DeploymentSpec, memberID string,
|
|||
clusterJWTSecretName, groupSpec.GetNodeSelector(), groupSpec.PriorityClassName, groupSpec.Resources, exporter, groupSpec.GetSidecars(), groupSpec.VolumeClaimTemplate); err != nil {
|
||||
return maskAny(err)
|
||||
}
|
||||
|
||||
m.ArangoVersion = status.CurrentImage.ArangoDBVersion
|
||||
m.ImageID = status.CurrentImage.ImageID
|
||||
|
||||
log.Debug().Str("pod-name", m.PodName).Msg("Created pod")
|
||||
} else if group.IsArangosync() {
|
||||
// Check image
|
||||
|
|
Loading…
Reference in a new issue