Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
888 views
in Technique[技术] by (71.8m points)

deployment - Problem deploying to Netlify a plain JS app

I have never had any problem deploying to Netlify but now I have been struggling for hours! I always build with CRA, but now it is a vanilla JS app that I have built using yarn to add a couple of packages. I don’t see anything wrong in my package.json, do you?

{
 
  "devDependencies": {
    "cypress": "^6.2.0"
  },
  "dependencies": {
    "emmet": "^2.3.0",
    "serve": "^11.3.2",
    "start-server-and-test": "^1.11.7"
  },
  "scripts": {
    "start": "PORT=5000 react-scripts start",
    "start:silent": "BROWSER=none PORT=5000 react-scripts start",
    "build": "CI= yarn run build",
    "test": "react-scripts test",
    "eject": "react-scripts eject",
    "cy:open": "cypress open",
    "cypress": "start-server-and-test start:silent http://localhost:5000/ cy:open",
    "serve": "serve ./"
  }
}

I will reproduce the logs from Netlify because I don’t really understand them.

1:14:51 AM: Build ready to start
1:14:53 AM: build-image version: 53b83b6bede2920f236b25b6f5a95334320dc849
1:14:53 AM: build-image tag: v3.6.0
1:14:53 AM: buildbot version: e26592b49d9d56b21349effe1b8fab4d50845f11
1:14:53 AM: Fetching cached dependencies
1:14:53 AM: Failed to fetch cache, continuing with build
1:14:53 AM: Starting to prepare the repo for build
1:14:53 AM: No cached dependencies found. Cloning fresh repo
1:14:53 AM: git clone https://github.com/myname/Vanilla
1:14:54 AM: Preparing Git Reference refs/heads/main
1:14:56 AM: Different publish path detected, going to use the one specified in the Netlify configuration file: 'dist' versus 'dist/' in the Netlify UI
1:14:56 AM: Starting build script
1:14:56 AM: Installing dependencies
1:14:56 AM: Python version set to 2.7
1:14:57 AM: v12.18.0 is already installed.
1:14:58 AM: Now using node v12.18.0 (npm v6.14.4)
1:14:58 AM: Started restoring cached build plugins
1:14:58 AM: Finished restoring cached build plugins
1:14:58 AM: Attempting ruby version 2.7.1, read from environment
1:14:59 AM: Using ruby version 2.7.1
1:15:00 AM: Using PHP version 5.6
1:15:00 AM: Started restoring cached node modules
1:15:00 AM: Finished restoring cached node modules
1:15:00 AM: Started restoring cached yarn cache
1:15:00 AM: Finished restoring cached yarn cache
1:15:00 AM: Installing yarn at version 1.22.4
1:15:00 AM: Installing Yarn!
1:15:00 AM: > Downloading tarball...
1:15:00 AM: [1/2]: https://yarnpkg.com/downloads/1.22.4/yarn-v1.22.4.tar.gz --> /tmp/yarn.tar.gz.9IdRgT769z
1:15:00 AM:   % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
1:15:00 AM:                                  Dload  Upload   Total   Spent    Left  Speed
1:15:00 AM:   0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
1:15:00 AM: 100    80  100    80    0     0    242      0 --:--:-- --:--:-- --:--:--   243
1:15:01 AM:   0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
1:15:01 AM: 100    93  100    93    0     0    122      0 --:--:-- --:--:-- --:--:--   484
1:15:01 AM: 100   643  100   643    0     0    530      0  0:00:01  0:00:01 --:--:--   530
1:15:01 AM:   9 1215k    9  118k    0     0  77966      0  0:00:15  0:00:01  0:00:14 77966
1:15:01 AM: 100 1215k  100 1215k    0     0   727k      0  0:00:01  0:00:01 --:--:-- 9794k
1:15:01 AM: [2/2]: https://yarnpkg.com/downloads/1.22.4/yarn-v1.22.4.tar.gz.asc --> /tmp/yarn.tar.gz.9IdRgT769z.asc
1:15:01 AM: 100    84  100    84    0     0   3049      0 --:--:-- --:--:-- --:--:--  3049
1:15:02 AM: 100    97  100    97    0     0   1242      0 --:--:-- --:--:-- --:--:--  1242
1:15:02 AM: 100   647  100   647    0     0   2952      0 --:--:-- --:--:-- --:--:--  2952
1:15:02 AM: 100  1028  100  1028    0     0   3923      0 --:--:-- --:--:-- --:--:--  3923
1:15:02 AM: > Verifying integrity...
1:15:02 AM: gpg: Signature made Mon 09 Mar 2020 03:52:13 PM UTC using RSA key ID 69475BAA

