0
gulpタスクを使用してプロダクションに展開していますが、gulp-deployに問題があります。サーバ上の別の場所にコピーする他のファイルが必要です。Gulpプロダクションにftpを導入
//Gulp APP ftp deploy
gulp.task('deploy-app', function() {
var conn = ftp.create({
host: 'xxx',
user: 'xxx',
password: 'xxx',
parallel: 10,
log: gutil.log
});
var globs = [
'./css/**/*{css,png,jpg,gif,ttf,woff,eof,svg,woff2}',
'./img/**',
'./views/**',
'./scripts/**',
'index.html',
'Web.config'
];
// using base = '.' will transfer everything to /public_html correctly
// turn off buffering in gulp.src for best performance
return gulp.src(globs, { base: '.', buffer: false })
.pipe(conn.newer('/site/wwwroot')) // only upload newer files
.pipe(conn.dest('/site/wwwroot'));
});
私がここに持っている問題は、私は、フォルダdistの内にある別ののindex.htmlを持っているので、私は、ルートからのindex.htmlを必要といけないということですが、それは、サーバーのフォルダのルートに行かなければなりません、行う方法