Questions tagged [static-files]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0
votes
0answers
29 views

Intermittent 404 For Static JavaScript Assets, Passenger Rails Apache Stack

I'm working with a Rails 4.2 single page app, running on a cluster of Apache servers with Phusion Passenger. Assets are set to precompile, with digests, and Apache serves static files. The main page ...
0
votes
0answers
48 views

Nginx alias not working on https but working on http

I hope this is going to be a relatively simple one but I'm stumped and searching through potential solutions haven't helped. I am looking to serve a static (ads.txt) file for my Ghost droplet on ...
0
votes
3answers
123 views

We are migrating our wordpress to static site. That is creating over 400,000 folders within 1 folder. Is there any limit to the number of sub-folders?

Our wordpress web site is several years old and has many posts indexed and ranking well on google. With any serious traffic my wordpress server tanks - and this happens even after several rounds of ...
0
votes
0answers
31 views

sharing assets between domain and subdomain without sharing with public

I want to put my images in img.mysite.tld hosted in gitlab And use them in my static site mysite.tld & www. mysite.tld, hosted in netlify. But ensure that no other domain can use them like using ...
0
votes
0answers
71 views

htaccess not redirecting images?

I'm trying to force all content to use HTTPS. I added the following rule to my htaccess: RewriteCond %{HTTPS} off RewriteCond %{HTTP:X-Forwarded-Proto} =http RewriteRule ^.*$ https://%{HTTP_HOST}%{...
0
votes
1answer
267 views

s3 static site: Amazon using wrong bucket

I'm setting up a static site, hosted on S3, using this set of directions: https://www.linode.com/docs/platform/object-storage/host-static-site-object-storage/ I've set my bucket up with the name ...
1
vote
0answers
122 views

Mixing private and public static files in AWS is either fully private or fully public

I am trying to move my static assets to AWS. I am following many blog posts but most of all this one: https://simpleisbetterthancomplex.com/tutorial/2017/08/01/how-to-setup-amazon-s3-in-a-django-...
0
votes
1answer
164 views

Any way to reduce redundant location block codes in Nginx config?

