linux jenkins部署之路之,ftp部署怎么匿名還好用咋解決思密達

怎么安裝就不說了,網上一堆

這噶搭是配置 目錄是/etc/vsftpd/vsftpd.conf

# Example config file /etc/vsftpd/vsftpd.conf

#
# The default compiled in settings are fairly paranoid. This sample file
# loosens things up a bit, to make the ftp daemon more usable.
# Please see vsftpd.conf.5 for all compiled in defaults.
#
# READ THIS: This example file is NOT an exhaustive list of vsftpd options.
# Please read the vsftpd.conf.5 manual page to get a full idea of vsftpd's
# capabilities.
#
# Allow anonymous FTP? (Beware - allowed by default if you comment this out).
anonymous_enable=YES
#
# Uncomment this to allow local users to log in.
# When SELinux is enforcing check for SE bool ftp_home_dir
local_enable=YES
#
# Uncomment this to enable any form of FTP write command.
write_enable=YES
#
# Default umask for local users is 077. You may wish to change this to 022,
# if your users expect that (022 is used by most other ftpd's)
local_umask=022
#
# Uncomment this to allow the anonymous FTP user to upload files. This only
# has an effect if the above global write enable is activated. Also, you will
# obviously need to create a directory writable by the FTP user.
# When SELinux is enforcing check for SE bool allow_ftpd_anon_write, allow_ftpd_full_access
anon_upload_enable=YES
#
# Uncomment this if you want the anonymous FTP user to be able to create
# new directories.
anon_mkdir_write_enable=YES
#
# Activate directory messages - messages given to remote users when they
# go into a certain directory.
dirmessage_enable=YES
#
# Activate logging of uploads/downloads.
xferlog_enable=YES
#
# Make sure PORT transfer connections originate from port 20 (ftp-data).
connect_from_port_20=YES
#
# If you want, you can arrange for uploaded anonymous files to be owned by
# a different user. Note! Using "root" for uploaded files is not
# recommended!
#chown_uploads=YES
#chown_username=whoever
#
# You may override where the log file goes if you like. The default is shown
# below.
#xferlog_file=/var/log/xferlog
#
# If you want, you can have your log file in standard ftpd xferlog format.
# Note that the default log file location is /var/log/xferlog in this case.
xferlog_std_format=YES
#
# You may change the default value for timing out an idle session.
#idle_session_timeout=600
#
# You may change the default value for timing out a data connection.
#data_connection_timeout=120
#
# It is recommended that you define on your system a unique user which the
# ftp server can use as a totally isolated and unprivileged user.
#nopriv_user=ftpsecure
#
# Enable this and the server will recognise asynchronous ABOR requests. Not
# recommended for security (the code is non-trivial). Not enabling it,
# however, may confuse older FTP clients.
#async_abor_enable=YES
#
# By default the server will pretend to allow ASCII mode but in fact ignore
# the request. Turn on the below options to have the server actually do ASCII
# mangling on files when in ASCII mode.
# Beware that on some FTP servers, ASCII support allows a denial of service
# attack (DoS) via the command "SIZE /big/file" in ASCII mode. vsftpd
# predicted this attack and has always been safe, reporting the size of the
# raw file.
# ASCII mangling is a horrible feature of the protocol.
#ascii_upload_enable=YES
#ascii_download_enable=YES
#
# You may fully customise the login banner string:
#ftpd_banner=Welcome to blah FTP service.
#
# You may specify a file of disallowed anonymous e-mail addresses. Apparently
# useful for combatting certain DoS attacks.
#deny_email_enable=YES
# (default follows)
#banned_email_file=/etc/vsftpd/banned_emails
#
# You may specify an explicit list of local users to chroot() to their home
# directory. If chroot_local_user is YES, then this list becomes a list of
# users to NOT chroot().
# (Warning! chroot'ing can be very dangerous. If using chroot, make sure that
# the user does not have write access to the top level directory within the
# chroot)
#chroot_local_user=YES
#chroot_list_enable=YES
# (default follows)
chroot_list_file=/etc/vsftpd/chroot_list
#
# You may activate the "-R" option to the builtin ls. This is disabled by
# default to avoid remote users being able to cause excessive I/O on large
# sites. However, some broken FTP clients such as "ncftp" and "mirror" assume
# the presence of the "-R" option, so there is a strong case for enabling it.
#ls_recurse_enable=YES
#
# When "listen" directive is enabled, vsftpd runs in standalone mode and
# listens on IPv4 sockets. This directive cannot be used in conjunction
# with the listen_ipv6 directive.
listen=NO
#
# This directive enables listening on IPv6 sockets. By default, listening
# on the IPv6 "any" address (::) will accept connections from both IPv6
# and IPv4 clients. It is not necessary to listen on *both* IPv4 and IPv6
# sockets. If you want that (perhaps because you want to listen on specific
# addresses) then you must run two copies of vsftpd with two configuration
# files.
# Make sure, that one of the listen options is commented !!
listen_ipv6=YES


