在Mac Sierra上,如何授予ssh会话访问显示的权限? [英] On a Mac Sierra, how can I give an ssh session access to the display?

查看:199
本文介绍了在Mac Sierra上,如何授予ssh会话访问显示的权限?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这是跟Jenkins一起运行ios-sim 的后续工作-我当通过ssh(而不是通过launchctl

This is a follow-up of Running ios-sim with Jenkins - I need a way to make this work when the Jenkins slave is run via ssh, and not via launchctl

因此,通常来说,如果我使用ssh登录到Mac,如何访问显示器?

So, in general, how can I access the display if I log onto a mac using ssh?

推荐答案

我认为您必须使用与ssh连接一起使用的用户登录Mac(Jenkins从站).登录后,您运行的作业应该可以访问显示.

I think you have to login to the Mac (Jenkins slave) using the user that you are using with the ssh connection. Once logged in, the jobs you run should be able to access the display.

我们使用"通过SSH在Unix计算机上启动从属代理程序" 启动方法在Mac计算机上启动Jenkins从属.我们在主服务器和从服务器上配置了SSH凭据,因此这是无缝的.我的Mac奴隶离我很远.我目前无法连接到它,以查看谁登录不重要.也许不一定是您的ssh登录.

We start the Jenkins slave on our Mac machine using "Launch slave agents on Unix machines via SSH" Launch Method. We have SSH credentials configured on the master and slave so this is seamless. My Mac slave is located a great distance from me. I can't currently connect to it to see if it matters who is logged in. Perhaps it doesn't have to be your ssh login.

编辑后添加:理想情况下,您无需使用"sudo"来运行命令.但是,您可能必须这样做.

Edited to add: Ideally you would not need to use "sudo" to run your command. But, you might have to.

这篇关于在Mac Sierra上,如何授予ssh会话访问显示的权限?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