* (nits)

* add hardware encoding support for Intel QSV via VAAPI

* automate RENDER_GID env var

* add remmina

* remmina: github CI
This commit is contained in:
Mark Lowne 2022-03-18 18:25:46 +01:00 committed by GitHub
parent 87082bb978
commit 12c92cb55a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
9 changed files with 355 additions and 1 deletions

View File

@ -0,0 +1,20 @@
ARG BASE_IMAGE=m1k1o/neko:base
FROM $BASE_IMAGE
# install remmina
RUN set -eux; apt-get update; \
apt-get install -y --no-install-recommends \
remmina-plugin-rdp remmina-plugin-vnc \
# remmina-plugin-x2go # not in bullseye
remmina-plugin-spice remmina-plugin-nx; \
# clean up
apt-get clean -y; \
rm -rf /var/lib/apt/lists/* /var/cache/apt/*
# copy configuation files
COPY supervisord.conf /etc/neko/supervisord/remmina.conf
COPY --chown=neko remmina.pref /home/neko/.config/remmina/remmina.pref
COPY --chown=neko rdp.remmina spice.remmina vnc.remmina /home/neko/.local/share/remmina/
COPY run-remmina.sh /usr/bin/run-remmina.sh
ENV REMMINA_URL=
ENV REMMINA_PROFILE=

View File

@ -0,0 +1,90 @@
[remmina]
password=
gateway_username=
notes_text=
vc=
preferipv6=0
ssh_tunnel_loopback=0
serialname=
sound=local
printer_overrides=
name=rdpdefault
console=0
colordepth=99
security=
precommand=
disable_fastpath=0
left-handed=0
postcommand=
multitransport=0
group=
server=
ssh_tunnel_certfile=
glyph-cache=0
ssh_tunnel_enabled=0
disableclipboard=0
audio-output=
parallelpath=
monitorids=
cert_ignore=0
gateway_server=
serialpermissive=0
protocol=RDP
old-license=0
ssh_tunnel_password=
resolution_mode=2
pth=
loadbalanceinfo=
disableautoreconnect=0
clientname=
clientbuild=
resolution_width=0
drive=
relax-order-checks=0
username=
base-cred-for-gw=0
gateway_domain=
network=none
rdp2tcp=
gateway_password=
serialdriver=
domain=
profile-lock=0
rdp_reconnect_attempts=
restricted-admin=0
multimon=0
exec=
smartcardname=
serialpath=
enable-autostart=0
usb=
shareprinter=0
ssh_tunnel_passphrase=
shareparallel=0
disablepasswordstoring=0
quality=0
span=0
parallelname=
ssh_tunnel_auth=0
keymap=
ssh_tunnel_username=
execpath=
shareserial=0
resolution_height=0
timeout=
useproxyenv=0
sharesmartcard=0
freerdp_log_filters=
microphone=
dvc=
ssh_tunnel_privatekey=
gwtransp=http
ssh_tunnel_server=
ignore-tls-errors=1
disable-smooth-scrolling=0
gateway_usage=0
websockets=0
freerdp_log_level=INFO
window_maximize=1
scale=1
viewmode=4

View File

@ -0,0 +1,103 @@
[remmina_pref]
secret=Jsh7BJPwHqLCKi2vdkMAImSgdBVZGF6s8VbUPY3Q9WA=
datadir_path=
remmina_file_name=%G_%P_%N_%h
screenshot_path=
screenshot_name=
deny_screenshot_clipboard=true
save_view_mode=true
use_master_password=false
unlock_timeout=0
unlock_password=
trust_all=true
floating_toolbar_placement=0
toolbar_placement=3
prevent_snap_welcome_message=true
last_quickconnect_protocol=
fullscreen_on_auto=true
always_show_tab=false
hide_connection_toolbar=true
hide_searchbar=true
default_action=0
scale_quality=3
ssh_loglevel=1
ssh_parseconfig=true
hide_toolbar=true
small_toolbutton=true
view_file_mode=0
resolutions=640x480,800x600,1024x768,1152x864,1280x960,1400x1050
keystrokes=
main_width=600
main_height=400
main_maximize=true
main_sort_column_id=1
main_sort_order=0
expanded_group=
toolbar_pin_down=false
sshtunnel_port=4732
ssh_tcp_keepidle=20
ssh_tcp_keepintvl=10
ssh_tcp_keepcnt=3
ssh_tcp_usrtimeout=60000
applet_new_ontop=false
applet_hide_count=true
applet_enable_avahi=false
disable_tray_icon=true
dark_tray_icon=false
recent_maximum=10
default_mode=3
tab_mode=0
fullscreen_toolbar_visibility=2
auto_scroll_step=10
hostkey=65508
shortcutkey_fullscreen=
shortcutkey_autofit=
shortcutkey_nexttab=
shortcutkey_prevtab=
shortcutkey_scale=
shortcutkey_grab=65508
shortcutkey_viewonly=109
shortcutkey_screenshot=
shortcutkey_minimize=65478
shortcutkey_disconnect=65473
shortcutkey_toolbar=116
vte_font=
vte_allow_bold_text=true
vte_lines=512
[ssh_colors]
background=#d5ccba
cursor=#45373c
bold=#45373c
foreground=#45373c
color0=#20111b
color1=#be100e
color2=#858162
color3=#eaa549
color4=#426a79
color5=#97522c
color6=#989a9c
color7=#968c83
color8=#5e5252
color9=#be100e
color10=#858162
color11=#eaa549
color12=#426a79
color13=#97522c
color14=#989a9c
color15=#d5ccba
[usage_stats]
periodic_usage_stats_permitted=false
periodic_usage_stats_last_sent=0
periodic_usage_stats_uuid_prefix=
[remmina_news]
periodic_news_permitted=false
periodic_rmnews_last_get=0
periodic_rmnews_get_count=1
periodic_rmnews_uuid_prefix=
[remmina]
name=
ignore-tls-errors=1

45
.docker/remmina/run-remmina.sh Executable file
View File

@ -0,0 +1,45 @@
#!/bin/bash
set -u
err() {
echo "ERROR: $*" >&2
exit 1
}
profile_dir="/home/neko/.local/share/remmina"
if [[ -n "$REMMINA_PROFILE" ]]; then
profile=${REMMINA_PROFILE%.remmina}.remmina
file=${profile##/*/}
[[ "$file" = "$profile" ]] && profile="$profile_dir"/"$file"
[[ -f "$profile" ]] || err "Connection profile $profile not found"
echo "Running remmina with connection profile $profile"
exec remmina -c "$profile"
fi
[[ -z "$REMMINA_URL" ]] && err "Neither `REMMINA_PROFILE` nor `REMMINA_URL` found in env vars"
readarray -t arr < <( echo -n "$REMMINA_URL" | perl -pe 's|^(\w+\:\/\/)?(\w*:)?(.+@)?([^:]+)(:\d+)?$|\1\n\2\n\3\n\4\n\5|' )
proto=$(echo "${arr[0]}" | cut -d: -f1)
user=$(echo "${arr[1]}" | cut -d: -f1)
pw=$(echo "${arr[2]}" | cut -d@ -f1)
host="${arr[3]}"
# port=$(echo "${arr[4]}" | cut -d: -f2)
port="${arr[4]}" #keep the :
echo "Parsed url in `REMMINA_URL`: proto:$proto username:$user host:$host port:$port"
[[ "$proto" != "vnc" && "$proto" != "rdp" && "$proto" != "spice" ]] && err "Unsupported protocol $proto in connection url `REMMINA_URL`"
profile="$profile_dir"/"$proto".remmina
if [[ -n "$pw" ]]; then
encpw=$(echo "$pw" | remmina --encrypt-password | grep Encrypted | sed 's/Encrypted password: //')
remmina --set-option password="$encpw" --update-profile "$profile"
else
remmina --set-option password= --update-profile "$profile"
fi
remmina --set-option username="$user" --update-profile "$profile"
remmina --set-option server="$host$port" --update-profile "$profile"
# remmina --set-option window_maximize=1 --update-profile "$profile"
# remmina --set-option scale=1 --update-profile "$profile"
exec remmina -c "$profile"