pam_service_name=vsftpd
userlist_enable=YES
tcp_wrappers=YES
#123qwe123

如果以上完事發現550,那就是用戶對那個/var/ftp下的文件夾權限不夠,比如/var/ftp/pub文件夾

chmod 755 /var/ftp,這個目錄是必須755

可以chmod 777 pub

----------------------------------------------------------------

Publish over FTP

在Jenkins服務上安裝?Publish over FTP也就不講了也可百度 ,配置是這樣


----------------------------------------------------------------


----------------------------------------------------------------

最后是pipline配置

node ('master') {
? ? def mvnHome
? ? stage('Code checkout') {
? ? ? ? checkout([$class: 'SubversionSCM', additionalCredentials: [], excludedCommitMessages: '', excludedRegions: '', excludedRevprop: '', excludedUsers: '', filterChangelog: false, ignoreDirPropChanges: false, includedRegions: '', locations: [[credentialsId: 'ed7688fa-9ae9-4a1c-a5fd-99957f7b5b5f', depthOption: 'infinity', ignoreExternalsOption: true, local: './tgcw-service-fyz', remote: 'https://10.11.63.242/svnplugin/tyz/fyz-code/trunk/tgcw-service-fyz']], quietOperation: true, workspaceUpdater: [$class: 'UpdateUpdater']])
? ? }
? ? stage('Build') {
? ? ? ? mvnHome = tool 'maven3.5.2'
? ? ? ? env.JAVA_HOME= tool 'Java8'
? ? ? ? env.PATH="${env.JAVA_HOME}/bin:${env.PATH}"
? ? ? ? dir('/opt/jenkins/jenkins_home/workspace/tgcw-service-fyz/tgcw-service-fyz') {
? ? ? ? ? ? sh "'${mvnHome}/bin/mvn' clean install"
? ? ? ? }
? ? }
? ?stage('FTP upload') {
ftpPublisher alwaysPublishFromMaster: false, continueOnError: false, failOnError: false, publishers: [[configName: 'anonymous215', transfers: [[asciiMode: false, cleanRemote: false, excludes: '', flatten: false, makeEmptyDirs: false, noDefaultExcludes: false, patternSeparator: '[, ]+', remoteDirectory: '/', remoteDirectorySDF: false, removePrefix: '', sourceFiles: '**/*.jar']], usePromotionTimestamp: false, useWorkspaceInPromotion: false, verbose: false]]
? ? }
? ? stage('Clean up') {
? ? ? ? cleanWs cleanWhenFailure: false, cleanWhenUnstable: false, deleteDirs: true, notFailBuild: true
? ? }

}

-------------------------------------------------------------------------------------------------------------

sbin/service crond start //啟動服務

/sbin/service crond stop //關閉服務

/sbin/service crond restart //重啟服務

/sbin/service crond reload //重新載入配置

/etc/crontab?


懂的人知道我這思路有多重要,不懂的,聯系我也可以給講。

本文來自互聯網用戶投稿,該文觀點僅代表作者本人,不代表本站立場。本站僅提供信息存儲空間服務,不擁有所有權,不承擔相關法律責任。
如若轉載,請注明出處:http://www.pswp.cn/news/387090.shtml
繁體地址,請注明出處:http://hk.pswp.cn/news/387090.shtml
英文地址,請注明出處:http://en.pswp.cn/news/387090.shtml

如若內容造成侵權/違法違規/事實不符,請聯系多彩編程網進行投訴反饋email:809451989@qq.com,一經查實,立即刪除!

相關文章

powerCat進行常規tcp端口轉發

實戰中,我們也會遇到需要我們進行端口轉發的情況,比如已經拿下的目標機1是在dmz區,而目標1所在內網的其他目標只能通過目標1去訪問,這時候我們就需要端口轉發或者代理來進行后滲透。這次就要介紹一個加強版的nc,基于po…

Lecture 7 Hashing Table I

Hash |---Hash function: Division, Multiplication |---Collision: Chaining, Open addressing(Linear,Double hasing) Symbol-table problem: Table S holding n records pointer --> key|satelite data (record) Hashing: Hash function h maps keys “randomly”…

SpringCloud 微服務

一微服務架構概述1.1 微服務特性以及優點每個服務可以獨立運行在自己的進程里一系列獨立運行的微服務(goods,order,pay,user,search…)共同構建了整個系統每個服務為獨立的業務開發,一個微服務只關注某個特定的功能,例如用戶管理,商品管理微服…

window起別名

http://www.bagualu.net/wordpress/archives/1714 轉載于:https://www.cnblogs.com/wei-huan/p/10654026.html

vue在ie9中的兼容問題

問題總結 https://github.com/vuejs-templates/webpack/issues/260 首先npm install --save babel-polyfill然后在main.js中的最前面引入babel-polyfillimport babel-polyfill在index.html 加入以下代碼&#xff08;非必須&#xff09;<meta http-equiv"X-UA-Compatib…

