Skip to content

Commit 732a933

Browse files
committed
Updating R2 chapters dashboard instructions
1 parent aed407f commit 732a933

19 files changed

+142
-445
lines changed

src/content/docs/r2/buckets/bucket-locks.mdx

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@ title: Bucket locks
33
pcx_content_type: how-to
44
---
55

6+
import { DashButton } from "~/components";
7+
68
Bucket locks prevent the deletion and overwriting of objects in an R2 bucket for a specified period — or indefinitely. When enabled, bucket locks enforce retention policies on your objects, helping protect them from accidental or premature deletions.
79

810
## Get started with bucket locks
@@ -14,7 +16,7 @@ Before getting started, you will need:
1416

1517
### Enable bucket lock via dashboard
1618

17-
1. From the Cloudflare dashboard, select **R2** from the sidebar.
19+
1. <DashButton url="/?to=/:account/r2/overview" />
1820
2. Select the bucket you would like to add bucket lock rule to.
1921
3. Switch to the **Settings** tab, then scroll down to the **Bucket lock rules** card.
2022
4. Select **Add rule** and enter the rule name, prefix, and retention period.
@@ -87,7 +89,7 @@ If your bucket is setup with [jurisdictional restrictions](/r2/reference/data-lo
8789

8890
### Dashboard
8991

90-
1. From the Cloudflare dashboard, select **R2** from the sidebar.
92+
1. <DashButton url="/?to=/:account/r2/overview" />
9193
2. Select the bucket you would like to add bucket lock rule to.
9294
3. Switch to the **Settings** tab, then scroll down to the **Bucket lock rules** card.
9395

@@ -107,7 +109,7 @@ For more information on required parameters and examples of how to get bucket lo
107109

108110
### Dashboard
109111

110-
1. From the Cloudflare dashboard, select **R2** from the sidebar.
112+
1. <DashButton url="/?to=/:account/r2/overview" />
111113
2. Select the bucket you would like to add bucket lock rule to.
112114
3. Switch to the **Settings** tab, then scroll down to the **Bucket lock rules** card.
113115
4. Locate the rule you want to remove, select the `...` icon next to it, and then select **Delete**.

src/content/docs/r2/buckets/cors.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,9 +73,9 @@ curl --request PUT <URL> --header "Content-Type: text/plain" --data "123"
7373

7474
## Add CORS policies from the dashboard
7575

76-
1. From the Cloudflare dashboard, select **R2**.
76+
1. <DashButton url="/?to=/:account/r2/overview" />
7777
2. Locate and select your bucket from the list.
78-
3. From your bucket’s page, select **Settings**.
78+
3. Select **Settings**.
7979
4. Under **CORS Policy**, select **Add CORS policy**.
8080
5. From the **JSON** tab, manually enter or copy and paste your policy into the text box.
8181
6. When you are done, select **Save**.

src/content/docs/r2/buckets/event-notifications.mdx

Lines changed: 20 additions & 146 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@ title: Event notifications
33
pcx_content_type: how-to
44
---
55

6+
import { DashButton } from "~/components";
7+
68
Event notifications send messages to your [queue](/queues/) when data in your R2 bucket changes. You can consume these messages with a [consumer Worker](/queues/reference/how-queues-works/#create-a-consumer-worker) or [pull over HTTP](/queues/configuration/pull-consumers/) from outside of Cloudflare Workers.
79

810
## Get started with event notifications
@@ -17,7 +19,7 @@ Before getting started, you will need:
1719

1820
### Enable event notifications via Dashboard
1921

20-
1. From the Cloudflare dashboard, select **R2** from the sidebar.
22+
1. <DashButton url="/?to=/:account/r2/overview" />
2123
2. Select the bucket you'd like to add an event notification rule to.
2224
3. Switch to the **Settings** tab, then scroll down to the **Event notifications** card.
2325
4. Select **Add notification** and choose the queue you'd like to receive notifications and the [type of events](/r2/buckets/event-notifications/#event-types) that will trigger them.
@@ -58,51 +60,10 @@ Event notification rules determine the [event types](/r2/buckets/event-notificat
5860

5961
## Event types
6062

61-
<table>
62-
<tbody>
63-
<th style="width:25%">Event type</th>
64-
<th style="width:50%">Description</th>
65-
<th style="width:25%">Trigger actions</th>
66-
<tr>
67-
<td>
68-
<code>object-create</code>
69-
</td>
70-
<td>
71-
Triggered when new objects are created or existing objects are
72-
overwritten.
73-
</td>
74-
<td>
75-
<ul>
76-
<li>
77-
<code>PutObject</code>
78-
</li>
79-
<li>
80-
<code>CopyObject</code>
81-
</li>
82-
<li>
83-
<code>CompleteMultipartUpload</code>
84-
</li>
85-
</ul>
86-
</td>
87-
</tr>
88-
<tr>
89-
<td>
90-
<code>object-delete</code>
91-
</td>
92-
<td>Triggered when an object is explicitly removed from the bucket.</td>
93-
<td>
94-
<ul>
95-
<li>
96-
<code>DeleteObject</code>
97-
</li>
98-
<li>
99-
<code>LifecycleDeletion</code>
100-
</li>
101-
</ul>
102-
</td>
103-
</tr>
104-
</tbody>
105-
</table>
63+
| Event type | Description | Trigger actions |
64+
|------------|-------------|----------------|
65+
| `object-create` | Triggered when new objects are created or existing objects are overwritten. | <ul><li>`PutObject`</li><li>`CopyObject`</li><li>`CompleteMultipartUpload`</li></ul> |
66+
| `object-delete` | Triggered when an object is explicitly removed from the bucket. | <ul><li>`DeleteObject`</li><li>`LifecycleDeletion`</li></ul> |
10667

10768
## Message format
10869

@@ -128,106 +89,19 @@ Queue consumers receive notifications as [Messages](/queues/configuration/javasc
12889

12990
### Properties
13091

131-
<table>
132-
<tbody>
133-
<th style="width:22%">Property</th>
134-
<th style="width:18%">Type</th>
135-
<th style="width:60%">Description</th>
136-
<tr>
137-
<td>
138-
<code>account</code>
139-
</td>
140-
<td>String</td>
141-
<td>The Cloudflare account ID that the event is associated with.</td>
142-
</tr>
143-
<tr>
144-
<td>
145-
<code>action</code>
146-
</td>
147-
<td>String</td>
148-
<td>
149-
The type of action that triggered the event notification. Example
150-
actions include: <code>PutObject</code>, <code>CopyObject</code>,{" "}
151-
<code>CompleteMultipartUpload</code>, <code>DeleteObject</code>.
152-
</td>
153-
</tr>
154-
<tr>
155-
<td>
156-
<code>bucket</code>
157-
</td>
158-
<td>String</td>
159-
<td>The name of the bucket where the event occurred.</td>
160-
</tr>
161-
<tr>
162-
<td>
163-
<code>object</code>
164-
</td>
165-
<td>Object</td>
166-
<td>
167-
A nested object containing details about the object involved in the
168-
event.
169-
</td>
170-
</tr>
171-
<tr>
172-
<td>
173-
<code>object.key</code>
174-
</td>
175-
<td>String</td>
176-
<td>The key (or name) of the object within the bucket.</td>
177-
</tr>
178-
<tr>
179-
<td>
180-
<code>object.size</code>
181-
</td>
182-
<td>Number</td>
183-
<td>
184-
The size of the object in bytes. Note: not present for object-delete
185-
events.
186-
</td>
187-
</tr>
188-
<tr>
189-
<td>
190-
<code>object.eTag</code>
191-
</td>
192-
<td>String</td>
193-
<td>
194-
The entity tag (eTag) of the object. Note: not present for object-delete
195-
events.
196-
</td>
197-
</tr>
198-
<tr>
199-
<td>
200-
<code>eventTime</code>
201-
</td>
202-
<td>String</td>
203-
<td>The time when the action that triggered the event occurred.</td>
204-
</tr>
205-
<tr>
206-
<td>
207-
<code>copySource</code>
208-
</td>
209-
<td>Object</td>
210-
<td>
211-
A nested object containing details about the source of a copied object.
212-
Note: only present for events triggered by <code>CopyObject</code>.
213-
</td>
214-
</tr>
215-
<tr>
216-
<td>
217-
<code>copySource.bucket</code>
218-
</td>
219-
<td>String</td>
220-
<td>The bucket that contained the source object.</td>
221-
</tr>
222-
<tr>
223-
<td>
224-
<code>copySource.object</code>
225-
</td>
226-
<td>String</td>
227-
<td>The name of the source object.</td>
228-
</tr>
229-
</tbody>
230-
</table>
92+
| Property | Type | Description |
93+
|----------|------|-------------|
94+
| `account` | String | The Cloudflare account ID that the event is associated with. |
95+
| `action` | String | The type of action that triggered the event notification. Example actions include: `PutObject`, `CopyObject`, `CompleteMultipartUpload`, `DeleteObject`. |
96+
| `bucket` | String | The name of the bucket where the event occurred. |
97+
| `object` | Object | A nested object containing details about the object involved in the event. |
98+
| `object.key` | String | The key (or name) of the object within the bucket. |
99+
| `object.size` | Number | The size of the object in bytes. Note: not present for object-delete events. |
100+
| `object.eTag` | String | The entity tag (eTag) of the object. Note: not present for object-delete events. |
101+
| `eventTime` | String | The time when the action that triggered the event occurred. |
102+
| `copySource` | Object | A nested object containing details about the source of a copied object. Note: only present for events triggered by `CopyObject`. |
103+
| `copySource.bucket` | String | The bucket that contained the source object. |
104+
| `copySource.object` | String | The name of the source object. |
231105

232106
## Notes
233107

src/content/docs/r2/buckets/object-lifecycles.mdx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@ title: Object lifecycles
33
pcx_content_type: how-to
44
---
55

6+
import { DashButton } from "~/components";
7+
68
Object lifecycles determine the retention period of objects uploaded to your bucket and allow you to specify when objects should transition from Standard storage to Infrequent Access storage.
79

810
A lifecycle configuration is a collection of lifecycle rules that define actions to apply to objects during their lifetime.
@@ -27,7 +29,7 @@ When you create an object lifecycle rule, you can specify which prefix you would
2729

2830
### Dashboard
2931

30-
1. From the Cloudflare dashboard, select **R2**.
32+
1. <DashButton url="/?to=/:account/r2/overview" />
3133
2. Locate and select your bucket from the list.
3234
3. From the bucket page, select **Settings**.
3335
4. Under **Object Lifecycle Rules**, select **Add rule**.
@@ -176,7 +178,7 @@ console.log(
176178

177179
### Dashboard
178180

179-
1. From the Cloudflare dashboard, select **R2**.
181+
1. <DashButton url="/?to=/:account/r2/overview" />
180182
2. Locate and select your bucket from the list.
181183
3. From the bucket page, select **Settings**.
182184
4. Under **Object lifecycle rules**, select the rules you would like to delete.

src/content/docs/r2/buckets/public-buckets.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ To remove a domain:
101101
1. In **R2**, select the bucket you want to modify.
102102
2. On the bucket page, Select **Settings**, go to **Custom Domains**.
103103
3. Next to the domain you want to disable, select **...** and **Remove domain**.
104-
4. Select Remove domain in the confirmation window. This step also removes the CNAME record pointing to the domain. You can always add the domain again.
104+
4. Select **Remove domain** in the confirmation window. This step also removes the CNAME record pointing to the domain. You can always add the domain again.
105105

106106
## Public development URL
107107

@@ -125,14 +125,14 @@ To enable access through `r2.dev` for your buckets:
125125
1. In **R2**, select the bucket you want to modify.
126126
2. On the bucket page, select **Settings**.
127127
3. Under **Public Development URL**, select **Enable**.
128-
4. In **Allow Public Access?**, confirm your choice by typing allow to confirm and select **Allow**.
128+
4. In **Allow Public Access?**, confirm your choice by typing `allow` to confirm and select **Allow**.
129129
5. You can now access the bucket and its objects using the Public Bucket URL.
130130

131131
To verify that your bucket is publicly accessible, check that **Public URL Access** shows **Allowed** in you bucket settings.
132132

133133
### Disable public development url
134134

135-
Disabling public development URL access removes your buckets exposure through the `r2.dev` subdomain. The bucket and its objects will no longer be accessible via the Public Bucket URL.
135+
Disabling public development URL access removes your bucket's exposure through the `r2.dev` subdomain. The bucket and its objects will no longer be accessible via the Public Bucket URL.
136136

137137
If you have connected other domains, the bucket will remain accessible for those domains.
138138

@@ -141,4 +141,4 @@ To disable public access for your bucket:
141141
1. In **R2**, select the bucket you want to modify.
142142
2. On the bucket page, select **Settings**.
143143
3. Under **Public Development URL**, select **Disable**.
144-
4. In **Disallow Public Access?**, type disallow to confirm and select **Disallow**.
144+
4. In **Disallow Public Access?**, type `disallow` to confirm and select **Disallow**.

src/content/docs/r2/buckets/storage-classes.mdx

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -38,21 +38,13 @@ Standard storage is designed for data that is accessed frequently. This is the d
3838
### Infrequent Access storage <Badge text="Beta" variant="caution" size="small" />
3939

4040
:::note[Open Beta]
41-
42-
4341
This feature is currently in beta. To report bugs or request features, go to the #r2 channel in the [Cloudflare Developer Discord](https://discord.cloudflare.com) or fill out the [feedback form](https://forms.gle/5FqffSHcsL8ifEG8A).
44-
45-
4642
:::
4743

4844
Infrequent Access storage is ideal for data that is accessed less frequently. This storage class offers lower storage cost compared to Standard storage, but includes [retrieval fees](/r2/pricing/#data-retrieval) and a 30 day [minimum storage duration](/r2/pricing/#minimum-storage-duration) requirement.
4945

5046
:::note
51-
52-
5347
For objects stored in Infrequent Access storage, you will be charged for the object for the minimum storage duration even if the object was deleted, moved, or replaced before the specified duration.
54-
55-
5648
:::
5749

5850
#### Example use cases
@@ -76,11 +68,7 @@ To learn more about how to specify the storage class for new objects, refer to t
7668
### Use object lifecycle rules to transition objects to Infrequent Access storage
7769

7870
:::note
79-
80-
8171
Once an object is stored in Infrequent Access, it cannot be transitioned to Standard Access using lifecycle policies.
82-
83-
8472
:::
8573

8674
To learn more about how to transition objects from Standard storage to Infrequent Access storage, refer to [Object lifecycles](/r2/buckets/object-lifecycles/).

0 commit comments

Comments
 (0)