Is it possible to DRY a bunch of location blocks in Nginx with the exact same configuration, just different routes? Take a look at the following snippet off my Nginx .conf, for instance: location / { ...
2
votes
1answer
2k views

Unable to serve NextJS static assets through Nginx

I have a NextJS app running on port 3000 and I have a test.ico file located at the following location: /static/images/icons/ I want this file to be served off the root rather than the actual path. I ...
0
votes
1answer
309 views

What does rsync status code 3072 mean?

I'm using the static site generator Nanoc, with rsync locally and on the (ancient Ubuntu) server so I can deploy from the command line. It's been awhile since I last used rsync for this site but I'm ...
1
vote
2answers
365 views

How to manage static content for high-loaded website via nginx?

My understanding is that nginx is well-suited for serving static content. But i can't find any information with regard to how well it's for serving very big amount of static content. Let's say i use ...
0
votes
1answer
593 views

nginx static files served on server using curl, but not to browser on remote machine

I'm working my way through my first nginx / gunicorn / flask deployment using a stock Amazon Lightsail Ubuntu server. At this point, I'm ignoring gunicorn and flask, and just trying to get nginx to ...
0
votes
0answers
777 views

Nginx Subdirectory returning 404

I currently have a bunch of working static files at the domain name khairulslt.me (from NameCheap). Recently, I've tried setting up a subdirectory (khairulslt.me/RGBGame) as seen in the code below; ...
0
votes
0answers
603 views

Nginx: disable caching if page contains the word

I am using nginx as a reverse proxy. Is it possible somehow to access response page content as a variable to disable caching for a pages that have specific word in content (not in header) WITHOUT ...
0
votes
1answer
436 views

nginx serving static files doesn't work properly with comma character

Summary: Static files are publishing in /path/to/root , If the request is not in the static folders, the request sending @a1 location block. Static files; /path/to/root/folder/folder1,111/index....
1
vote
1answer
604 views

img 404 using Nginx, Docker, Django, Digital Ocean

For some reason, my CSS, JS, and Font-Awesome static assets are recognized and serving properly, but my img static files are showing 404 errors in the Nginx Docker container logs. Everything works ...
1
vote
1answer
2k views

Nginx: / for both static content and proxied application

http://example.com: my site http://example.net: the proxied backend I'm trying to setup an nginx server block as both a static content server and a reverse proxy. Nginx should first check for static ...
1
vote
1answer
397 views

How to serve a huge static and pregenerated website?

My current web project has the following characteristics: A website which is basically a read-only archive of information. There are no interactive actions a visitor could do. All pages (currently ...
0
votes
0answers
314 views

Web application serving static files using Docker on multiple hosts

Before Docker we normally had a NFS server on a separate host(s) and then mounted it on nginx and app hosts, so that nginx instances could serve static files created by web app and app worker ...
0
votes
1answer
3k views

Express.js fails to serve all static files on heroku

there, I have a little problem with node.js and express on heroku. I have a node.js server that loads up my index.html page and other resources: process.env.PWD = process.cwd(); var express = require(...
1
vote
1answer
619 views

Fresh Ubuntu 16.04 Nginx Configuration is Serving Old Static Files

I have a very basic landing page for a domain of mine. For the last couple days I have been fighting a very peculiar issue. For example, the directory contains: vanilla> ./files/ ./index....
5
votes
3answers
18k views

Nginx does not serve large files

When trying to download a large file (not sure what size is enough, trying to download 5Gb), connection is stuck: $ wget --verbose http://example.net/large.zip -O /dev/null --2016-12-14 12:52:38-- ...
0
votes
2answers
721 views

Why does nginx raise a 404 when it tries to acess static files on a FreeBSD server?

I've got nginx 1.8.1 on a server running FreeBSD 10.2. I'm trying to serve files from a subdirectory of /usr/local/www/ (which is default on FreeBSD), but for some reason, requests to the files I'm ...
1
vote
1answer
63 views

Nginx fails to direct to https server block on same domain

I'm attempting to serve a static file using nginx over https. Setup DNS correctly points subdomain to AWS IP: subdomain1.website.com -> correct IP Working config I've found the following ...
11
votes
1answer
15k views

Reverse proxy application and its static files with Nginx

I am trying to do something that seems to me very simple but I must be stupid or miss something very obvious because I cannot figure it out. I want to access the multiple web applications running on ...
2
votes
1answer
601 views

Apache HTTPD: URL resolution for a virtual host with proxies and directory alias

Here's what my environment looks like: REST api (django), running over WSGI (mod_wsgi) on port http://server:8107/api static files for the API site (i have some admin pages), in a directory, say /opt/...
3
votes
1answer
8k views

nginx 403 when serving static files + reverse proxy

I'm trying to serve a node app through nginx, but first attempt to serve static files that may be in a /public folder. I've got that much working -- but when accessing domain.tld/ or the index of ...
0
votes
1answer
250 views

Nginx serving index.html fine, but requests for assets are bad

i have the following nginx config: server { listen 80; listen [::]:80; listen 443; listen [::]:443; server_name oreqizer.com; ...
1
vote
1answer
1k views

Nginx serving static files via Unicorn upstream (tcp)

I'm trying to create a rails app with load balancer. App is running but I don't know how to serve static files. All examples assume that nginx and unicorn running on the same machine. Here is the ...
0
votes
0answers
191 views

Nginx: Serve PHP files from defined location only

I have an AngularJS app in /home/app/front and a PHP backend in /home/app/back. Now I would like to serve static files from / and PHP from /api/v1/ I tried the following config with no success. Nginx ...
4
votes
1answer
6k views

IIS 8.5 Serve file with no extension from particular folder

I have some files that have been uploaded to a folder called /Download however the have no extension e.g. File1 I have tried adding a /Download/Web.Config file with the following specified <?xml ...
0
votes
2answers
6k views

Building a high performance file server using SSD as cache

I want to build a file server that serves ~50 TB of content to its users. To maximize the server's throughput, I'm going to utilize the follow scenario. 50 TB of HDD storage. All of the static files ...
0
votes
1answer
1k views

Staticfiles for Django cannot be located on IIS 8

I have a Django 1.7 website configured on IIS 8 platform. The staticfiles are kept in a folder generated after running collectstatic command. As mentioned in the tutorials I have made that folder a ...
0
votes
1answer
90 views

refreshing Expires daily

I'm operating a website on which the (static) content is generated once daily. This allows setting the expires setting to "modification plus 1 day". (I'm running apache with mod_expires.) Most files ...
0
votes
3answers
2k views

Why my browser wouldn't load all image resources at once?

I am trying to optimize the loading time of a webpage. Currently, the main http request can be done in under a second, however, the consenquent loading of images seems "to cascade": http://picpaste....
6
votes
1answer
5k views

How to serve specific static files with nginx?

I have queries like /api/lang?lang=en which I want to serve with nginx as /server/i18n-angular/en.json. How can I do that? I have the following directory structure: /public/ /server/i18n-angular/en....
5
votes
1answer
3k views

How to serve static files with apache on openshift official python cartridge?

I have scalable openshift online app with official python-2.7 cartridge. By default everything is served with mod_wsgi handler. How do I configure my app and/or Apache to serve some static files in my ...
0
votes
1answer
427 views

Serve static files from directory depending on http referrer inside of nginx [closed]

My server hosts images, but the content of images have to be different for the same link and have to deepens on http referrer. For example: Website 1 load image website1.jpg from www.example.com/...
2
votes
1answer
2k views

IIS returns 404 when trying to access static files on certain file types

I have a specific file type of .notebook that IIS is blocking. I tried going into request filtering and adding .notebook with allow set to true, but I still get the 404. Anything else in this folder ...
3
votes
0answers
739 views

fcgi to serve static files with nginx

Maybe I'm wrong, so before to ask my question, I'll explain a little what I'm trying to set up : I've a VPS where I want to have multiple users sites, with permission denied to all users to see the ...
0
votes
1answer
2k views

How to serve static files for multiple Django projects via nginx to same domain

I am trying to setup my nginx conf so that I can serve the relevant files for my multiple Django projects. Ultimately I want each app to be available at www.example.com/app1, www.example.com/app2 etc....
1
vote
2answers
5k views

Nginx rewrite URLs but not static files

I need to rewrite URLs like http://www.domain.com/blog/wp-content/uploads/this-is-a-static-file.jpg to http://www.domain.com/wp-content/uploads/this-is-a-static-file.jpg I am using this rule: ...
1
vote
1answer
1k views

Apache: mapping multiple directories to the same location

I would like to map multiple directories to the same location with Apache, expecting a behaviour similar to this: suppose that the /static location is to be backed by directories /srv/static1 and /srv/...
0
votes
1answer
438 views

Nginx issues with freshly overwritten images

I have this problem: I read directly (as static content) an image from https://whatever.com/static/image.png . The image is displayed properly. I overwrite this file with another one and I try ...
2
votes
1answer
4k views

Nginx redirect all request that does not match a file to a php file

I'm trying to get all request to: http://example.com/downloads/* redirect to http://example.com/downloads/index.php except if the requested file exist in /downloads/ ex: http://example.com/downloads ...
1
vote
1answer
411 views

Nginx: Disallow index.html in URL

We're generating a site consisting of only static files (using Assemble). Having the .html extension on URLs looks so nineties, so we generate every static HTML file in its own directory and call it ...
0
votes
0answers
2k views

IIS8.0 Response size limit?

I am trying to serve up some hefty (really hefty) static web pages. The one I am playing with is 20Mb, and contains image links to about 5000 images. I'm seeing some errors, where after a certain ...
0
votes
1answer
488 views

serving static assets via http is really slow compared to sshfs (apache2/nginx)

After migrating to a new VPS I had some users complaining about slow loading images on their sites. After creating some test files with dd I realized that I can download all files via sshfs with full ...
4
votes
2answers
4k views

Static file permissions with Nginx, Gunicorn and Django

I attempting to setup a Nginx server up with a Gunicorn WSGI server running Django behind.. The setup all seems to runs except i have a permissions issue. I have setup aliases to /media and a /static ...
0
votes
1answer
116 views

Apache memory usage with 404

We're facing a problem with an apache server serving static files. When there are lots of requests for a resource that doesn't exist the apache starts to grow in number of processes and memory usage ...