Lecture 9 Random built Binary Search Trees BSTs

Random built Binary Search Trees BSTs E[hight] near 3logn Quick Sort? Relation to Quick Sort: BST sort & Quick sort make same comparisons but in a different order. Randomized BST Sort: 1. Randomly permute A 2. BST sort(A)

spring boot 帶遠程調試啟動方式

比如啟動service-system-0.0.1-SNAPSHOT.jar和service-file-0.0.1-SNAPSHOT.jar nohup java -Xdebug -Xrunjdwp:servery,transportdt_socket,address7999,suspendn -jar service-system-0.0.1-SNAPSHOT.jar > /dev/null 2>&1 &nohup java -Xdebug -Xrunjdwp:se…

文件讀寫

讀寫文件通常都是IO操作&#xff0c;Python內置了讀文件的函數&#xff0c;用法和C是兼容的。 讀寫文件前&#xff0c;我們先必須了解一下&#xff0c;在磁盤上讀寫文件的功能都是有操作系統提供的&#xff0c;現代操作系統不允許普通的程序直接操作磁盤&#xff0c;所以&#…

Vue項目中遇到了大文件分片上傳的問題

Vue項目中遇到了大文件分片上傳的問題&#xff0c;之前用過webuploader&#xff0c;索性就把Vue2.0與webuploader結合起來使用&#xff0c;封裝了一個vue的上傳組件&#xff0c;使用起來也比較舒爽。 上傳就上傳吧&#xff0c;為什么搞得那么麻煩&#xff0c;用分片上傳&#x…

NDK學習筆記-使用現有so動態庫

前面將的都是如何使用C/C文件生成so動態庫&#xff0c;那么在使用別人的so動態庫的時候應該怎么做呢&#xff1f;這篇文章就是使用一個變聲功能的動態庫&#xff0c;完成對于以有so動態庫的說明。 動態庫來源 在互聯網中&#xff0c;有著許許多多動態庫&#xff0c;很多廠商也對…

Spring cloud系列十四 分布式鏈路監控Spring Cloud Sleuth

1. 概述 Spring Cloud Sleuth實現對Spring cloud 分布式鏈路監控 本文介紹了和Sleuth相關的內容&#xff0c;主要內容如下&#xff1a; Spring Cloud Sleuth中的重要術語和意義&#xff1a;Span、Trance、AnnotationZipkin中圖形化展示分布式鏈接監控數據并說明字段意義Spring …

Linux源碼編譯安裝程序

一、程序的組成部分 Linux下程序大都是由以下幾部分組成&#xff1a; 二進制文件&#xff1a;也就是可以運行的程序文件 庫文件&#xff1a;就是通常我們見到的lib目錄下的文件 配置文件&#xff1a;這個不必多說&#xff0c;都知道 幫助文檔&#xff1a;通常是我們在linux下用…

selenium用法詳解

selenium用法詳解 selenium主要是用來做自動化測試&#xff0c;支持多種瀏覽器&#xff0c;爬蟲中主要用來解決JavaScript渲染問題。 模擬瀏覽器進行網頁加載&#xff0c;當requests,urllib無法正常獲取網頁內容的時候一、聲明瀏覽器對象 注意點一&#xff0c;Python文件名或者…

haoop筆記

8:00 2019/3/141&#xff1a;什么是hadoop? hadoop是解決大數據問題的一整套技術方案2&#xff1a;hadoop的組成? 核心框架 分布式文件系統 分布式計算框架 分布式資源分配框架 hadoop對象存儲 機器計算3&#xff1a;hadoop 云計算 大數據 微服務 人工智能關系 參見word學習…

Sleuth則是用來共方便的集成Zipkin。

簡述 使用 spring cloud 用到最多的是各種rest服務調用&#xff0c;Twitter的Zipkin 是一種實現分布式跟蹤解決方案&#xff0c;Sleuth則是用來共方便的集成Zipkin。調用跟蹤系統的業務場景 隨著服務的拆分&#xff0c;系統的模塊變得越來越多&#xff0c;不同的模塊可能由不同…

Spring Cloud 中 分布式事務解決方案 -- 阿里GTS的使用

1&#xff1a;依賴引入<!--gts相關--><!--數據庫連接--><dependency><groupId>org.springframework.boot</groupId><artifactId>spring-boot-starter-jdbc</artifactId></dependency><dependency><groupId>mysql&…

《HTTP 權威指南》筆記:第十五章 實體與編碼

&#xfffc; 如果把 「HTTP 報文」想象為因特網貨運系統的「箱子」,那么「HTTP 實體」就是報文中的實際的「貨物」. 其中,實體又包含了「實體首部」 和 「實體主體」,實體首部用于描述各種參數,實體主體就是原始貨物. 常見的實體首部 實體的大小: Content-Length 定義: 報文的…