Answer the question
In order to leave comments, you need to log in
I don't understand what's wrong with gulp?
I have a mistake I can't figure it out please help
import { configFTP } from '../config/ftp.js'
import vinylFTP from "vinyl-ftp"
import util from "gulp-util"
export const ftp = () => {
configFTP.log = util.log;
const ftpConnect = vinylFTP.create(configFTP)
return app.gulp.src(`${app.path.buildFolder}/**/*.*`, {})
.pipe(app.plugins.plumber(
app.plugins.notify.onError({
title:'FTP ',
message: 'Error: <%= error.message %>'
})
))
.pipe(ftpConnect.dest(`/${app.path.ftp}/${app.path.rootFolder}`))
}
export let configFTP = {
host:" ",// адрес ftp сервера
user:" ",//имя пользователя
password:" ",//пароль
parallel:5//кол-во одновременных потоков
}
$ npm run deploy
> [email protected] deploy
> gulp deployFTP --build
[23:49:43] Using gulpfile ~\OneDrive\Рабочий стол\gulp\gulpfile.js
[23:49:43] Starting 'deployFTP'...
[23:49:43] Starting 'reset'...
[23:49:43] Finished 'reset' after 63 ms
[23:49:43] Starting 'copy'...
[23:49:43] Starting 'html'...
[23:49:43] Starting 'scss'...
[23:49:43] Starting 'js'...
[23:49:43] Starting 'images'...
[23:49:43] Finished 'copy' after 155 ms
[gulp-version-number] Output to file: gulp/version.json
[23:49:45] Finished 'html' after 1.71 s
[23:49:45] Finished 'scss' after 1.77 s
[23:49:46] asset app.min.js 179 bytes [emitted] [minimized] (name: main)
webpack 5.65.0 compiled successfully
[23:49:46] Finished 'js' after 2.7 s
[23:49:46] gulp-imagemin: Minified 1 image (saved 5.77 kB - 55.2%)
[23:49:46] Finished 'images' after 3.01 s
[23:49:46] Starting 'ftp'...
<b>[23:49:46] CONN
[23:49:46] ERROR Error: getaddrinfo ENOTFOUND
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26)
at GetAddrInfoReqWrap.callbackTrampoline (node:internal/async_hooks:130:17) (ENOTFOUND)
[23:49:46] DISC
[23:49:46] gulp-notify: [FTP ] Error: getaddrinfo ENOTFOUND
[23:49:46] 'ftp' errored after 171 ms
[23:49:46] Error: premature close
at onclosenexttick (C:\Users\gorla\OneDrive\Рабочий стол\gulp\node_modules\end-of-stream\index.js:54:86)
at processTicksAndRejections (node:internal/process/task_queues:78:11)
[23:49:46] 'deployFTP' errored after 3.28
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question