_ [debian] 続々々々・WINE on Docker

wine 1.8.7-2 は 1.6.2-20 と違ってこんな感じで。

FROM debian:stretch

ENV WINEDEBUG -all
ENV LANG ja_JP.UTF-8
ENV LC_ALL ja_JP.UTF-8
ENV XMODIFIERS "@im=uim"
ENV GTK_IM_MODULE uim
ENV QT_IM_MODULE uim
ENV DEBIAN_FRONTEND noninteractive

RUN ln -sf /usr/share/zoneinfo/Asia/Tokyo /etc/localtime \
        && echo "deb http://deb.debian.org/debian stretch contrib" >> /etc/apt/sources.list \
        && echo "deb http://deb.debian.org/debian stretch-updates contrib" >> /etc/apt/sources.list \
        && dpkg --add-architecture i386 \
        && apt-get update \
        && apt-get install -y --no-install-recommends \
                wine \
                wine32 \
                locales \
                fontconfig \
                fonts-ipaexfont-gothic \
                fonts-ipafont-gothic \
                fonts-vlgothic \
                libfontconfig1:i386 \
                playonlinux \
                winetricks \
        && apt-get clean \
        && rm -rf /var/lib/apt/lists/* \
        && echo "en_US.UTF-8 UTF-8" >  /etc/locale.gen \
        && echo "ja_JP.UTF-8 UTF-8" >> /etc/locale.gen \
        && locale-gen

RUN useradd -u 1000 -d /home/wine -m -s /bin/bash wine
ENV HOME /home/wine
WORKDIR /home/wine
USER wine
ENTRYPOINT [ "/usr/bin/wine-stable" ]

これで

docker build -t wine32:1.8.7-2 .

して

docker run --rm --name wine \
    -e DISPLAY=$DISPLAY \
    -v /home/XXXX:/home/wine \
    -v /tmp/.X11-unix:/tmp/.X11-unix \
    -v /var/run/pulse:/var/run/pulse \
    wine32:1.8.7-2 \
    XXXX.exe

やれば動かせた。system-wide PulseAudio のソケットを共有してるので音も問題なし。

_ [debian] ruby on Docker

rbenv も Docker で隔離するように変更した。