View File

@ -0,0 +1,33 @@
[remmina]
disablegstvideooverlay=0
disablepasswordstoring=0
sharesmartcard=0
videocodec=0
ssh_tunnel_password=
postcommand=
server=
name=spicedefault
ssh_tunnel_enabled=0
profile-lock=0
enable-autostart=0
imagecompression=0
password=
precommand=
disableclipboard=0
group=
ssh_tunnel_certfile=
protocol=SPICE
enableaudio=1
viewonly=0
ssh_tunnel_server=
ssh_tunnel_loopback=0
ssh_tunnel_auth=0
ignore-tls-errors=1
ssh_tunnel_username=
ssh_tunnel_passphrase=
ssh_tunnel_privatekey=
notes_text=
usetls=0
window_maximize=1
scale=1
viewmode=4

View File

@ -0,0 +1,12 @@
[program:remmina]
environment=HOME="/home/%(ENV_USER)s",USER="%(ENV_USER)s",DISPLAY="%(ENV_DISPLAY)s"
command=/usr/bin/run-remmina.sh
stopsignal=INT
autorestart=true
priority=500
user=%(ENV_USER)s
stdout_logfile=/var/log/neko/remmina.log
stdout_logfile_maxbytes=100MB
stdout_logfile_backups=10
redirect_stderr=true

View File

@ -0,0 +1,49 @@
[remmina]
encodings=
videocodec=0
name=temp eos
ssh_tunnel_server=
ssh_tunnel_privatekey=
password=
quality=0
disablesmoothscrolling=0
enableaudio=1
precommand=
disablegstvideooverlay=0
ssh_tunnel_enabled=0
sharesmartcard=0
imagecompression=0
ssh_tunnel_passphrase=
ssh_tunnel_password=
usetls=0
viewonly=0
disableserverinput=0
depth_profile=0
postcommand=
tightencoding=0
disablepasswordstoring=0
lossy_encoding=0
ignore-tls-errors=1
gvncdebug=0
ssh_tunnel_username=
server=
disableclipboard=0
disableserverbell=0
profile-lock=0
enable-autostart=0
window_maximize=1
scale=1
disableencryption=0
ssh_tunnel_auth=0
group=
ssh_tunnel_loopback=0
showcursor=1
viewmode=4
notes_text=
keymap=
colordepth=32
proxy=
protocol=VNC
ssh_tunnel_certfile=
shared=0
username=

View File

@ -48,7 +48,7 @@ jobs:
needs: [ build-base ]
strategy:
matrix:
tags: [ firefox, chromium, google-chrome, ungoogled-chromium, microsoft-edge, brave, tor-browser, vncviewer, vlc, xfce ]
tags: [ firefox, chromium, google-chrome, ungoogled-chromium, microsoft-edge, brave, tor-browser, vncviewer, remmina, vlc, xfce ]
env:
DOCKER_TAG: ${{ matrix.tags }}
steps:

View File

@ -81,6 +81,8 @@ jobs:
platforms: linux/amd64,linux/arm64
- tag: vncviewer
platforms: linux/amd64,linux/arm64
- tag: remmina
platforms: linux/amd64
- tag: vlc
platforms: linux/amd64,linux/arm64
- tag: xfce