You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
echo"deb [signed-by=/etc/apt/keyrings/plex.gpg] https://downloads.plex.tv/repo/deb public main"| sudo tee /etc/apt/sources.list.d/plexmediaserver.list
48
49
```
49
50
4. Install Plex and s3fs:
50
51
51
-
Now, as the Plex repository is enabled, update the APT package list and install the latest version of Plex and s3fs, which is needed to mount the Object Storage bucket.
52
-
```
52
+
Update the APT package list and install the latest version of Plex and s3fs:
53
+
```bash
53
54
apt update
54
55
apt install -y plexmediaserver s3fs
55
56
```
56
57
57
58
### Configuring s3fs
58
59
59
-
1. Create the folder on which you will mount the bucket.
60
-
```
60
+
1. Create the folder on which you will mount the bucket:
61
+
```bash
61
62
mkdir -p /mnt/media
62
63
```
63
-
2. Enter your API keys in the password file and set owner-only permissions.
64
-
```
65
-
echo $ACCESS_KEY:$SECRET_KEY > ~/.passwd-s3fs
66
-
chmod 600 ~/.passwd-s3fs
67
-
```
68
-
3. Uncomment `user_allow_other` in the `/etc/fuse.conf` file to allow other users to access the server. You can use a text editor of your choice. In this tutorial we use `nano`.
64
+
2. Obtain and configure API keys for Scaleway Object Storage:
65
+
66
+
- Log in to your [Scaleway console](https://console.scaleway.com) and navigate to Object Storage.
67
+
- Select or create a bucket.
68
+
-[Create an API](/iam/how-to/create-api-keys/) key with `ObjectStorageFullAccess` permission.
69
+
70
+
3. Enter your API keys in the password file and set proper permissions:
71
+
```bash
72
+
echo ACCESS_KEY_ID:SECRET_ACCESS_KEY | sudo tee /etc/passwd-s3fs
73
+
sudo chmod 600 /etc/passwd-s3fs
69
74
```
70
-
nano /etc/fuse.conf
75
+
4. Uncomment `user_allow_other` in the `/etc/fuse.conf` file:
Replace `plexmediaserver` with the name of your bucket and `nl-ams` with the region of your bucket, if necessary.
86
+
Replace `BUCKET_NAME` with the name of your bucket and `REGION` with its appropriate code (e.g., `nl-ams`).
80
87
</Message>
81
-
5. (Optional) To mount the bucket automatically during boot, create a [systemd](/tutorials/systemd-essentials/) script, called `/etc/systemd/user/s3fs.service`:
6. Enable the script by running the following commands:
98
-
```
99
-
systemctl --user enable s3fs.service
100
-
systemctl --user start s3fs.service
101
-
```
102
-
103
-
If you ever want to disable the automatic mounting, run the following command:
104
-
105
-
```
106
-
systemctl --user stop s3fs.service
88
+
6. (Optional) Enable automatic mounting at boot by adding an entry to `/etc/fstab`:
89
+
```bash
90
+
echo"s3fs#BUCKET_NAME /mnt/media fuse _netdev,allow_other,umask=0002,passwd_file=/etc/passwd-s3fs,url=https://s3.REGION.scw.cloud 0 0"| sudo tee -a /etc/fstab
107
91
```
108
92
109
93
### Configuring Plex
110
94
111
-
1. Check that Plex is running before continuing:
112
-
```
95
+
1. Check that Plex is running:
96
+
```bash
113
97
systemctl status plexmediaserver.service
114
98
```
115
-
116
-
The output should look like this example:
117
-
118
-
```
119
-
● plexmediaserver.service - Plex Media Server for Linux
- On Windows computers, you can create the tunnel by using [PuTTY](https://www.chiark.greenend.org.uk/~sgtatham/putty/):
134
-
- Open PuTTY, and enter your server IP address in the hostname and SSH port. Or, if you already have your server session set up and saved, just load the existing session.
135
-
- Go to **Connection** > **SSH** > **Tunnels**.
136
-
- Fill in **Source port** as **8888** and **Destination** as **localhost:32400**.
137
-
- Click the **Add** button.
138
-
- Navigate back to the session homepage now and click the **Save** button, then **Open** to connect to the server.
139
-
140
-
Open a web browser on your local computer and navigate to `http://localhost:8888/web`. The Plex login screen displays:
3. Access the Plex interface with your server IP address:
151
-
- Open a web browser on your local computer and navigate to `http://<plex.server.ip>:32400`
152
-
- The Plex login screen should display.
153
-
154
-
<Messagetype="note">
155
-
The port `32400` is the default used by Plex for the interface.
156
-
</Message>
157
-
4. Enter the required parameters and click **Next** to complete the setup.
158
-
<Messagetype="note">
159
-
Make sure the checkbox `Allow me to access my media outside my home` is ticked, so you can access your media files from any device.
160
-
</Message>
161
-
5. Click **Add a library** to create a new media gallery.
162
-
6. Select the type of library you wish to create and click **Next**.
163
-
7. Click **Browse and select a multimedia folder** to do so.
164
-
- Plex recommends creating separate folders for each type of media. For example, if your library is about movies, create a folder `Movies` in your bucket, through the `/mnt/media` mounted folder or the Scaleway console.
165
-
- You should see the `Movies` folder inside Plex, in the browse window.
166
-
8. Select `/mnt/media/<Folder name>` as the media folder.
You can upload additional content to your server with any Amazon S3-compatible tool, like [Cyberduck](/tutorials/store-s3-cyberduck/).
112
+
A Plex account is required.
171
113
</Message>
172
-
9. Click **Next** and then **Finish** to conclude the set-up.
173
-
10. Add media to your bucket and trigger a scan of your media folder in the Plex interface. Your media should display. If so, it is all set up. For more information about Plex, refer to their [official documentation](https://support.plex.tv/articles/).
114
+
3. Configure the Plex server:
115
+
- Open `http://<plex.server.ip>:32400` in a browser.
116
+
- Complete the setup wizard.
117
+
- Add a library and specify `/mnt/media/<Folder Name>` as the media folder.
118
+
<Lightboxsrc="scaleway-plex-add-folder.webp"alt="Adding a media folder in Plex" />
119
+
4. To upload media, use an S3-compatible tool like Cyberduck.
120
+
5. Trigger a media scan in Plex to display new files.
121
+
122
+
For more information, refer to [Plex's official documentation](https://support.plex.tv/articles/).
0 commit comments