package com.njzscloud.common.mp.config;

import lombok.Getter;
import lombok.Setter;
import org.springframework.boot.context.properties.ConfigurationProperties;

@Getter
@Setter
@ConfigurationProperties("mybatis-plus.tunnel")
public class DbTunnelProperties {
    private boolean enable = false;

    private SSHProperties ssh;
    private DBProperties db;

    @Getter
    @Setter
    public static class SSHProperties {
        private String host;
        private int port = 22;
        private String user;
        private String credentials;
        private String passphrase;
        private int localPort;
    }

    @Getter
    @Setter
    public static class DBProperties {
        private String host;
        private int port = 3306;
    }

}
