<commit_before>#Kubernetes ZooKeeper K8SZK
This project contains a Docker image meant to facilitate the deployment of 
[Apache ZooKeeper](https://zookeeper.apache.org/) on [Kubernetes](http://kubernetes.io/) using 
[StatefulSets](http://kubernetes.io/docs/abstractions/controllers/petset/). 
##Limitations
1. Scaling is not currently supported. An ensemble's membership can not be updated in a safe way 
in ZooKeeper 3.4.9 (The current stable release).
2. Observers are currently not supported. Contributions are welcome.
3. Persistent Volumes must be used. emptyDirs will likely result in a loss of data.
##Docker Image
The docker image contained in this repository is comprised of a base Ubuntu 16.04 image using the latest
release of the OpenJDK JRE based on the 1.8 JVM (JDK 8u111) and the latest stable release of 
ZooKeeper, 3.4.9. Ubuntu is a much larger image than BusyBox or Alpine, but these images contain 
mucl or ulibc. This requires a custom version of OpenJDK to be built against a libc runtime other 
than glibc. No vendor of the ZooKeeper software supplies or verifies the software against such a 
JVM, and, while Alpine or BusyBox would provide smaller images, we have prioritized a well known 
environment.

The image is built such that the ZooKeeper process is designated to run as a non-root user. By default, 
this user is zookeeper. The ZooKeeper package is installed into the /opt/zookeeper directory, all 
configuration is sym linked into the /usr/etc/zookeeper/, and all executables are sym linked into 
/usr/bin. The ZooKeeper data directories are contained in /var/lib/zookeeper. This is identical to 
the RPM distribution that users should be familiar with.
##Configuration
###Headless Service
The ZooKeeper Stateful Set requires a Headless Service to control the network domain for the 
ZooKeeper processes. An example configuration is provided below.
```yaml
apiVersion: v1
kind: Service
metadata:<commit_msg>Fix Markdown formatting in README<commit_after>#Kubernetes ZooKeeper K8SZK
This project contains a Docker image meant to facilitate the deployment of 
[Apache ZooKeeper](https://zookeeper.apache.org/) on [Kubernetes](http://kubernetes.io/) using 
[StatefulSets](http://kubernetes.io/docs/abstractions/controllers/petset/). 
##Limitations
1. Scaling is not currently supported. An ensemble's membership can not be updated in a safe way 
in ZooKeeper 3.4.9 (The current stable release).
2. Observers are currently not supported. Contributions are welcome.
3. Persistent Volumes must be used. emptyDirs will likely result in a loss of data.

##Docker Image
The docker image contained in this repository is comprised of a base Ubuntu 16.04 image using the latest
release of the OpenJDK JRE based on the 1.8 JVM (JDK 8u111) and the latest stable release of 
ZooKeeper, 3.4.9. Ubuntu is a much larger image than BusyBox or Alpine, but these images contain 
mucl or ulibc. This requires a custom version of OpenJDK to be built against a libc runtime other 
than glibc. No vendor of the ZooKeeper software supplies or verifies the software against such a 
JVM, and, while Alpine or BusyBox would provide smaller images, we have prioritized a well known 
environment.

The image is built such that the ZooKeeper process is designated to run as a non-root user. By default, 
this user is zookeeper. The ZooKeeper package is installed into the /opt/zookeeper directory, all 
configuration is sym linked into the /usr/etc/zookeeper/, and all executables are sym linked into 
/usr/bin. The ZooKeeper data directories are contained in /var/lib/zookeeper. This is identical to 
the RPM distribution that users should be familiar with.
##Configuration
###Headless Service
The ZooKeeper Stateful Set requires a Headless Service to control the network domain for the 
ZooKeeper processes. An example configuration is provided below.
```yaml
apiVersion: v1
kind: Service
metadata:
{'fraction_non_alphanumeric': 0.052806972571135605, 'fraction_numerical': 0.0107664701358626, 'mean_word_length': 4.590257879656161, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7199445', 'n_tokens_mistral': 1141, 'n_tokens_neox': 1041, 'n_words': 555}