1:15:02 AM: gpg: Good signature from "Yarn Packaging <[email protected]>"
1:15:02 AM: gpg: WARNING: This key is not certified with a trusted signature!
1:15:02 AM: gpg:          There is no indication that the signature belongs to the owner.
1:15:02 AM: Primary key fingerprint: 72EC F46A 56B4 AD39 C907  BBB7 1646 B01B 86E5 0310
1:15:02 AM:      Subkey fingerprint: 6D98 490C 6F1A CDDD 448E  4595 4F77 6793 6947 5BAA
1:15:02 AM: > GPG signature looks good
1:15:02 AM: > Extracting to ~/.yarn...
1:15:02 AM: > Adding to $PATH...
1:15:02 AM: > Successfully installed Yarn 1.22.4! Please open another terminal where the `yarn` command will now be available.
1:15:03 AM: Installing NPM modules using Yarn version 1.22.4
1:15:03 AM: yarn install v1.22.4
1:15:03 AM: warning package.json: No license field
1:15:03 AM: warning No license field
1:15:03 AM: [1/4] Resolving packages...
1:15:03 AM: [2/4] Fetching packages...
1:15:11 AM: [3/4] Linking dependencies...
1:15:13 AM: [4/4] Building fresh packages...
1:15:30 AM: Done in 27.27s.
1:15:31 AM: NPM modules installed using Yarn
1:15:31 AM: warning package.json: No license field
1:15:31 AM: Started restoring cached go cache
1:15:31 AM: Finished restoring cached go cache
1:15:31 AM: go version go1.14.4 linux/amd64
1:15:31 AM: go version go1.14.4 linux/amd64
1:15:31 AM: Installing missing commands
1:15:31 AM: Verify run directory
1:15:32 AM: ?
1:15:32 AM: ────────────────────────────────────────────────────────────────
1:15:32 AM:   Netlify Build                                                 
1:15:32 AM: ────────────────────────────────────────────────────────────────
1:15:32 AM: ?
1:15:32 AM: ? Version
1:15:32 AM:   @netlify/build 8.0.1
1:15:32 AM: ?
1:15:32 AM: ? Flags
1:15:32 AM:   deployId: 5ff92dbbeb91b7410728e9c4
1:15:32 AM:   mode: buildbot
1:15:32 AM: ?
1:15:32 AM: ? Current directory
1:15:32 AM:   /opt/build/repo
1:15:32 AM: ?
1:15:32 AM: ? Config file
1:15:32 AM:   No config file was defined: using default values.
1:15:32 AM: ?
1:15:32 AM: ? Context
1:15:32 AM:   production
1:15:32 AM: ?
1:15:32 AM: ────────────────────────────────────────────────────────────────
1:15:32 AM:   1. Build command from Netlify app                             
1:15:32 AM: ────────────────────────────────────────────────────────────────
1:15:32 AM: ?
1:15:32 AM: $ CI= yarn run build
1:15:33 AM: yarn run v1.22.4
1:15:33 AM: warning package.json: No license field
1:15:33 AM: $ CI= yarn run build
1:15:33 AM: warning package.json: No license field
1:15:33 AM: $ CI= yarn run build
1:15:33 AM: warning package.json: No license field
1:15:33 AM: $ CI= yarn run build
1:15:33 AM: warning package.json: No license field
1:15:49 AM: $ CI= yarn run build
1:15:49 AM: warning package.json: No license field
1:15:49 AM: $ CI= yarn run build
1:15:49 AM: warning package.json: No license field
1:15:49 AM: $ CI= yarn run build
1:15:49 AM: warning package.json: No license field
1:15:50 AM: $ CI= yarn run build
1:15:50 AM: warning package.json: No license field
1:15:50 AM: $ CI= yarn run build
1:15:50 AM: warning package.json: No license field
1:15:50 AM: $ CI= yarn run build
1:15:50 AM: warning package.json: No license field
1:15:50 AM: $ CI= yarn run build
1:15:50 AM: warning package.json: No license field
1:15:50 AM: $ CI= yarn run build
1:15:51 AM: warning package.json: No license field
1:15:51 AM: $ CI= yarn run build
1:15:51 AM: warning package.json: No license field
1:15:51 AM: $ CI= yarn run build
1:15:51 AM: warning package.json: No license field
1:15:51 AM: $ CI= yarn run build
1:15:51 AM: warning package.json: No license field
1:15:51 AM: $ CI= yarn run build
1:15:52 AM: warning package.json: No license field
1:15:52 AM: $ CI= yarn run build
1:15:52 AM: warning package.json: No license field
1:15:52 AM: $ CI= yarn run build
1:15:52 AM: warning package.json: No license field
1:15:52 AM: $ CI= yarn run build
1:15:52 AM: warning package.json: No license field
1:15:52 AM: $ CI= yarn run build
1:15:53 AM: warning package.json: No license field
1:15:53 AM: $ CI= yarn run build
1:15:53 AM: warning package.json: No license field
1:15:53 AM: $ CI= yarn run build
1:15:53 AM: warning package.json: No license field
1:15:53 AM: $ CI= yarn run build
1:15:53 AM: warning package.json: No license field
1:15:53 AM: $ CI= yarn run build
1:15:54 AM: warning package.json: No license field
1:15:54 AM: $ CI= yarn run build
1:15:54 AM: warning package.json: No license field
1:15:54 AM: $ CI= yarn run build
1:15:54 AM: warning package.json: No license field
1:15:54 AM: $ CI= yarn run build
1:15:54 AM: warning package.json: No license field
1:15:54 AM: $ CI= yarn run build
1:15:54 AM: warning package.json: No license field
1:15:54 AM: $ CI= yarn run build
1:15:55 AM: warning package.json: No license field
1:15:55 AM: $ CI= yarn run build
1:15:55 AM: warning package.json: No license field
1:15:55 AM: $ CI= yarn run build
1:15:55 AM: warning package.json: No license field
1:15:55 AM: $ CI= yarn run build
1:15:55 AM: warning package.json: No license field
1:15:55 AM: $ CI= yarn run build
1:15:56 AM: warning package.json: No license field
1:15:56 AM: $ CI= yarn run build
1:15:56 AM: warning package.json: No license field
1:15:56 AM: $ CI= yarn run build
1:15:56 AM: warning package.json: No license field
1:15:56 AM: $ CI= yarn run build
1:15:56 AM: warning package.json: No license field
1:15:56 AM: $ CI= yarn run build
1:15:56 AM: warning package.json: No license field
1:15:56 AM: $ CI= yarn run build
1:15:57 AM: warning package.json: No license field
1:15:57 AM: $ CI= yarn run build
1:15:57 AM: warning package.json: No license field
1:15:57 AM: $ CI= yarn run build
1:15:57 AM: warning package.json: No license field
1:15:57 AM: $ CI= yarn run build
1:15:57 AM: warning package.json: No license field
1:15:57 AM: $ CI= yarn run build
1:15:58 AM: warning package.json: No license field
1:15:58 AM: $ CI= yarn run build
1:15:58 AM: warning package.json: No license field
1:15:58 AM: $ CI= yarn run build
1:15:58 AM: warning package.json: No license field
1:15:58 AM: $ CI= yarn run build
1:15:58 AM: warning package.json: No license field
1:15:58 AM: $ CI= yarn run build
1:15:59 AM: warning package.json: No license field
1:15:59 AM: $ CI= yarn run build
1:15:59 AM: warning package.json: No license field
1:15:59 AM: $ CI= yarn run build
1:15:59 AM: warning package.json: No license field
1:15:59 AM: $ CI= yarn run build
1:15:59 AM: warning package.json: No license field
1:15:59 AM: $ CI= yarn run build
1:16:00 AM: warning package.json: No license field
1:16:00 AM: $ CI= yarn run build
1:16:00 AM: warning package.json: No license field
1:16:00 AM: $ CI= yarn run build
1:16:00 AM: warning package.json: No license field
1:16:00 AM: $ CI= yarn run build
1:16:01 AM: warning package.json: No license field
1:16:01 AM: $ CI= yarn run build
1:16:01 AM: warning package.json: No license field
1:16:01 AM: $ CI= yarn run build
1:16:01 AM: warning package.json: No license field
1:16:01 AM: $ CI= yarn run build
1:16:01 AM: warning package.json: No license field
1:16:15 AM: warning package.json: No license field
1:16:15 AM: $ CI= yarn run build
1:16:16 AM: warning package.json: No license field
1:16:16 AM: $ CI= yarn run build
1:16:16 AM: warning package.json: No license field
1:16:16 AM: $ CI= yarn run build
1:16:16 AM: warning package.json: No license field
1:16:16 AM: $ CI= yarn run build
1:16:16 AM: warning package.json: No license field
1:16:17 AM: $ CI= yarn run build
1:16:17 AM: warning package.json: No license field
1:16:17 AM: $ C

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...