mirror of
https://github.com/ditatompel/insights.git
synced 2025-01-08 03:12:06 +07:00
chore: Added new article about "Deskflow"
This commit is contained in:
parent
30f0e00594
commit
8be282ec38
7 changed files with 256 additions and 0 deletions
Binary file not shown.
After Width: | Height: | Size: 90 KiB |
Binary file not shown.
After Width: | Height: | Size: 19 KiB |
Binary file not shown.
After Width: | Height: | Size: 28 KiB |
Binary file not shown.
After Width: | Height: | Size: 43 KiB |
Binary file not shown.
After Width: | Height: | Size: 128 KiB |
|
@ -0,0 +1,127 @@
|
|||
---
|
||||
title: Mengontrol Komputer Lain di Jaringan Dengan Satu Mouse dan Keyboard Menggunakan Deskflow
|
||||
description: Cara menginstall, mengonfigurasi, dan menggunakan Deskflow di Linux. Sebuah aplikasi open-source ntuk sharing keyboard dan mouse dengan komputer lain.
|
||||
summary: Cara menginstall, mengonfigurasi, dan menggunakan Deskflow di Linux. Sebuah aplikasi open-source ntuk sharing keyboard dan mouse dengan komputer lain.
|
||||
date: 2024-09-23T23:23:00+07:00
|
||||
lastmod:
|
||||
draft: false
|
||||
noindex: false
|
||||
nav_weight: 1000
|
||||
categories:
|
||||
- TIL
|
||||
tags:
|
||||
- Deskflow
|
||||
images:
|
||||
authors:
|
||||
- ditatompel
|
||||
---
|
||||
|
||||
Ada banyak cara untuk mengontrol dekstop (GUI) komputer lain melalui jaringan,
|
||||
misalnya menggunakan RDP atau VNC. Kadang kala saya menggunakan
|
||||
_X11 Forwarding_ juga untuk menjalankan sebuah aplikasi GUI dari remote
|
||||
komputer ke laptop saya. Sedangkan untuk kontrol GUI yang lebih kompleks,
|
||||
saya menggunakan [xrdp][xrdp_gh].
|
||||
|
||||
Tapi mungkin kedepannya cara saya untuk melakukan control desktop komputer lain
|
||||
di jaringan lokal akan berbeda setelah saya menemukan [Deskflow][deskflow_gh].
|
||||
Deskflow adalah sebuah aplikasi _open source_ (_upstream_ dari
|
||||
[Synergy][synergy_web], komersial) untuk sharing keyboard dan mouse dengan
|
||||
komputer lain. Dengan Deskflow, satu keyboard dan trackpad dari laptop saya
|
||||
bisa saya gunakan untuk mengontrol desktop komputer lain.
|
||||
|
||||
Berbeda dengan RDP atau VNC yang menampilkan tampilan remote desktop ke
|
||||
PC / laptop kita; Deskflow sama sekali tidak menampilkan apapun dari remote
|
||||
desktop. Jika disederhanakan, Deskflow hanya merekam dan meneruskan mouse,
|
||||
keyboard dan clipboard ke komputer lain (client). Jadi Deskflow efektif jika
|
||||
remote desktop (client) memiliki monitor dan monitor tersebut berada di dekat
|
||||
Anda (ibaratkan Anda memiliki multiple monitor, tapi dari PC yang berbeda).
|
||||
|
||||
## Instalasi
|
||||
|
||||
Saat tulisan ini dibuat, Deskflow **belum tersedia** di _package manager_
|
||||
seluruh distro Linux. Deskflow juga tidak menyediakan _pre-compiled binary_
|
||||
baik untuk Linux, MAC, maupun Windows. Jadi satu-satunya cara untuk menginstall
|
||||
dan menjalankan Deskflow adalah meng-compile dari source code-nya.
|
||||
|
||||
Meskipun begitu, Anda tidak perlu khawatir karena sudah tersedia
|
||||
_"install / helper"_ script untuk sebagian besar distro (Debian, Fedora,
|
||||
OpenSUSE, dan Arch Linux).
|
||||
|
||||
Di artikel ini, saya akan menggunakan 2 buah komputer (semuanya menggunakan
|
||||
sistem operasi Linux):
|
||||
|
||||
- P50: Komputer utama saya yang akan saya gunakan untuk mengontrol komputer
|
||||
lain (server).
|
||||
- T420: Komputer lain yang akan saya kontrol dari P50 (client).
|
||||
|
||||
Pertama, download source code Deskflow dan
|
||||
[compile aplikasi Deskflow][deskflow_cmp] di server dan client:
|
||||
|
||||
```shell
|
||||
git clone https://github.com/deskflow/deskflow.git
|
||||
cd deskflow
|
||||
./scripts/install_deps.sh
|
||||
cmake -B build
|
||||
cmake --build build -j$(nproc)
|
||||
```
|
||||
|
||||
Setelah proses kompilasi berhasil, pastikan _unit test_ dan _integrity test_
|
||||
berjalan dengan baik:
|
||||
|
||||
```shell
|
||||
./build/bin/unittests
|
||||
./build/bin/integtests
|
||||
```
|
||||
|
||||
## Konfigurasi
|
||||
|
||||
### Server
|
||||
|
||||
Di komputer server, jalankan `./build/bin/deskflow`, kemudian pilih
|
||||
_"Use this computer's keyboard and mouse"_.
|
||||
|
||||
![deskflow server](deskflow-server1.png#center)
|
||||
|
||||
Untuk mempermudah penggunaan aplikasi Deskflow, kita bisa membuat
|
||||
[XDG Desktop Entry][xdg_desktop_spec] dengan meng-copy file
|
||||
`.res/dist/linux/deskflow.desktop` ke `~/.local/share/applications`
|
||||
(untuk single user) atau `/usr/share/applications` untuk multi user.
|
||||
Jangan lupa sesuaikan nilai dari `Path=/usr/bin` dan `Exec=/usr/bin/deskflow`
|
||||
yang ada pada file tersebut ke direktori dimana file binary deskflow disimpan.
|
||||
|
||||
### Client
|
||||
|
||||
Di komputer client, jalankan `./build/bin/deskflow` kemudian pilih
|
||||
_"Use another computer's mouse and keyboard"_ dan masukkan alamat IP server ke
|
||||
input text dibawahnya.
|
||||
|
||||
> Catatan: Entah kenapa untuk pertama kali mencoba melakukan koneksi ke server,
|
||||
> saya tidak bisa melakukannya dari X11 Forwarding. Jadi saya harus melakukan
|
||||
> koneksi awal langsung dari GUI laptop client (bukan dari GUI X11 Forwarding).
|
||||
|
||||
![deskflow client](deskflow-client1.png#center)
|
||||
|
||||
Setelah mencoba melakukan koneksi dari sisi client, akan muncul _pop-up window_
|
||||
di komputer server yang menginformasikan bahwa ada "client" baru ingin
|
||||
melakukan koneksi. Pilih _"Add client"_.
|
||||
|
||||
![deskflow add client popup](deskflow-add-client-popup.png#center)
|
||||
|
||||
Setelah itu Anda dapat memilih layout dimana posisi komputer client dapat kita
|
||||
kontrol (seperti ketika menggunakan dual monitor).
|
||||
|
||||
![deskflow layout](deskflow-layout.png#center)
|
||||
|
||||
Klik "Ok" dan cobalah untuk menggeser posisi mouse pointer ke arah dimana Anda
|
||||
mengkonfigurasi posisi komputer client. Seharusnya Anda sudah dapat menggunakan
|
||||
mouse dan keyboard komputer server untuk komputer client.
|
||||
|
||||
> Tips: Setelah client ter-registrasi ke server, Anda dapat secara manual
|
||||
> melakukan koneksi dari client menggunakan CLI dengan
|
||||
> `deskflowc --enable-crypto [alamat ip server]`.
|
||||
|
||||
[xrdp_gh]: https://github.com/neutrinolabs/xrdp "xrdp GitHub repository"
|
||||
[deskflow_gh]: https://github.com/deskflow/deskflow "Deskflow GitHub repository"
|
||||
[synergy_web]: https://symless.com/synergy "Synergy Website"
|
||||
[deskflow_cmp]: https://github.com/deskflow/deskflow/blob/master/BUILD.md "Deskflow Build Quick Start"
|
||||
[xdg_desktop_spec]: https://specifications.freedesktop.org/desktop-entry-spec/latest/ "XDG Desktop Entry spec"
|
|
@ -0,0 +1,129 @@
|
|||
---
|
||||
title: Control Nearby Computers With One Mouse and Keyboard Using Deskflow
|
||||
description: How to install, configure, and use Deskflow on multiple Linux computers. Discover the steps to compile Deskflow from source, create XDG Desktop Entries, and connect clients to servers for seamless integration.
|
||||
summary: Learn how to install, configure, and use Deskflow on multiple Linux computers. Discover the steps to compile Deskflow from source, create XDG Desktop Entries, and connect clients to servers for seamless integration.
|
||||
# linkTitle:
|
||||
date: 2024-09-23T23:23:00+07:00
|
||||
lastmod:
|
||||
draft: false
|
||||
noindex: false
|
||||
# comments: false
|
||||
nav_weight: 1000
|
||||
categories:
|
||||
- TIL
|
||||
tags:
|
||||
- Deskflow
|
||||
images:
|
||||
authors:
|
||||
- ditatompel
|
||||
---
|
||||
|
||||
There are several ways to control another computer's desktop (GUI) over a
|
||||
network, such as using RDP or VNC. Occasionally, I also use X11 Forwarding to
|
||||
run a GUI application from a remote computer on my laptop. While for more
|
||||
complex GUI control, I use [xrdp][xrdp_gh].
|
||||
|
||||
But perhaps in the future my way of controlling another computer's desktop on a
|
||||
local network will be different after I discovered [Deskflow][deskflow_gh].
|
||||
Deskflow is an open-source application (upstream from [Synergy][synergy_web],
|
||||
commercial) for sharing keyboard and mouse with other computers. With Deskflow,
|
||||
I can use one keyboard and trackpad from my laptop to control another
|
||||
computer's desktop.
|
||||
|
||||
Unlike RDP or VNC, which display the remote desktop display on our PC/laptop;
|
||||
Deskflow does not display anything from the remote desktop at all.
|
||||
If simplified, Deskflow only records and forwards mouse, keyboard, and
|
||||
clipboard input to another computer (client). So Deskflow is effective if the
|
||||
remote desktop (client) has a monitor, and it's close by (as if you have
|
||||
multiple monitors, but from different PCs).
|
||||
|
||||
## Installation
|
||||
|
||||
At the time of writing, Deskflow is **not** yet available in the package
|
||||
manager for all Linux distributions. Deskflow also does not provide
|
||||
pre-compiled binaries for Linux, macOS, or Windows. Therefore, the only way to
|
||||
install and run Deskflow is to compile it from its source code.
|
||||
|
||||
However, you don't need to worry because there is already an "install" script
|
||||
available for most distributions (Debian, Fedora, OpenSUSE, and Arch Linux).
|
||||
|
||||
In this article, I will use two computers, both running the Linux operating
|
||||
system:
|
||||
|
||||
- P50: My main computer that I will use to control another computer
|
||||
(the server).
|
||||
- T420: Another computer that I will control from P50 (the client).
|
||||
|
||||
First, download the Deskflow source code and
|
||||
[compile the Deskflow application][deskflow_cmp] on both the server and client:
|
||||
|
||||
```shell
|
||||
git clone https://github.com/deskflow/deskflow.git
|
||||
cd deskflow
|
||||
./scripts/install_deps.sh
|
||||
cmake -B build
|
||||
cmake --build build -j$(nproc)
|
||||
```
|
||||
|
||||
After the compilation process completes successfully, ensure that both the
|
||||
_unit tests_ and _integrity tests_ pass without issue:
|
||||
|
||||
```shell
|
||||
./build/bin/unittests
|
||||
./build/bin/integtests
|
||||
```
|
||||
|
||||
## Configuration
|
||||
|
||||
### Server
|
||||
|
||||
On the server computer, run `./build/bin/deskflow`, then select
|
||||
_"Use this computer's keyboard and mouse"_.
|
||||
|
||||
![deskflow server](deskflow-server1.png#center)
|
||||
|
||||
To make it easier to use the Deskflow application, we can create an
|
||||
[XDG Desktop Entry][xdg_desktop_spec] by copying the
|
||||
`.res/dist/linux/deskflow.desktop` file to `~/.local/share/applications`
|
||||
(for single-user mode) or `/usr/share/applications` for multi-user mode.
|
||||
Don't forget to adjust the values of `Path=/usr/bin` and
|
||||
`Exec=/usr/bin/deskflow` in the file to point to the directory where the
|
||||
deskflow binary file is stored.
|
||||
|
||||
### Client
|
||||
|
||||
On the client computer, run `./build/bin/deskflow`, then select
|
||||
_"Use another computer's mouse and keyboard"_ and enter the server's IP address
|
||||
into the text input below.
|
||||
|
||||
> Note: For some reason, I encountered an issue the first time I tried to
|
||||
> connect to the server via X11 Forwarding. Therefore, I made the initial
|
||||
> connection directly from the client laptop GUI (not through the
|
||||
> X11 Forwarding GUI).
|
||||
|
||||
![deskflow client](deskflow-client1.png#center)
|
||||
|
||||
After trying to connect from the client side, a pop-up window will appear on
|
||||
the server computer informing you that there is a new client wanting to
|
||||
connect. Select _"Add client"_.
|
||||
|
||||
![deskflow add client popup](deskflow-add-client-popup.png#center)
|
||||
|
||||
After registering the client, you can choose a layout where we can control the
|
||||
position of the client computer (such as when using dual monitors).
|
||||
|
||||
![deskflow layout](deskflow-layout.png#center)
|
||||
|
||||
Click "OK" and try to move the mouse pointer position to the direction where
|
||||
you configured the client computer position. You should be able to use the
|
||||
server computer's mouse and keyboard for the client computer.
|
||||
|
||||
> Tip: After the client is registered to the server, you can manually connect
|
||||
> from the client using the CLI with
|
||||
> `deskflowc --enable-crypto [server IP address]`.
|
||||
|
||||
[xrdp_gh]: https://github.com/neutrinolabs/xrdp "xrdp GitHub repository"
|
||||
[deskflow_gh]: https://github.com/deskflow/deskflow "Deskflow GitHub repository"
|
||||
[synergy_web]: https://symless.com/synergy "Synergy Website"
|
||||
[deskflow_cmp]: https://github.com/deskflow/deskflow/blob/master/BUILD.md "Deskflow Build Quick Start"
|
||||
[xdg_desktop_spec]: https://specifications.freedesktop.org/desktop-entry-spec/latest/ "XDG Desktop Entry spec"
|
Loading…
Reference in a new issue