Skip to content

Commit

Permalink
Add support for ReplicaSet
Browse files Browse the repository at this point in the history
  • Loading branch information
joan38 committed Aug 18, 2018
1 parent 0015c1c commit 1afaf17
Showing 1 changed file with 33 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
package com.goyeau.kubernetes.client

import akka.actor.ActorSystem
import io.circe._
import io.k8s.api.apps.v1beta2.{ReplicaSet, ReplicaSetList}

private[client] case class ReplicaSetsOperations(protected val config: KubeConfig)(
implicit protected val system: ActorSystem,
protected val listDecoder: Decoder[ReplicaSetList],
encoder: Encoder[ReplicaSet],
decoder: Decoder[ReplicaSet]
) extends Listable[ReplicaSetList] {
protected val resourceUri = "apis/apps/v1beta2/replicasets"

def namespace(namespace: String) = NamespacedReplicaSetsOperations(config, namespace)
}

private[client] case class NamespacedReplicaSetsOperations(
protected val config: KubeConfig,
protected val namespace: String
)(
implicit protected val system: ActorSystem,
protected val resourceEncoder: Encoder[ReplicaSet],
protected val resourceDecoder: Decoder[ReplicaSet],
protected val listDecoder: Decoder[ReplicaSetList]
) extends Creatable[ReplicaSet]
with Replaceable[ReplicaSet]
with Gettable[ReplicaSet]
with Listable[ReplicaSetList]
with Deletable
with GroupDeletable {
protected val resourceUri = s"apis/apps/v1beta2/namespaces/$namespace/replicasets"
}

0 comments on commit 1afaf17

Please sign in to comment.