From 313af879b58780719573653d93908056004c5e2f Mon Sep 17 00:00:00 2001 From: Timothy Perrett Date: Fri, 28 Sep 2018 08:33:18 -0700 Subject: [PATCH 1/4] Ci mods --- .buildkite/pipeline.exec.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.buildkite/pipeline.exec.sh b/.buildkite/pipeline.exec.sh index 1978de0a..dc5ef662 100755 --- a/.buildkite/pipeline.exec.sh +++ b/.buildkite/pipeline.exec.sh @@ -14,4 +14,4 @@ if [ "$BUILDKITE_PULL_REQUEST" = 'false' ]; then git checkout -qf "$BUILDKITE_BRANCH"; fi -sbt ++2.11.11 'release with-defaults' +sbt ++2.11.11 'core/testOnly nelson.TemplatesSpec' From 22787a95b2906f7c3cbf3a3e1332a30049d8b2ec Mon Sep 17 00:00:00 2001 From: Timothy Perrett Date: Fri, 28 Sep 2018 08:34:33 -0700 Subject: [PATCH 2/4] line ending --- .buildkite/pipeline.exec.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/.buildkite/pipeline.exec.sh b/.buildkite/pipeline.exec.sh index dc5ef662..6f837cc3 100755 --- a/.buildkite/pipeline.exec.sh +++ b/.buildkite/pipeline.exec.sh @@ -15,3 +15,4 @@ if [ "$BUILDKITE_PULL_REQUEST" = 'false' ]; then fi sbt ++2.11.11 'core/testOnly nelson.TemplatesSpec' + From d3ad760e2481c9cc8573a09dcd5cfff7ffe6874a Mon Sep 17 00:00:00 2001 From: Timothy Perrett Date: Fri, 28 Sep 2018 09:39:35 -0700 Subject: [PATCH 3/4] Cleanup --- .buildkite/pipeline.exec.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.buildkite/pipeline.exec.sh b/.buildkite/pipeline.exec.sh index 6f837cc3..1978de0a 100755 --- a/.buildkite/pipeline.exec.sh +++ b/.buildkite/pipeline.exec.sh @@ -14,5 +14,4 @@ if [ "$BUILDKITE_PULL_REQUEST" = 'false' ]; then git checkout -qf "$BUILDKITE_BRANCH"; fi -sbt ++2.11.11 'core/testOnly nelson.TemplatesSpec' - +sbt ++2.11.11 'release with-defaults' From f2d56f8e6a56d03e0d68b14e4d504609d3b5fbbd Mon Sep 17 00:00:00 2001 From: Timothy Perrett Date: Sun, 30 Sep 2018 19:43:43 -0700 Subject: [PATCH 4/4] Add replication to the Pulsar workflow --- core/src/main/scala/workflows/Pulsar.scala | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/core/src/main/scala/workflows/Pulsar.scala b/core/src/main/scala/workflows/Pulsar.scala index 6951acbc..508effb1 100644 --- a/core/src/main/scala/workflows/Pulsar.scala +++ b/core/src/main/scala/workflows/Pulsar.scala @@ -19,11 +19,10 @@ package nelson import cats.syntax.apply._ import nelson.Datacenter.{Deployment, Namespace => DCNamespace} -import nelson.DeploymentStatus.{Pending, Ready, Terminated, Warming} +import nelson.DeploymentStatus.{Pending, Deploying, Ready, Terminated, Warming} import nelson.Manifest.{Namespace => ManifestNamespace, Plan, UnitDef, Versioned} -import nelson.Workflow.{WorkflowF, WorkflowOp} +import nelson.Workflow.WorkflowF import nelson.Workflow.syntax._ -import nelson.docker.DockerOp /** * Kubernetes deployment workflow that deploys and deletes units, whilst provisioning @@ -46,8 +45,9 @@ object Pulsar extends Workflow[Unit] { else unit.ports.fold[DeploymentStatus](Ready)(_ => Warming) for { - i <- DockerOp.extract(Versioned.unwrap(vunit)).inject[WorkflowOp] _ <- status(id, Pending, "Pulsar workflow about to start") + _ <- status(id, Deploying, "Replicating container images to remote registry") + i <- dockerOps(id, unit, dc.docker.registry) //// write the policies to Vault _ <- logToFile(id, s"Writing policy to vault: ${vaultLoggingFields(sn, ns = ns.name, dcName = dc.name)}") _ <- writePolicyToVault(cfg = dc.policy, sn = sn, ns = ns.name, rs = rs)