Skip to content

Commit 48ac75c

Browse files
committed
Discord version 0.0.4
Updated readme a bit Dependencies have been updated accordingly Update script modifies all instances of the version to be built
1 parent df5faf2 commit 48ac75c

File tree

3 files changed

+41
-24
lines changed

3 files changed

+41
-24
lines changed

Dockerfile

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,31 +2,36 @@
22
FROM debian:jessie
33
LABEL maintainer "Christophe Boucharlat <christophe.boucharlat@gmail.com>"
44

5-
# Discord Version 0.0.2
5+
# Discord Version 0.0.4
66

77
RUN apt-get update && apt-get install -y \
88
apt-utils \
99
dbus-x11 \
1010
dunst \
1111
hunspell-en-us \
12-
python3-dbus \
13-
software-properties-common \
1412
libx11-xcb1 \
15-
gconf2 \
16-
libgtk2.0-0 \
17-
libxtst6 \
18-
libnss3 \
1913
libasound2 \
14+
libatomic1 \
15+
libgconf-2-4 \
16+
libnotify4 \
17+
libnspr4 \
18+
libnss3 \
19+
libxss1 \
20+
libxtst6 \
21+
libappindicator1 \
22+
libc++1 \
2023
wget \
2124
--no-install-recommends && \
2225
apt-get clean && \
2326
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
2427

25-
RUN wget https://dl.discordapp.net/apps/linux/0.0.1/discord-0.0.1.tar.gz -O /tmp/discord.tar.gz && \
28+
# download latest version currently 0.0.3
29+
RUN wget http://dl.discordapp.net/apps/linux/0.0.4/discord-0.0.4.tar.gz -O /tmp/discord.tar.gz && \
2630
cd /tmp/ && \
2731
tar xvzf /tmp/discord.tar.gz && \
2832
rm /etc/fonts/conf.d/10-scale-bitmap-fonts.conf && \
29-
fc-cache -fv
33+
fc-cache -fv && \
34+
rm /tmp/discord.tar.gz
3035

3136
ENV QT_XKB_CONFIG_ROOT=/usr/share/X11/xkb
3237

README.md

Lines changed: 24 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -5,33 +5,43 @@ A Docker image that start a fresh discord client.
55
[![Image Layers](https://images.microbadger.com/badges/image/xorilog/discord.svg)](https://microbadger.com/images/xorilog/discord)
66

77

8-
## Usage
8+
## Usage
99
To spawn a new instance of Discord:
1010

1111
```shell
12-
docker run --rm -it --name discord \
13-
-v /tmp/.X11-unix:/tmp/.X11-unix \
14-
-e DISPLAY=unix$DISPLAY \
15-
--device /dev/snd \
16-
-v /etc/localtime:/etc/localtime:ro \
17-
-v <Your_storage_dir>/.config/discord/:/root/.config/discord/ \
18-
xorilog/discord
12+
USER=$(whoami);
13+
xhost + local:discord; #allow discord to connect to X
14+
docker run --rm -it \
15+
--name discord \
16+
--hostname discord \
17+
-v /home/$USER:/home/$USER \
18+
-e DISPLAY=$DISPLAY \
19+
-v /etc/group:/etc/group:ro \
20+
-v /etc/passwd:/etc/passwd:ro \
21+
-v /etc/shadow:/etc/shadow:ro \
22+
-v /tmp/.X11-unix:/tmp/.X11-unix:rw \
23+
-v /etc/localtime:/etc/localtime:ro \
24+
--user $(id -u) \
25+
--device /dev/snd \
26+
discord;
27+
xhost - local:discord; #remove discord from being allowed to connect to X
1928
```
20-
## Issues
21-
* You have to log out Discord to close the docker container.
29+
The previous commands is to be run on a linux machine. But Mac users, I have a special surprise for you. You can also do fun hacks with X11. Details are described [here](https://github.com/docker/docker/issues/8710).
30+
31+
## Issues
32+
* You have to log out Discord or be sure 'minimize to try' is turned off in user settings under linux settings to be able to close discord fully.
2233

2334

2435
## FAQ
2536
### Docker <1.8
2637
Before Docker 1.8 you need to replace `--device /dev/snd` by `-v /dev/snd:/dev/snd --privileged`.
2738

28-
29-
### QXcbConnection: Could not connect to display unix:0
39+
### 'QXcbConnection: Could not connect to display unix:0' or 'No protocol specified'
40+
Some form of
3041
```shell
3142
xhost +
3243
```
33-
do not forget to remove it after start or usage (`xhost -`)
34-
The previous command is to be run on a linux machine. But Mac users, I have a special surprise for you. You can also do fun hacks with X11. Details are described [here](https://github.com/docker/docker/issues/8710).
44+
Before running is required to get this working and remember to remove after finished usage (`xhost -`)
3545

3646

3747
Thanks to [Discord](https://discordapp.com/) for their great app !

update.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,11 @@
11
#!/bin/bash
22

33
# Gather latest version of discord
4-
version=$(curl --head "https://discordapp.com/api/download?platform=linux&format=tar.gz" |grep Location |cut -d '/' -f 6)
4+
version=$(curl --head "https://discordapp.com/api/download?platform=linux&format=tar.gz" |grep -i location |cut -d '/' -f 6)
55

66
sed -i 's/Discord\ Version\ [0-9]*\.[0-9]*\.[0-9]*$/\Discord\ Version\ '$version'/' Dockerfile
7+
sed -i 's/linux\/[0-9]*\.[0-9]*\.[0-9]*\/discord-[0-9]*\.[0-9]*\.[0-9]*/linux\/'$version'\/discord-'$version'/' Dockerfile
8+
79
git commit -am "Discord version $version" -S
810
git tag -am "Discord version $version" $version
911
git push --follow-tags

0 commit comments

Comments
 (0)