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 documentation for buckets and resizing a volume #174

Closed
wants to merge 2 commits into from
Closed
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
45 changes: 45 additions & 0 deletions devzero-storage/object-storage.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
---
title: Object Storage
---
# Buckets

Check failure on line 4 in devzero-storage/object-storage.md

View workflow job for this annotation

GitHub Actions / markdown-linter

Multiple top-level headings in the same document

devzero-storage/object-storage.md:4 MD025/single-title/single-h1 Multiple top-level headings in the same document [Context: "# Buckets"] https://github.com/DavidAnson/markdownlint/blob/v0.34.0/doc/md025.md

Check failure on line 4 in devzero-storage/object-storage.md

View workflow job for this annotation

GitHub Actions / markdown-linter

Multiple top-level headings in the same document

devzero-storage/object-storage.md:4 MD025/single-title/single-h1 Multiple top-level headings in the same document [Context: "# Buckets"] https://github.com/DavidAnson/markdownlint/blob/v0.34.0/doc/md025.md

DevZero's buckets allow storing a group of objects (with an API compatible with AWS S3).
Buckets are regional in nature and can be access by any workspace in that region.

## Creating a Bucket

Bucket names must be unique across all of DevZero, so we generate bucket names from a prefix you provide

### In your default region

{% code %}
```
$ dz storage bucket create --prefix=my-fancy-bucket
ID Name Region Status
bucket-481692276ad14fcf96a32e176d597731 my-fancy-bucket-481692276ad14fcf96a32e176d597731 Portland, USA Creating

```
{% endcode %}

### In an arbitrary region

{% code %}
```
$ dz storage bucket create --prefix=other-fancy-bucket --region=eu-north-1
ID Name Region Status
bucket-eaed65a5ff9a4a0284d28ad61f962f5f other-fancy-bucket-eaed65a5ff9a4a0284d28ad61f962f5f Stockholm, Sweden Creating
```
{% endcode %}

## Listing your buckets

{% code %}
```
$ dz storage bucket list
ID Name Region Status
bucket-eaed65a5ff9a4a0284d28ad61f962f5f my-fancy-bucket-eaed65a5ff9a4a0284d28ad61f962f5f Portland, USA Available
bucket-481692276ad14fcf96a32e176d597731 other-fancy-bucket-481692276ad14fcf96a32e176d597731 Stockholm, Sweden Available
```
{% endcode %}

## Accessing a bucket from a workspace
6 changes: 5 additions & 1 deletion devzero-storage/overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,12 @@ Ceph is a free and open-source software-defined storage platform that provides o

## Mount

The methodology that's used to enable a workspace to have access to persistent volumes (can be verified by running mount in a UNIX shell).
The method that's used to enable a workspace to have access to persistent volumes (can be verified by running mount in a UNIX shell).

## Persistent Volumes

Persistent volumes are network-backed block devices that are mounted to workspaces. This ensures that changes made inside a workspace are resilient to restarts, etc.

## Object Storage
Object storage is a netword-based storage system that stores data as unstructured objects, as opposed to a hierarchical filesystem.
Common Object store services include AWS S3 and Microsoft Azure Blob Storage. DevZero uses an S3-compatible object store backed by Ceph.
29 changes: 20 additions & 9 deletions devzero-storage/volume-elastic-nfs.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ Volumes are regional in nature and can be attached to any workspace in that regi
{% code %}
```
$ dz storage volume create --name=my-fancy-volume --size=50
ID Name Total size (GB) Region
7947b1c8-881c-49fb-b5c7-c3e0367a76f2 my-fancy-volume 50 Portland, USA
ID Name Total size (GB) Region
volume-7947b1c8881c49fbb5c7c3e0367a76f2 my-fancy-volume 50 Portland, USA
```
{% endcode %}

Expand All @@ -23,8 +23,8 @@ ID Name Total size (GB) Region
{% code %}
```
$ dz storage volume create --name=other-fancy-volume --size=50 --region=eu-north-1
ID Name Total size (GB) Region
e71e024e-ba0a-443a-b452-c931e8ce39a5 other-fancy-volume 50 Stockholm, Sweden
ID Name Total size (GB) Region
volume-e71e024eba0a443ab452c931e8ce39a5 other-fancy-volume 50 Stockholm, Sweden
```
{% endcode %}

Expand All @@ -33,9 +33,9 @@ e71e024e-ba0a-443a-b452-c931e8ce39a5 other-fancy-volume 50
{% code %}
```
$ dz storage volume list
ID Name Total size (GB) Region
7947b1c8-881c-49fb-b5c7-c3e0367a76f2 my-fancy-volume 50 Portland, USA
e71e024e-ba0a-443a-b452-c931e8ce39a5 other-fancy-volume 50 Stockholm, Sweden
ID Name Total size (GB) Region
volume-7947b1c8881c49fbb5c7c3e0367a76f2 my-fancy-volume 50 Portland, USA
volume-e71e024eba0a443ab452c931e8ce39a5 other-fancy-volume 50 Stockholm, Sweden
```
{% endcode %}

Expand All @@ -45,7 +45,7 @@ The volume is mounted at the path specified by the `--mount` flag.

{% code %}
```
$ dz workspace launch "My Recipe Name" --region=us-west-2 --mount /mnt/my-shared-volume=7947b1c8-881c-49fb-b5c7-c3e0367a76f2
$ dz workspace launch "My Recipe Name" --region=us-west-2 --mount /mnt/my-shared-volume=volume-7947b1c8881c49fbb5c7c3e0367a76f2
Your workspace is currently being built... please wait!
🚀 workspace launch: success
Successfully deployed workspace dear-filly-ubhg
Expand All @@ -54,7 +54,7 @@ dz workspace connect dear-filly-ubhg

# OR

$ dz workspace launch "My Recipe Name" --region=eu-north-1 --mount /mnt/my-shared-volume=e71e024e-ba0a-443a-b452-c931e8ce39a5
$ dz workspace launch "My Recipe Name" --region=eu-north-1 --mount /mnt/my-shared-volume=volume-e71e024eba0a443ab452c931e8ce39a5
Your workspace is currently being built... please wait!
🚀 workspace launch: success
Successfully deployed workspace abominal-monkey-ytui
Expand All @@ -80,3 +80,14 @@ Filesystem K-blocks Used Available Use% Mounted on
[some path..] 10485760 0 10485760 0% /mnt/my-shared-volume
```
{% endcode %}

## Resizing a volume

To change the size of a volume, you can run:
{% code %}
```
$ dz storage volume edit volume-7947b1c8881c49fbb5c7c3e0367a76f2 --size 100
ID Name Total size (GB) Region
volume-7947b1c8881c49fbb5c7c3e0367a76f2 my-fancy-volume 100 Portland, USA
```
{% endcode %}
Loading