Hi everyone,
I’m experiencing an issue with the build time for my site afnizarnur.netlify.app
on Netlify. The deploy build is taking more than 15 minutes to complete. Before this, I encountered numerous deploy failures with every attempt I made to fix them. Eventually, I added the NPM_FLAGS
environment variable with the value --force
, which allowed the deployment to succeed. However, the build time remains very long.
My site is built using Eleventy, and I suspect the issue might be related to the Netlify CLI. Since my site uses the Netlify CLI, I tried downgrading the version in package.json
as well as the Node.js version in the Netlify settings, but these changes didn’t improve the situation. I also attempted to move the Netlify CLI to devDependencies, but that didn’t help either.
Here the link to latest Deploy Log Succeeded with NPM_FLAGS
Below is my package.json
, which might provide some insights:
package.json
{
“name”: “afnizarnur”,
“version”: “1.0.0”,
“description”: “Afnizar Nur Ghifari”,
“browserslist”: [
“defaults”
],
“scripts”: {
“start”: “npm run dev”,
“dev”: “run-s clean eleventy:dev --print-label”,
“build”: “run-s clean eleventy:prod --print-label”,
“eleventy:dev”: “cross-env ELEVENTY_ENV=development eleventy --serve”,
“eleventy:prod”: “cross-env ELEVENTY_ENV=production eleventy”,
“clean”: “del-cli dist”,
“test”: “echo "Error: no test specified" && exit 1”
},
“repository”: {
“type”: “git”,
“url”: “GitHub - afnizarnur/afnizarnur.com: My personal site handcrafted with Eleventy and hosted in Netlify.”
},
“author”: “Afnizar Nur Ghifari”,
“license”: “MIT”,
“dependencies”: {
“@11ty/eleventy-img”: “^1.0.0”,
“@11ty/eleventy-navigation”: “^0.3.2”,
“@11ty/eleventy-plugin-rss”: “^1.1.2”,
“@babel/plugin-transform-runtime”: “^7.16.4”,
“axios”: “^1.4.0”,
“babel-loader”: “^8.2.3”,
“cheerio”: “^1.0.0-rc.12”,
“clean-css”: “^5.2.2”,
“critical”: “^5.1.1”,
“cssesc”: “^3.0.0”,
“del-cli”: “^4.0.1”,
“dotenv”: “^16.1.4”,
“eleventy-plugin-embed-everything”: “^1.18.2”,
“eleventy-plugin-svg-sprite”: “^1.2.2”,
“focus-trap”: “^6.9.4”,
“focus-visible”: “^5.2.0”,
“gsap”: “^3.9.1”,
“html-minifier”: “^4.0.0”,
“imagesloaded”: “^4.1.4”,
“lodash”: “^4.17.21”,
“luxon”: “^2.1.1”,
“markdown-it”: “^12.2.0”,
“markdown-it-footnote”: “^4.0.0”,
“memfs”: “^3.4.0”,
“netlify-cli”: “^17.23.1”,
“node-fetch”: “^3.3.1”,
“node-sass”: “npm:sass@^1.67.0”,
“npm-run-all”: “^4.1.5”,
“split-type”: “^0.3.3”,
“splitting”: “^1.0.6”,
“svg-sprite”: “^1.2.19”,
“webpack”: “^5.64.4”
},
“devDependencies”: {
“@11ty/eleventy”: “^2.0.1”,
“@11ty/eleventy-plugin-syntaxhighlight”: “^5.0.0”,
“@babel/core”: “^7.22.5”,
“@babel/plugin-transform-modules-commonjs”: “^7.22.5”,
“@babel/preset-env”: “^7.22.5”,
“cross-env”: “^7.0.3”,
“dotenv-webpack”: “^8.0.1”,
“eleventy-plugin-page-assets”: “github:maxboeck/eleventy-plugin-page-assets”,
“plur”: “^5.1.0”,
“prettier”: “^2.8.8”
}
}
I would greatly appreciate any suggestions or solutions to improve the build time.
Thank you for your help!