Bonteq
January 25, 2021, 7:08pm
1
Site Name : https://hithr-static.netlify.app/
The live site’s Dynamic URLs aren’t loading as I expect, but work fine when I run the code through ntl dev --live
.
What might be different between the two so I can hopefully debug the issues I’m running into.
The basis of dev --live
is that you can quickly share a site with other devices/people without deploying. To my knowledge, redirects do not work in --live
mode which I think is the reason you are experiencing this issue.
See this post here
Yup, as Luke said, we won’t be able to do that natively here - redirects are static at deploy time, and I don’t think you have a full list of hostnames. If I’m wrong and you do, feel free to make one redirect per name, like this:
https://luke.fbx.im/whatever https://app-luke.fbx.biz/path 301!
Otherwise you’d best be served by a function that can parse the original host header, or some other dynamic solution.
1 Like
Bonteq
January 26, 2021, 6:56pm
3
Thank you for the reply.
Could you go more in-depth with redirects not working in --live mode ? I still can’t wrap my head around how it’s working in --live mode and not through the proper deployment method.
That is strange if it isn’t working in your deployed site… do you mind linking to your deploy logs, so I could check them over?
Kyle.
Bonteq
January 26, 2021, 8:13pm
5
It’s deploying just fine, but here’s the log.
11:04:20 AM: Build ready to start
11:04:21 AM: build-image version: d84c79427e8f83c1ba17bcdd7b3fe38059376b68
11:04:21 AM: build-image tag: v3.6.1
11:04:21 AM: buildbot version: e9929dc9a5baca8ca6218c9fd265aedbdf1a7681
11:04:21 AM: Fetching cached dependencies
11:04:22 AM: Starting to download cache of 326.3MB
11:04:25 AM: Finished downloading cache in 3.155096807s
11:04:25 AM: Starting to extract cache
11:04:38 AM: Finished extracting cache in 13.668966706s
11:04:38 AM: Finished fetching cache in 16.895378982s
11:04:38 AM: Starting to prepare the repo for build
11:04:39 AM: Preparing Git Reference refs/heads/main
11:04:41 AM: Starting build script
11:04:41 AM: Installing dependencies
11:04:41 AM: Python version set to 2.7
11:04:42 AM: Started restoring cached node version
11:04:45 AM: Finished restoring cached node version
11:04:45 AM: v12.18.0 is already installed.
11:04:46 AM: Now using node v12.18.0 (npm v6.14.4)
11:04:46 AM: Started restoring cached build plugins
11:04:46 AM: Finished restoring cached build plugins
11:04:46 AM: Attempting ruby version 2.7.1, read from environment
11:04:48 AM: Using ruby version 2.7.1
11:04:48 AM: Using PHP version 5.6
11:04:48 AM: Started restoring cached node modules
11:04:48 AM: Finished restoring cached node modules
11:04:48 AM: Started restoring cached yarn cache
11:04:48 AM: Finished restoring cached yarn cache
11:04:49 AM: Installing NPM modules using Yarn version 1.22.4
11:04:50 AM: yarn install v1.22.4
11:04:50 AM: [1/4] Resolving packages…
11:04:51 AM: success Already up-to-date.
11:04:51 AM: Done in 1.35s.
11:04:51 AM: NPM modules installed using Yarn
11:04:51 AM: Started restoring cached go cache
11:04:51 AM: Finished restoring cached go cache
11:04:51 AM: go version go1.14.4 linux/amd64
11:04:51 AM: go version go1.14.4 linux/amd64
11:04:51 AM: Installing missing commands
11:04:51 AM: Verify run directory
11:04:53 AM:
11:04:53 AM: ────────────────────────────────────────────────────────────────
11:04:53 AM: Netlify Build
11:04:53 AM: ────────────────────────────────────────────────────────────────
11:04:53 AM:
11:04:53 AM: ❯ Version
11:04:53 AM: @netlify /build 8.2.0
11:04:53 AM:
11:04:53 AM: ❯ Flags
11:04:53 AM: deployId: 600f3253f045a80007f366f9
11:04:53 AM: mode: buildbot
11:04:53 AM:
11:04:53 AM: ❯ Current directory
11:04:53 AM: /opt/build/repo
11:04:53 AM:
11:04:53 AM: ❯ Config file
11:04:53 AM: No config file was defined: using default values.
11:04:53 AM:
11:04:53 AM: ❯ Context
11:04:53 AM: production
11:04:53 AM:
11:04:53 AM: ────────────────────────────────────────────────────────────────
11:04:53 AM: 1. Build command from Netlify app
11:04:53 AM: ────────────────────────────────────────────────────────────────
11:04:53 AM:
11:04:53 AM: yarn generate
11:04:54 AM: yarn run v1.22.4
11:04:54 AM: nuxt generate
11:05:32 AM: Done in 38.62s.
11:05:32 AM:
11:05:32 AM: (build.command completed in 38.9s)
11:05:32 AM:
11:05:32 AM: ────────────────────────────────────────────────────────────────
11:05:32 AM: 2. Deploy site
11:05:32 AM: ────────────────────────────────────────────────────────────────
11:05:32 AM:
11:05:32 AM: Starting to deploy site from ‘dist’
11:05:32 AM: Creating deploy tree
11:05:32 AM: Creating deploy upload records
11:05:32 AM: 23 new files to upload
11:05:32 AM: 0 new functions to upload
11:05:33 AM: Site deploy was successfully initiated
11:05:33 AM:
11:05:33 AM: (Deploy site completed in 840ms)
11:05:33 AM:
11:05:33 AM: ────────────────────────────────────────────────────────────────
11:05:33 AM: Netlify Build Complete
11:05:33 AM: ────────────────────────────────────────────────────────────────
11:05:33 AM:
11:05:33 AM: (Netlify Build completed in 39.8s)
11:05:33 AM: Caching artifacts
11:05:33 AM: Started saving node modules
11:05:33 AM: Finished saving node modules
11:05:33 AM: Started saving build plugins
11:05:33 AM: Finished saving build plugins
11:05:33 AM: Started saving yarn cache
11:05:33 AM: Finished saving yarn cache
11:05:33 AM: Starting post processing
11:05:33 AM: Started saving pip cache
11:05:33 AM: Post processing - HTML
11:05:33 AM: Finished saving pip cache
11:05:33 AM: Started saving emacs cask dependencies
11:05:33 AM: Finished saving emacs cask dependencies
11:05:33 AM: Started saving maven dependencies
11:05:33 AM: Finished saving maven dependencies
11:05:33 AM: Started saving boot dependencies
11:05:33 AM: Finished saving boot dependencies
11:05:33 AM: Started saving rust rustup cache
11:05:33 AM: Finished saving rust rustup cache
11:05:33 AM: Started saving go dependencies
11:05:33 AM: Finished saving go dependencies
11:05:33 AM: Build script success
11:05:34 AM: Post processing - header rules
11:05:34 AM: Post processing - redirect rules
11:05:34 AM: Post processing done
11:05:34 AM: Site is live
11:06:30 AM: Finished processing build request in 2m8.767666891s
If the issue only occurs after deploy with Netlify then it is almost certainly an issue with deploying.
Can you link to the actual deploy UI?
I would recommend you read this aswell.
Last Reviewed By Netlify Support Staff: December 2022
Are you struggling to understand why your project runs locally but errors out with missing files or logs that point toward issues with case when you try and build on Netlify? You are not alone. Often, case (as in: UPPERCASE or lowercase letters in filenames or paths) can cause problems. Here is a guide to understanding how case sensitivity issues present themselves, why they arise, and how you can fix them!
1. Errors you might see
Case sens…
luke
January 27, 2021, 8:38am
7
Hi, @Bonteq . Is the Netlify team you use the same team under the same email address as the email address used for this forum login? If so, I’m seeing the following in your deploy details page for the only site updated this month:
No redirect rules processed
This deploy did not include any redirect rules. Learn more about redirects .
So, your redirects are not being processed for some reason. Where are your redirects? Are they in netlify.toml
or in _redirects
(or both which is also works)?
If you are putting the redirects in either file, that file must exist in the publish directory (dist) at the end of the deploy. That doesn’t appear to be happening for this site.
Would you please confirm at least one of those files is being copied to the publish directory before the deploy ends?
If there are any questions about this, please let us know.
1 Like