I have a Droplet running named XXX.
Inside /etc/nginx/sites-enabled/XXX.xx
I have the following configuration.
server {
server_name XXX.xx www.XXX.xx;
location / {
proxy_pass http://localhost:5000;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection keep-alive;
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
location /images/ {
alias /mnt/XXXblob/images/;
}
listen 443 ssl; # managed by Certbot
ssl_certificate /etc/letsencrypt/live/XXX.xx/fullchain.pem; # managed by Certbot
ssl_certificate_key /etc/letsencrypt/live/XXX.xx/privkey.pem; # managed by Certbot
include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
}
Before that I also have runned
sudo chown -R www-data:www-data /mnt/XXXBlob/images/
When I look up /etc/fstab it has the following content.
LABEL=cloudimg-rootfs / ext4 defaults 0 0 LABEL=UEFI /boot/efi vfat defaults 0 0 /dev/disk/by-id/scsi-0DO_Volume_XXXBlob /home/portal/XXXBlob ext4 defaults,nofail,discard 0 2
Any help are appreciated!
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Hi there,
According to the fstab, your volume should be mounted at /home/portal/XXXBlob. What is the output of the following command:
df -h
What I could suggest here is to mount the volume not on /mnt but inside your document root, so for example if your website files are hosted at /var/www/html/ you could mount the disk to images folder at /var/www/html/images.
Regards, Bobby
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.