My website does not update when new files commited to git repository

My website name: liuzelin.netlify.app
I am occured a build problem the few days.

I use netlify to automatically deploy my github-blog repository, which worked well before.

But in recent days, when I visited my website, I found that netlify could not successfully deploy my updates to my website for several documents in the blog repository that I submitted.

You can see on my website that the latest document is the one called “GCP-Services”.
But take this document as an example: “在同一台服务器上部署多个nginx”. I uploaded this document to the blog repository on July 31, but it does not appear on my website


What I have tried:

Download my blog repository to a virtual machine with the operating system of Debian11, and start it using the command below on CLI.

hugo --gc --minify --buildFuture && npm install atomic-algolia --save-dev && npm run algolia

hugo server --bind=0.0.0.0 -D -F

I found that I can successfully access the latest content pushed to the blog repository. As shown in the figure below:

So I’m not sure why’s going wrong? Maybe there’s something I need to change in the Deploy settings?

Any help would be greatly appreciated.

Hard to say without checking your repo.

Sorry for the late reply.

Can you tell me which files need to be checked?
Or do I need to make the repository public if necessary?

Hi, I have set the repository to public.

the repo is here: my blog on github

Your site does not work for me locally:

hugo server
WARN  DEPRECATED: Kind "taxonomyterm" used in outputs configuration is deprecated, use "taxonomy" instead.
Watching for changes in /home/hrishikesh/tickets/f-123145/{assets,content,layouts,package.json,static,themes}
Watching for config changes in /home/hrishikesh/tickets/f-123145/config.yaml, /home/hrishikesh/tickets/f-123145/themes/LoveIt/config.toml
Start building sites …
hugo v0.131.0-bfbee17932ff24009008aa94cdd75c0c41f59279+extended linux/amd64 BuildDate=2024-08-02T09:03:48Z VendorInfo=snap:0.131.0

WARN  Current environment is "development". The "comment system", "CDN" and "fingerprint" will be disabled.
当前运行环境是 "development". "评论系统", "CDN" 和 "fingerprint" 不会启用.
WARN  deprecated: .Site.Author was deprecated in Hugo v0.124.0 and will be removed in a future release. Use taxonomies instead.
WARN  deprecated: .Site.IsMultiLingual was deprecated in Hugo v0.124.0 and will be removed in a future release. Use hugo.IsMultilingual instead.
ERROR render of "404" failed: "/home/hrishikesh/tickets/f-123145/themes/LoveIt/layouts/_default/baseof.html:11:12": execute of template failed: template: 404.html:11:12: executing "404.html" at <partial "head/meta.h
tml" .>: error calling partial: execute of template failed: template: _internal/opengraph.html:38:9: executing "_internal/opengraph.html" at <partial "_funcs/get-page-images" .>: error calling partial: execute of template failed: template: partials/_funcs/get-page-images.html:22:10: executing "partials/_funcs/get-page-images.html" at <$imgParams>: range can't iterate over /
ERROR render of "term" failed: "/home/hrishikesh/tickets/f-123145/themes/LoveIt/layouts/_default/baseof.html:11:12": execute of template failed: template: taxonomy/list.html:11:12: executing "taxonomy/list.html" at 
<partial "head/meta.html" .>: error calling partial: execute of template failed: template: _internal/opengraph.html:38:9: executing "_internal/opengraph.html" at <partial "_funcs/get-page-images" .>: error calling partial: execute of template failed: template: partials/_funcs/get-page-images.html:22:10: executing "partials/_funcs/get-page-images.html" at <$imgParams>: range can't iterate over /
ERROR render of "taxonomy" failed: "/home/hrishikesh/tickets/f-123145/themes/LoveIt/layouts/_default/baseof.html:11:12": execute of template failed: template: taxonomy/terms.html:11:12: executing "taxonomy/terms.htm
l" at <partial "head/meta.html" .>: error calling partial: execute of template failed: template: _internal/opengraph.html:38:9: executing "_internal/opengraph.html" at <partial "_funcs/get-page-images" .>: error calling partial: execute of template failed: template: partials/_funcs/get-page-images.html:22:10: executing "partials/_funcs/get-page-images.html" at <$imgParams>: range can't iterate over /
ERROR render of "section" failed: "/home/hrishikesh/tickets/f-123145/themes/LoveIt/layouts/_default/baseof.html:11:12": execute of template failed: template: _default/section.html:11:12: executing "_default/section.
html" at <partial "head/meta.html" .>: error calling partial: execute of template failed: template: _internal/opengraph.html:38:9: executing "_internal/opengraph.html" at <partial "_funcs/get-page-images" .>: error calling partial: execute of template failed: template: partials/_funcs/get-page-images.html:22:10: executing "partials/_funcs/get-page-images.html" at <$imgParams>: range can't iterate over /
Built in 257 ms
Error: error building site: render: failed to render pages: render of "home" failed: "/home/hrishikesh/tickets/f-123145/themes/LoveIt/layouts/_default/baseof.html:11:12": execute of template failed: template: index.
html:11:12: executing "index.html" at <partial "head/meta.html" .>: error calling partial: execute of template failed: template: _internal/opengraph.html:38:9: executing "_internal/opengraph.html" at <partial "_func
s/get-page-images" .>: error calling partial: execute of template failed: template: partials/_funcs/get-page-images.html:22:10: executing "partials/_funcs/get-page-images.html" at <$imgParams>: range can't iterate over /

