2018-07-26 12:18:52 +00:00
![The Lounge ](https://raw.githubusercontent.com/thelounge/thelounge.github.io/master/assets/logos/logo/TL_Grey%26Yellow_Vertical_logotype_Transparent_Bg/TL_Grey%26Yellow_Vertical_logotype_Transparent_Bg.png )
2016-05-04 12:06:30 +00:00
2023-03-21 09:50:37 +00:00
#### Docker image for The Lounge, a modern web IRC client designed for self-hosting
2018-02-24 08:58:30 +00:00
2018-10-28 17:43:00 +00:00
**[Website](https://thelounge.chat/) • [Docs ](https://thelounge.chat/docs ) • [Demo ](https://demo.thelounge.chat/ )**
2018-07-26 12:18:52 +00:00
2021-05-26 09:32:06 +00:00
[![#thelounge IRC channel on Libera.Chat" ](https://img.shields.io/badge/Libera.Chat-%23thelounge-415364.svg?colorA=ff9e18&style=flat-square )](https://demo.thelounge.chat/) [![Total pulls on Docker ](https://img.shields.io/docker/pulls/thelounge/thelounge.svg?style=flat-square&maxAge=3600 )](https://hub.docker.com/r/thelounge/thelounge/) [![Total stars on Docker ](https://img.shields.io/docker/stars/thelounge/thelounge.svg?colorB=007dc7&style=flat-square&maxAge=3600 )](https://hub.docker.com/r/thelounge/thelounge/)
2018-02-24 08:58:30 +00:00
2018-10-14 13:17:39 +00:00
---
### Overview
2018-02-24 08:58:30 +00:00
2018-10-28 17:43:15 +00:00
- **Modern features brought to IRC.** Push notifications, link previews, new message markers, and more bring IRC to the 21st century.
- **Always connected.** Remains connected to IRC servers while you are offline.
- **Cross platform.** It doesn't matter what OS you use, it just works wherever Node.js runs.
- **Responsive interface.** The client works smoothly on every desktop, smartphone and tablet.
- **Synchronized experience.** Always resume where you left off no matter what device.
2018-02-24 08:58:30 +00:00
To learn more about configuration, usage and features of The Lounge, take a look at [the website ](https://thelounge.chat ).
2016-05-04 12:06:30 +00:00
2023-03-19 17:49:40 +00:00
### Registries
Images are available in the following registries:
- [ghcr.io ](https://github.com/thelounge/thelounge-docker/pkgs/container/thelounge ): `ghcr.io/thelounge/thelounge`
- [DockerHub ](https://hub.docker.com/r/thelounge/thelounge ): `thelounge/thelounge`
2018-10-14 13:17:39 +00:00
### Running a container
2016-05-04 12:06:30 +00:00
2018-04-26 08:46:05 +00:00
One can get started quickly by using the example [`docker-compose.yml` ](https://github.com/thelounge/docker-lounge/blob/master/docker-compose.yml ) file. [What is docker-compose? ](https://docs.docker.com/compose/ )
2018-10-28 17:43:15 +00:00
2016-05-04 12:06:30 +00:00
```sh
$ docker-compose up --detach
```
2018-04-26 08:46:05 +00:00
or starting a container manually:
2016-05-04 12:06:30 +00:00
```
2016-09-26 05:56:10 +00:00
$ docker run --detach \
2018-10-28 17:47:05 +00:00
--name thelounge \
--publish 9000:9000 \
--volume ~/.thelounge:/var/opt/thelounge \
--restart always \
2023-03-19 17:49:40 +00:00
ghcr.io/thelounge/thelounge:latest
2016-05-04 12:06:30 +00:00
```
2019-01-28 19:07:43 +00:00
### Executing commands in the container
Due to the way root permissions are dropped in the container, it's highly recommended to pass the `--user node` argument to any
commands you execute in the container via Docker to ensure that file permissions retain the correct owner, like so:
```
$ docker exec --user node -it [container_name] thelounge add MyUser
```
### Configuring identd
Since root permissions are dropped in the container the default port 113 can not be used as it is within the
priviliged port range. Instead, use a higher port in your The Lounge identd configuration and map it back to 113
on your host system, for example like so:
```
$ docker run --detach \
--name thelounge \
--publish 113:9001 \
--publish 9000:9000 \
--volume ~/.thelounge:/var/opt/thelounge \
--restart always \
2023-03-19 17:49:40 +00:00
ghcr.io/thelounge/thelounge:latest
2019-01-28 19:07:43 +00:00
```
Refer to the [identd / oidentd docs ](https://thelounge.chat/docs/guides/identd-and-oidentd ) for more detailed information.
2018-10-14 13:17:39 +00:00
### Data directory
2018-04-26 08:46:05 +00:00
2018-04-27 08:00:58 +00:00
The Lounge reads and stores all of its configuration, logs and other data at `/var/opt/thelounge` .
2018-04-26 08:46:05 +00:00
2019-01-27 22:10:37 +00:00
By default, The Lounge will run using the `node (1000:1000)` system user in the container, leading to mounted data directories
on the host system being owned by said user. This is customizable by changing the container user (see [Container user (advanced usage) ](#container-user-advanced-usage )).
2018-10-28 17:43:15 +00:00
_You will probably want to persist the data at this location by using [one of the means ](https://docs.docker.com/storage/ ) to do so._
2018-04-26 08:46:05 +00:00
2018-10-14 13:17:39 +00:00
### Adding users
2018-04-25 10:52:39 +00:00
Users can be added as follows:
2018-10-28 17:43:15 +00:00
2018-04-25 10:52:39 +00:00
```sh
2019-01-27 22:10:37 +00:00
$ docker exec --user node -it [container_name] thelounge add [username]
2018-04-25 10:52:39 +00:00
```
2018-10-28 17:43:15 +00:00
_Note: without [persisting data ](#data-directory ), added users will be lost when the container is removed._
2018-04-26 08:46:05 +00:00
2018-10-14 13:17:39 +00:00
### Changing the port that The Lounge will be available on
2016-10-16 13:22:27 +00:00
To change the port which The Lounge will be available on, one will have to
2018-04-25 10:52:39 +00:00
change the host port in the port mapping. To make The Lounge available on e.g. port 5000:
2018-10-28 17:43:15 +00:00
2016-10-16 13:22:27 +00:00
```sh
$ docker run --detach \
2018-10-28 17:47:05 +00:00
--name thelounge \
--publish 5000:9000 \ # Change host port to listen on port 5000
--volume ~/.thelounge:/var/opt/thelounge \
--restart always \
2023-03-19 17:49:40 +00:00
ghcr.io/thelounge/thelounge:latest
2016-10-16 13:22:27 +00:00
```
2019-01-27 22:10:37 +00:00
### Container user (advanced usage)
2016-09-26 05:56:10 +00:00
2019-01-27 22:10:37 +00:00
By default, The Lounge will run using the `node (1000:1000)` user. This is customizable by running the container as a different, non-root, user.
Beware that this may cause permission issues when a container process tries reading from the data disk unless you have manually set the permissions correctly.
2016-09-26 05:56:10 +00:00
2019-01-27 22:10:37 +00:00
Also keep in mind that whenever executing one-off commands in the container you need to explicitly set the correct user.