This commit is contained in:
Paidax
2024-12-11 15:10:08 +08:00
parent fe30f6e24b
commit 6ebbf5d576
7 changed files with 289 additions and 91 deletions
+13
View File
@@ -8,6 +8,7 @@ import io.v.nutz.web.commons.base.Globals;
import io.v.nutz.web.commons.ext.pubsub.WebPubSub;
import io.v.nutz.web.commons.filter.CsrfFilter;
import io.v.nutz.web.commons.filter.SsrfFilter;
import org.apache.commons.net.ftp.FTPClient;
import org.beetl.core.GroupTemplate;
import org.nutz.boot.NbApp;
import org.nutz.dao.Chain;
@@ -41,6 +42,8 @@ import java.util.Enumeration;
import java.util.List;
import java.util.stream.Collectors;
import static org.nutz.boot.starter.ftp.FtpStarter.*;
/**
* @author wizzer@qq.com
*/
@@ -92,6 +95,16 @@ public class MainLauncher {
init_task();
init_proposal_undertake();
ioc.get(Globals.class);
try {
FTPClient ftpClient = new FTPClient();
ftpClient.connect(conf.get(PROP_SERVER_HOST, ""), conf.getInt(PROP_SERVER_PORT, 21));
ftpClient.login(conf.get(PROP_SERVER_USERNAME, ""), conf.get(PROP_SERVER_PASSWORD, ""));
ftpClient.enterLocalPassiveMode();
System.out.println("***************************=" + ftpClient.getReplyCode());
} catch (Exception e) {
e.printStackTrace();
}
}
/**