I have a Gatsby application that is partially static and has some routes that must be handled by Nginx instead of Gatsby service worker, but still didn't find a way to remove a specific path from Gatsby cache. Consider the following pages:
/home alright, handled by Gatsby
/contact alright, handled by Gatsby
/bloghandled by Nginx
My home page has a link for /blog, that stands under the same domain, but Nginx is responsible for providing its content, so I don't have a Gatsby page for it.
The problem arises because sometimes when clicking in the Blog link, then the service worker will send me to a 404 page, but some other times it will just work fine.
I've already tried to add the blog/path to the navigateFallbackWhitelist of gatsby-plugin-offline, but still had no success.
Is there a way to force Gatsby to permanently ignore and not cache a specific path?
You can setup Gatsby separately for home and contact.
Will that be alright?
check this
Related
When I place a Laravel project into Apache's document root, say /var/www/html, it works when I point a browser at it.
However if I put it under a directory under Apache's document root, for example /var/www/html/myProject, it doesn't work when I point a browser at it.
Is there anyway I can change this behavior?
Thank you very much.
Edit:
When I put the Laravel project off a sub-directory off /var/www/html, Laravel complained that it could not write to the file laravel.log. After checking and changing the group ownership of the sub-directory, the index page came up normally.
However, the background image was missing, even after I changed the URI in the CSS stylesheet.
Furthermore, when I clicked on any link from the index page, I got a 404 Not Found Error. This is an Apache 404 and not a Laravel 404, which is styled differently.
OTOH, if I run the PHP server off this sub-directory and point my browser at localhost:8000, the links serve up pages correctly.
Thank you for your help.
I have this problem since several days.
I'm developing a Vuejs/laravel app, using Sanctum as an authenticator. where laravel mainly have the api gestion role, and I've started to deploying it. On Local, everything looks fine, api and auth are working.
On deploy, since my app is binded to be in a subdomain (laravelapp.maindomain with folder path of domain/laravelapp), when i try to access any page (vue-router) instead of domain/laravelapp/login i get domain/login, even if the page itself is looking fine.
If i try to reload the redirected page (domain/page) i have a 404. Also, since every API is pointing to domain/api/link instead of domain/laravelapp/api/link, everything is broken starting with auth.
I've tried modifying .env file, RouteServiceProvider, .htaccess(but i have no knowledge about that).
I also tried to set the subdomain Document Root to domain/laravelapp (it's the first thing i've done), but not only it dosn't work, if I try to print on screen subdomain's root, it returns domain. It's becoming a real issue right now, thank you for any help.
EDIT: I've discovered something. in the main domain there is a Joomla application. The api route contains the Joomla redirect (like, there is a plugin oh the site that changes language automatically, appending /en /it /de given the chosen language). So, in my case, the api is domain/index.php/en/subdomain. I tried again being more specific with document root, with no results, and playing around with .htaccess, but with no success.
According to the docs we are able to put a 503.html document inside the root of our Laravel project.
You may customize the maintenance mode splash screen for your application by placing a 503.html file in your application's root directory.
I would however love to be able to put one or more assets on this page (for example our Logo) to make this page better more personal. Laravel Vapor automatically uploads your static assets to cloudfront, which is not a problem if you're using the asset() helper. However, are there any solutions already being made? I can't find any.
Is there anyone who has created a solution to make this happen?
With Vapor every time you deploy all the assets get a new cloudfront url. This is mostly fine for js and css which we change often. Images, logos etc do not change much.
Better to make another bucket on aws and hard code the path the image file in your 503. Doesn't need to be deployed every time. Your users browsers can cache it for as long as you set it in the bucket.
I'd like Vapor to only change asset urls if the files have changed but so far that is not the case.
A policy change forced me to have to change our domain name for ckan, someone had a bright idea to use the domain name for a different landing site and then redirect off to the ckan sever from there.
I have updated data records in the database to reflect the amended url in the resource tables. (resource, resource_revision , resource_view)
it was https://www.blah.....
the new url is http://hub.blah......
Some resources re now downloadable at the new domain, the pages show the correct domain name and links and buttons work correctly.
Some resources on the page show the old url and link to the old url where there is no document accessible. The document is present at the new url. I can see the records for the resource in the database reflect the new url in the database.
The previewers of the dataset are all showing the data as I would expect on those that have the correct url but not working on the pages where the url is incorrect on the screen.
New uploads are showing correctly on pages and correctly in the database.
I have restarted solr, nginx, apache and a reboot of the web server and the database server.
It looks like the pages that are out of date are cached but I cant find a way to refresh them and force the several hundred pages to re-query the database to get the correct information.
I see the same issue when the page is accessed externally and internally to my corporate network.
Anyone any more ideas?
My best guess would be that the URLs are wrong in the solr index, try to rebuild the whole solr index with this paster command (run in virtualenv):
paster --plugin=ckan search-index rebuild -c production.ini
Adapt to your config file accordingly.
after a bit of a headache and a good nights sleep I added
the following to production.ini
ckan.datastore.sqlalchemy.pool_size=10
ckan.datastore.sqlalchemy.max_overflow=20
this worked for me
I have a magento install on a staging environment, everything is working except the catalog backend page and the frontend layered navigation. Look at the image below. There is a backend within the backend. When visiting the page it refreshes to infinity. See this identical problem
My first guess is there is a bug in the template file but an identical template file on my local machine does not cause any issues. Additionally the database between my local and staging site are identical minus the core_config_url. The only difference is local I am running Apache and on staging I am running nginx.
The second issue which I imagine is related is that the filters on the frontend catalog page dont work. They are visible but clicking on them reloads the page without changing the products.
Any help would be appreciated. Thanks
UPDATE: After switching from NGINX to Apache the issue disappeared. I still would like to figure out what is causing the problem
I take for granted that you had already tried different browsers/clearing your browser cache and Magento cache (empty the cache directory), etc.
Are you sure you put the correct value in the cookie_domain setting? Many users that had your same problem seem to have setted up an incorrect value in that setting.
Take a look here and let me know.
I have found that usually this is caused by a server-side error on the ajax request. If there is any kind of error response returned, it will just continue to spin. Either check your Chrome console for a 500 response, or look in your server's error logs.