System info: Ubuntu 22.04.3 LTS + KDE Plasma 5.27 + fcitx5
This bash script can quickly setup qq on linux, but it cannot enable you to type Chinese. I don't know how you can type Chinese in it. If you know, let me know.
| # quick code to setup qq docker | |
| docker run -it --name qq-container ubuntu:22.04 bash | |
| # Update packages and install dependencies | |
| apt update | |
| apt install wget gdebi-core desktop-file-utils libgbm1 libasound2 fonts-wqy-zenhei fonts-wqy-microhei language-pack-zh-hans fcitx5 fcitx5-config-qt fcitx5-chinese-addons | |
| # Download and install QQ | |
| wget https://dldir1.qq.com/qqfile/qq/QQNT/9681283b/linuxqq_3.2.3-20201_amd64.deb | |
| gdebi -n linuxqq_3.2.3-20201_amd64.deb | |
| exit | |
| docker commit qq-container qq-image | |
| xhost +local:docker | |
| # Run QQ in a Docker container with X11 and IBus support (container named qq-container) | |
| docker run -it --name qq-container-p \ | |
| --env="DISPLAY" \ | |
| --volume="/tmp/.X11-unix:/tmp/.X11-unix:rw" \ | |
| -e XMODIFIERS=@im=fcitx5 \ | |
| -e QT_IM_MODULE=fcitx5 \ | |
| -e GTK_IM_MODULE=fcitx5 \ | |
| -e AUDIO_GID=`getent group audio | cut -d: -f3` \ | |
| -e GID=`id -g` \ | |
| -e UID=`id -u` \ | |
| qq-image /usr/bin/qq --no-sandbox | |
| docker restart qq-container-p |