<divclass="head"><h1>Backups <small>{% if kind == "org" %}<ahref="/orgs/{{ owner }}/settings">{{ owner }}</a>'s repositories{% else %}your repositories{% endif %}, copied to a place you control</small></h1></div>
7
{% if let Some(n) = notice %}<pclass="note">{{ n }}</p>{% endif %}
8
{% if let Some(e) = error %}<pclass="error">{{ e }}</p>{% endif %}
9
<pclass="small mute backup-what">Each run copies every repository {% if kind == "org" %}the organisation{% else %}you{% endif %} own, with its wiki, byte for byte (signatures and all), its issues, proposals, releases and settings (never a secret value){% if kind == "org" %}, and the organisation's members and teams{% endif %}. Only what changed since the last run travels, and any kept run can be restored with <code>oxygenhub admin restore</code>.</p>
10
11
<formclass="card wide backup-form"method="post"action="{{ base }}">
{% for (v, label) in every() %}<labelclass="choice"><inputtype="radio"name="every"value="{{ v }}"{% ifsetting.every== *v %} checked{% endif %}> {{ label }}</label>{% endfor %}
17
</fieldset>
18
<fieldsetclass="choices">
19
<legendclass="small mute">Where</legend>
20
{% if !dirs.is_empty() %}<labelclass="choice"><inputtype="radio"name="destination"value="dir"{% ifsetting.destination== "dir" %} checked{% endif %}> A directory on this hub's host</label>{% endif %}
21
<labelclass="choice"><inputtype="radio"name="destination"value="gcs"{% ifsetting.destination== "gcs" || dirs.is_empty() %} checked{% endif %}> A Google Cloud Storage bucket, with no key</label>
22
</fieldset>
23
{% if !dirs.is_empty() %}
24
<labelfor="dir">Directory</label>
25
<selectid="dir"name="dir">{% for d in dirs %}<optionvalue="{{ d }}"{% ifsetting.destination== "dir" && setting.target== *d %} selected{% endif %}>{{ d }}/{{ owner }}</option>{% endfor %}</select>
<pclass="small mute">The hub signs in as <code>backup:{{ owner }}</code> with a token it issues itself; Google exchanges it for a few minutes' access to this bucket. No key file exists. One-time setup: <ahref="/help#backups">Help › Backups</a> (docs/backups.md §6).</p>
<selectid="keep_days"name="keep_days">{% for k in keeps() %}<optionvalue="{{ k }}"{% ifsetting.keep_days== *k %} selected{% endif %}>{{ k }} days</option>{% endfor %}</select>
<formclass="inline more"method="post"action="{{ base }}/run"><inputtype="hidden"name="_csrf"value="{{ shell.csrf }}"><buttontype="submit"class="small primary-btn"{% ifsetting.updated_ms==0 %} disabledtitle="Save where backups go first"{% endif %}>Back up now</button></form>
42
</div>
43
{% if runs.is_empty() %}<pclass="empty small">No runs yet.{% if setting.every == "off" %} Pick how often and where, then save.{% endif %}</p>