<commit_before>Automatic Volume Snapshots on Kubernetes / Google Container Engine
==================================================================

1. You add an annotation to your Kubernetes `PersistentVolume` resource,
   to indicate how many backups should be kept.
2. This tool will create and expire snapshots to match the desired
   configuration.

Currently, only the following setup is supported:

- Google Compute Engine disks.


How it works
------------

1. Run it as a service, preferable inside your Kubernetes cluster.
2. It will watch `PersistentVolume` resources and check those for an
   annotation named `backup.kubernetes.io/deltas`, which would have
   a value such as `1d 7d 30d`.
3. For every `PersistentVolume` that defines this annotation, and is
   a Google Compute disk, it will create new snapshots, and delete
   existing snapshots, according to the deltas defined.

  **WARNING**: The tool *will* consider snapshots not created by it.
  It will consider, and potentially delete, every snapshot that is
  associated with the disk in question.


How do the deltas work
----------------------

The expiry logic of [tarsnapper](https://github.com/miracle2k/tarsnapper)
is used.

The generations are defined by a list of deltas. ``60s`` means a minute,
``12h`` is half a day, ``7d`` is a week. The number of backups in each
generation is implied by it's and the parent generation's delta.

For example, given the deltas ``1h 1d 7d``, the first generation will
consist of 24 backups each one hour older than the previous
(or the closest approximation possible given the available backups),
the second generation of 7 backups each one day older than the previous,
and backups older than 7 days will be discarded for good.

The most recent backup is always kept.

The first delta is the backup interval.

<commit_msg>We don't consider foreig images any more.<commit_after>Automatic Volume Snapshots on Kubernetes / Google Container Engine
==================================================================

1. You add an annotation to your Kubernetes `PersistentVolume` resource,
   to indicate how many backups should be kept.
2. This tool will create and expire snapshots to match the desired
   configuration.

Currently, only the following setup is supported:

- Google Compute Engine disks.


How it works
------------

1. Run it as a service, preferable inside your Kubernetes cluster.
2. It will watch `PersistentVolume` resources and check those for an
   annotation named `backup.kubernetes.io/deltas`, which would have
   a value such as `1d 7d 30d`.
3. For every `PersistentVolume` that defines this annotation, and is
   a Google Compute disk, it will create new snapshots, and delete
   existing snapshots, according to the deltas defined.


How do the deltas work
----------------------

The expiry logic of [tarsnapper](https://github.com/miracle2k/tarsnapper)
is used.

The generations are defined by a list of deltas. ``60s`` means a minute,
``12h`` is half a day, ``7d`` is a week. The number of backups in each
generation is implied by it's and the parent generation's delta.

For example, given the deltas ``1h 1d 7d``, the first generation will
consist of 24 backups each one hour older than the previous
(or the closest approximation possible given the available backups),
the second generation of 7 backups each one day older than the previous,
and backups older than 7 days will be discarded for good.

The most recent backup is always kept.

The first delta is the backup interval.


{'fraction_non_alphanumeric': 0.10620220900594732, 'fraction_numerical': 0.012461059190031152, 'mean_word_length': 3.953716690042076, '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': '999105', 'n_tokens_mistral': 958, 'n_tokens_neox': 878, 'n_words': 504}