How do I get it to work?

Is your operating system centos?

I tried to start the site on a Centos7 system and it did give the same error .

But I ran it on a Debian Or Ubuntu system and it started successfully. As shown in the logs below

root@instance-20240804-030006-l01:~/l01# git clone https://github.com/liuzel01/blog.git
Cloning into 'blog'...
remote: Enumerating objects: 5686, done.
remote: Counting objects: 100% (1809/1809), done.
remote: Compressing objects: 100% (794/794), done.
remote: Total 5686 (delta 842), reused 1735 (delta 774), pack-reused 3877
Receiving objects: 100% (5686/5686), 46.83 MiB | 16.46 MiB/s, done.
Resolving deltas: 100% (1379/1379), done.
root@instance-20240804-030006-l01:~/l01# cd blog/
root@instance-20240804-030006-l01:~/l01/blog# ls
R          assets      config-bak.yaml  content    layouts       package-lock.json  public           resources  themes
README.md  blog.Rproj  config.yaml      index.Rmd  netlify.toml  package.json       push_algolia.js  static
root@instance-20240804-030006-l01:~/l01/blog# hugo version 
Hugo Static Site Generator v0.68.3/extended linux/amd64 BuildDate: 2020-03-25T06:15:45Z
root@instance-20240804-030006-l01:~/l01/blog# hugo server 
Building sites … WARN 2024/08/04 03:05:15 

Current environment is "development". The "comment system", "CDN" and "fingerprint" will be disabled.
当前运行环境是 "development". "评论系统", "CDN" 和 "fingerprint" 不会启用.

WARN 2024/08/04 03:05:15 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2024/08/04 03:05:16 found no layout file for "markdown" for kind "page": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.

                   | EN | ZH-CN  
-------------------+----+--------
  Pages            | 12 |   115  
  Paginator pages  |  0 |     7  
  Non-page files   |  0 |     0  
  Static files     | 86 |    86  
  Processed images |  0 |     0  
  Aliases          |  2 |    31  
  Sitemaps         |  2 |     1  
  Cleaned          |  0 |     0  

Built in 1267 ms
Watching for changes in /root/l01/blog/{assets,content,layouts,static,themes}
Watching for config changes in /root/l01/blog/config.yaml, /root/l01/blog/themes/LoveIt/config.toml
Environment: "development"
Serving pages from memory
Running in Fast Render Mode. For full rebuilds on change: hugo server --disableFastRender
Web Server is available at http://localhost:1313/ (bind address 127.0.0.1)
Press Ctrl+C to stop
^Croot@instance-20240804-030006-l01:~/l01/blog# cat /etc/os-release 
NAME="Ubuntu"
VERSION="20.04.6 LTS (Focal Fossa)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 20.04.6 LTS"
VERSION_ID="20.04"
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
VERSION_CODENAME=focal
UBUNTU_CODENAME=focal

