How To Manage DigitalOcean Spaces with Transmit 4
Transmit is a macOS-only file transfer utility developed by Panic, Inc.. It handles a wide variety of server types including FTP, SFTP, WebDAV, and most importantly for this article: S3-compatible servers.
DigitalOcean Spaces is an object storage service that is compatible with the S3 API. In this tutorial we will show you how to use Transmit 4 to connect to a Space, navigate, manipulate permissions, retrieve public URLs for your objects, and create new Spaces.
- You must already have Transmit 4 installed (a downloadable
.zipfile is here). Note that the most recent version of Transmit is Transmit 5. A Transmit 5 tutorial will be published soon.
- You must have an access key and secret key for Spaces. These are available in the API section of the DigitalOcean Control Panel. This is covered in more detail in the Creating an Access Key section of our tutorial How To Create a DigitalOcean Space and API Key
Step 1 — Connect to Spaces
Launch the Transmit application by clicking on its icon in the dock, or double-clicking its icon in your Applications folder. Transmit will open and display a window with your local filesystem on the left, and an FTP connection pane on the right:
At the top of the right-hand pane, Transmit 4 lists the different types of connections it supports, FTP, SFTP, S3, and WebDAV. Click on S3 to bring up the form for connecting to an S3-compatible server. Fill in the following details:
- Server: this should be the DigitalOcean datacenter region (
ams3, etc.) followed by
.digitaloceanspaces.com. We will use
nyc3.digitaloceanspaces.comin this tutorial.
- Access Key ID:
- Initial Path: leave this blank to open a list of all your NYC3 Spaces when you connect, or add the name of a pre-existing Space here to navigate directly to it when connecting
When all filled out, the connection pane should look similar to this:
Click the blue Connect button to connect to Spaces. Transmit will connect, then display a list of your Spaces (if you left the Initial Path option blank):
If you have not yet created a Space, this will be empty. Let's use Transmit to make a Space next.
Step 2 — Create a New Space
To create a new Space with Transmit 4, first make sure you're in the root directory where all your Spaces are listed. You can do this by clicking the
/ slash all the way on the left of breadcrumb trail at the top of the right-hand pane:
Once you've done that, click on the Action menu in the toolbar (it has a gear-shaped icon), then choose New Bucket…. A bucket is the S3-compatible name for an individual Space.
A dialog will pop up, asking for a bucket name and location.
Choose any name that fits the guidelines mentioned in the dialog. Leave the default Location value. Click Create and your new bucket will be created and added to the list.
Note: Space names must be unique across all regions, so if your name is already in use anywhere on
digitaloceanspaces.com, Transmit will give you an error. If this happens, try another name.
Next, we'll navigate into our new Space and add some files.
Step 3 — Create Some Content in Your Space
Double-click on the folder that represents your Space. This will open it and list its contents in the right-hand pane:
To upload a file, first navigate through your local filesystem using the left-hand side of the Transmit window. When you've found a suitable file to upload (pick something like a JPG or HTML file, so we can test in the browser), click and drag it from the left-hand pane to the right. It will copy over to your Space and show up in the directory listing on the right-hand side.
You can also drag and drop files directly from the macOS Finder.
Next, we'll test permissions and learn how to make files publicly accessible.
Step 4 — Adjust Permissions and Test Public Access
By default, the files in your Spaces are not made available to the public. Let's find the public URL for a file and see what happens when we try to load it in a web browser. In the right-hand pane, after navigating to your Space, click once on a file you'd like to view. This will select the file. Then click on the Action menu in the toolbar:
Select Copy URL from the Action menu. A web address will be copied to your clipboard. Switch over to your browser, paste the URL into the location bar, and hit
AccessDenied error will load:
To remedy this, we need to change the Read permissions on this file. With the file still selected, use the Action menu again, this time choosing to Get Info. A window will open with more details about the file, including its size, location, kind, and Read and Write permissions:
Use the dropdown menu next to Read: to change the setting from Owner to World, then click the Apply button at the bottom of the info window:
Transmit will update the permissions on the file. Return to your browser and reload the URL we tried before. Your file should successfully load.
In this tutorial, you used Transmit 4 to connect to DigitalOcean Spaces and navigate, create new Spaces, update permissions, upload files, and retrieve public URLs. To learn more about other Transmit features that could help integrate Spaces into your macOS-based workflow, visit Panic's Transmit Documentation Library.