Skip to content

集成ssh-agent代理组件 #72

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
hengboy opened this issue Nov 24, 2020 · 1 comment
Closed

集成ssh-agent代理组件 #72

hengboy opened this issue Nov 24, 2020 · 1 comment
Assignees
Labels
kind/feature New features

Comments

@hengboy
Copy link
Member

hengboy commented Nov 24, 2020

通过SpringBoot Starter的方式来集成ssh-agent,ssh-agent组件源码地址:https://github.com/minbox-projects/ssh-agent。

@hengboy hengboy added the kind/feature New features label Nov 24, 2020
@hengboy hengboy self-assigned this Nov 24, 2020
@hengboy
Copy link
Member Author

hengboy commented Nov 24, 2020

添加依赖

<dependency>
    <groupId>org.minbox.framework</groupId>
    <artifactId>api-boot-starter-ssh-agent</artifactId>
</dependency>

application.yml配置

api:
    boot:
        ssh-agent:
            configs:
                # 用户名、密码方式代理端口转发
                - authentication-method: USERNAME_PASSWORD
                  username: metadata
                  password: xxxxx
                  server-ip: xxx.xxx.xxx.xxx
                  local-port: 3307
                  forward-target-port: 3306
                # ssh private key 方式代理端口转发
                # 默认使用RSA加密方式的 ~/.ssh/id_rsa 文件
                # authentication-method默认配置为:SSH_PRIVATE_KEY
                - username: metadata
                  server-ip: xxx.xxx.xxx.xxx
                  local-port: 3307
                  forward-target-port: 3306

@hengboy hengboy closed this as completed Nov 24, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature New features
Projects
None yet
Development

No branches or pull requests

1 participant