MeanWhile when I deployed on Netlify, the Build image selection I chose was Ubuntu, as shown in the figure below

So I doubt is this indeed the cause of the problem?

I have solved the problem.

The problem is that my document has the configuration of draft: yes, which makes it impossible to publish successfully.


The following are the specific steps to solve it.

By deleting the document that had the problem before and regenerating a new document using Rstudio.(I went through the process again.)

I found that the regenerated document will have this configuration: draft:yes

Through querying the hugo deployment-related documents: blogdown deployment post does not appear on the website,

I found that before pushing to my repository, I could check the site using the command: blogdown::check_site() , And the inspection results will be output to the console , and there will be some simple suggestions in the TODO items

for example, this is my result after running the check command:

> blogdown::check_site()
― Running a series of automated checks for your blogdown website project...
--------------------------------------------------------------------------------------------------
○ A successful check looks like this.
● [TODO] A check that needs your attention looks like this.
| Let's check out your blogdown site!
--------------------------------------------------------------------------------------------------
― Checking config.yaml
| Checking "baseURL" setting for Hugo...
○ Found baseURL = "https://liuzelin.netlify.app/"; nothing to do here!
| Checking "ignoreFiles" setting for Hugo...
● [TODO] Set "ignoreFiles" to ["\\.Rmd$", "\\.Rmarkdown$", "_cache$"]
| Checking setting for Hugo's Markdown renderer...
○ All set! Found the "unsafe" setting for goldmark.
― Check complete: config.yaml

― Checking index.Rmd in the root directory
○ index.Rmd is correctly configured.
― Check complete: index.Rmd

― Checking .gitignore
| Checking for items to remove...
○ Nothing to see here - found no items to remove.
| Checking for items to change...
○ Nothing to see here - found no items to change.
| Checking for items you can safely ignore...
○ Found! You have safely ignored: .DS_Store
● [TODO] You can safely add to .gitignore: Thumbs.db, .hugo_build.lock
| Checking for items to ignore if you build the site on Netlify...
● [TODO] When Netlify builds your site, you can safely add to .gitignore: /public/, /resources/
| Checking for files required by blogdown but not committed...
○ Great! Did not find such files.
― Check complete: .gitignore

― Checking Hugo
| Checking Hugo version...
○ Found Hugo. You are using Hugo 0.100.2.
| Checking .Rprofile for Hugo version used by blogdown...
○ blogdown is using Hugo 0.100.2 to build site locally.
― Check complete: Hugo

― Checking netlify.toml...
○ Found HUGO_VERSION = 0.100.2 in [build] context of netlify.toml.
| Checking that remote & local Hugo versions match...
○ It's a match! Local and remote Hugo versions are identical (0.100.2).
| Checking that Netlify & local Hugo publish directories match...
○ Good to go - blogdown and Netlify are using the same publish directory: public
― Check complete: netlify.toml

― Checking content files
| Checking for validity of YAML metadata in posts...
○ All YAML metadata appears to be syntactically valid.
| Checking for previewed content that will not be published...
○ Found 0 files with future publish dates.
● [TODO] Found 1 file marked as drafts. To un-draft, run the command:

  blogdown::edit_draft(c(
  "content/posts/2024-06-16-supervisor/index.zh-cn.md"
  ))

  and change a file's YAML from 'draft: true' to 'draft: false' or delete it
| Checking your R Markdown content...
○ All R Markdown files have been knitted.
○ All R Markdown output files are up to date with their source files.
| Checking for .html/.md files to clean up...
○ Found 0 duplicate .html output files.
○ Found 0 incompatible .html files to clean up.
| Checking for the unnecessary 'content/' directory in theme...
○ Great! Your theme does not contain the content/ directory.
― Check complete: Content

And i run the command that suggested above:

blogdown::edit_draft(c(
  "content/posts/2024-06-16-supervisor/index.zh-cn.md"
  ))

delete the draft: yes , and push to my repo, then deployed it successfully.


However, the draft parameter does not exist in the previously published documents.

The reason for this problem is that the recently created documents chose to use default.md

  • this is the reason:

By checking default.md, I found that there is a default configuration: draft: true

After I commented out the draft: true configuration, I created a new document and published it again, and this problem will not occur.