Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add the multiAddress.enabled cluster option present in zk >3.6.0 #595

Open
wants to merge 12 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
71 changes: 71 additions & 0 deletions .github/workflows/build-push-docker.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
name: build-publish-docker-image

on:
push:
tags:
- '*'

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Set up Go 1.21
uses: actions/setup-go@v2
with:
go-version: 1.21
id: go
- name: Set up Go for root
run: |
sudo ln -sf `which go` `sudo which go` || true
sudo go version
- uses: actions/checkout@v2
- name: get go version
run: go version
- name: Gofmt and License checks
run: make check
- name: unit tests
run: make test
- name: Get tag name
id: vars
run: |
ref=${GITHUB_REF:10}
ref="${ref////-}"
echo $ref
echo ::set-output name=tag::$ref
- name: Build and push zookeeper Apache image
uses: docker/build-push-action@v1
if: ${{ startsWith(github.ref, 'refs/tags/zk') }}
with:
path: docker/zookeeper-image
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
repository: adobe/zookeeper
tags: 3.8.3-apache-${{ steps.vars.outputs.tag }}
add_git_labels: true
always_pull: true
push: ${{ startsWith(github.ref, 'refs/tags/zk') }}
- name: Build and push zookeeper image
if: ${{ !startsWith(github.ref, 'refs/tags/zk') }}
uses: docker/build-push-action@v1
with:
path: docker
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
repository: adobe/zookeeper
tags: 3.8.3-${{ steps.vars.outputs.tag }}
add_git_labels: true
always_pull: true
push: ${{ startsWith(github.ref, 'refs/tags/') && !startsWith(github.ref, 'refs/tags/zk') }}
- name: Build and push zookeeper-operator image
if: ${{ !startsWith(github.ref, 'refs/tags/zk') }}
uses: docker/build-push-action@v1
with:
dockerfile: Dockerfile
build_args: VERSION=${{ steps.vars.outputs.tag }},GIT_SHA=${{ github.sha }}
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
repository: adobe/zookeeper-operator
tag_with_ref: true
add_git_labels: true
always_pull: true
push: ${{ startsWith(github.ref, 'refs/tags/') && !startsWith(github.ref, 'refs/tags/zk') }}
80 changes: 0 additions & 80 deletions .github/workflows/ci.yaml

This file was deleted.

58 changes: 38 additions & 20 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,29 +6,47 @@ The project is currently alpha. While no breaking API changes are currently plan

## Table of Contents

* [Overview](#overview)
* [Requirements](#requirements)
* [Usage](#usage)
* [Installation of the Operator](#install-the-operator)
* [Deploy a sample Zookeeper Cluster](#deploy-a-sample-zookeeper-cluster)
* [Deploy a sample ZooKeeper Cluster with Ephemeral Storage](#Deploy-a-sample-zookeeper-cluster-with-ephemeral-storage)
* [Deploy a sample Zookeeper Cluster to a cluster using Istio](#deploy-a-sample-zookeeper-cluster-with-istio)
* [Upgrade a Zookeeper Cluster](#upgrade-a-zookeeper-cluster)
* [Uninstall the Zookeeper Cluster](#uninstall-the-zookeeper-cluster)
* [Upgrade the Zookeeper Operator](#upgrade-the-operator)
* [Uninstall the Operator](#uninstall-the-operator)
* [The AdminServer](#the-adminserver)
* [Development](#development)
* [Build the Operator Image](#build-the-operator-image)
* [Direct Access to Cluster](#direct-access-to-the-cluster)
* [Run the Operator Locally](#run-the-operator-locally)
* [Installation on GKE](#installation-on-google-kubernetes-engine)
* [Installation on Minikube](#installation-on-minikube)
- [Zookeeper Operator](#zookeeper-operator)
- [Project status: alpha](#project-status-alpha)
- [Table of Contents](#table-of-contents)
- [Overview](#overview)
- [Requirements](#requirements)
- [Usage](#usage)
- [Install the operator](#install-the-operator)
- [Install via helm](#install-via-helm)
- [Manual deployment](#manual-deployment)
- [Deploy a sample Zookeeper cluster](#deploy-a-sample-zookeeper-cluster)
- [Install via helm](#install-via-helm-1)
- [Manual deployment](#manual-deployment-1)
- [Deploy a sample Zookeeper cluster with Ephemeral storage](#deploy-a-sample-zookeeper-cluster-with-ephemeral-storage)
- [Deploy a sample Zookeeper cluster with Istio](#deploy-a-sample-zookeeper-cluster-with-istio)
- [Upgrade a Zookeeper cluster](#upgrade-a-zookeeper-cluster)
- [Trigger the upgrade via helm](#trigger-the-upgrade-via-helm)
- [Trigger the upgrade manually](#trigger-the-upgrade-manually)
- [Upgrade the Operator](#upgrade-the-operator)
- [Uninstall the Zookeeper cluster](#uninstall-the-zookeeper-cluster)
- [Uninstall via helm](#uninstall-via-helm)
- [Manual uninstall](#manual-uninstall)
- [Uninstall the operator](#uninstall-the-operator)
- [Uninstall via helm](#uninstall-via-helm-1)
- [Manual uninstall](#manual-uninstall-1)
- [The AdminServer](#the-adminserver)
- [Development](#development)
- [Build the operator image](#build-the-operator-image)
- [Direct access to the cluster](#direct-access-to-the-cluster)
- [Run the operator locally](#run-the-operator-locally)
- [Installation on Google Kubernetes Engine](#installation-on-google-kubernetes-engine)
- [Installation on Minikube](#installation-on-minikube)
- [Minikube Setup](#minikube-setup)
- [Cluster Deployment](#cluster-deployment)
- [Zookeeper YAML Exporter](#zookeeper-yaml--exporter)
- [How to build Zookeeper Operator](#how-to-build-zookeeper-operator)
- [How to use exporter](#how-to-use-exporter)


### Overview

This operator runs a Zookeeper 3.7.1 cluster, and uses Zookeeper dynamic reconfiguration to handle node membership.
This operator runs a Zookeeper 3.8.3 cluster, and uses Zookeeper dynamic reconfiguration to handle node membership.

The operator itself is built with the [Operator framework](https://github.com/operator-framework/operator-sdk).

Expand Down Expand Up @@ -371,7 +389,7 @@ The list of available commands are
### Build the operator image

Requirements:
- Go 1.17+
- Go 1.21+

Use the `make` command to build the Zookeeper operator image.

Expand Down
2 changes: 1 addition & 1 deletion api/v1beta1/zookeepercluster_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ func (s *ZookeeperClusterSpec) withDefaults(z *ZookeeperCluster) (changed bool)
}
if s.MaxUnavailableReplicas < 1 {
s.MaxUnavailableReplicas = 1
changed = true
//changed = true
}
return changed
}
Expand Down
3 changes: 3 additions & 0 deletions charts/zookeeper-operator/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@ app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
{{- end }}
app.kubernetes.io/managed-by: {{ .Release.Service }}
helm.sh/chart: "{{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}"
{{- range $k, $v := $.Values.labels }}
{{ $k }}: {{ $v | quote }}
{{- end }}
{{- end -}}

{{/*
Expand Down
123 changes: 0 additions & 123 deletions charts/zookeeper-operator/templates/post-install-upgrade-hooks.yaml

This file was deleted.

Loading