Browser
Introduction #
The Demyx Browser is a really helpful tool to visually see the Demyx directory structure. Demyx Browser is powered by Coder’s code-server which is Visual Studio Code accessible through the browser, also works great on the iPad. By having a full fledged IDE, you can install almost all of the extensions, SSH to other servers using the built-in terminal, manipulate anything inside the Demyx container’s volume, and many more. This was built and customized to make it easier to manage Demyx and its data. Users are able to run any of the demyx
commands in the terminal. Aside from running your basic Linux commands, there are useful commands to keep in mind.
Demyx #
In the file tree of the browser, you can see the demyx
container’s file structure. Within it, you can modify an app’s .env
or .yml
files without using demyx config
commands. If you do update any of those files, then please run demyx compose <app> up -d
to recreate the app’s container(s). You are able to run any demyx
commands but updating any of the core .env
values has to be done on the host.
/demyx
├── app
│ ├── code
│ ├── html
│ ├── php
│ ├── traefik
│ └── wp
├── backup
│ └── wp
├── custom
│ ├── example-callback.sh
│ └── example-cron
│ ├── daily.sh
│ ├── five-minute.sh
│ ├── hourly.sh
│ ├── minute.sh
│ ├── six-hour.sh
│ └── weekly.sh
├── log -> /var/log/demyx
└── tmp
App #
The /demyx/app
directory houses all of your app’s .env
and .yml
files. Please do not edit the .yml
files directory from core apps (code/traefik) since it will be automatically regenerated every time the demyx
container starts/restarts. You also have the ability to hook up third party apps into the Demyx network and if the app has a frontend, you can use Traefik labels to expose it.
For this example, we’ll use The Lounge as the third party app. The Lounge is a self hosted web IRC client that’s always connected as long as your server is up and running. First we need to create the directory /demyx/app/thelounge
either through the browser or in the terminal mkdir -p /demyx/app/thelounge
. Then create docker-compose.yml
inside the directory. The example domain irc.domain.tld
can be a subdomain or a top-level domain; having it in a subdirectory requires a bit more Traefik labels that’s not included in this example.
# The Lounge - docker-compose.yml
version: "2.4"
services:
thelounge:
container_name: thelounge
image: thelounge/thelounge
restart: unless-stopped
volumes:
- thelounge:/var/opt/thelounge
labels:
- "traefik.enable=true"
- "traefik.http.routers.thelounge-http.rule=Host(`irc.domain.tld`)"
- "traefik.http.routers.thelounge-http.entrypoints=http"
networks:
- demyx
volumes:
thelounge:
name: thelounge
networks:
demyx:
name: demyx
After you have made the docker-compose.yml
file, you can open the terminal (CTRL + ~
) and enter demyx compose thelounge up -d
to pull the image and then run the container.
Navigate your browser to the domain that you chose and you should see a login screen. To configure The Lounge, please refer to their documentations.
Backup #
The demyx
container has backups enabled by default and executes once daily at midnight. The backup feature doesn’t delete backup directories of apps that’s been deleted so it can get cluttered if you create/delete a bunch of apps. Feel free to delete backups that you don’t need or to free up space either through the browser or terminal.
Cron #
If you need to utilize the demyx
container’s cron feature then rename /demyx/custom/example-cron
to /demyx/custom/cron
in the file tree or terminal. You’ll find premade shell scripts for the available cron intervals. Whatever you put in there, be sure to test your script(s) properly and should return an exit code of 0. If it errors then the entire script will stop executing the rest of the commands.
Logs #
All of Demyx core images have the same directory structure: /demyx
, /etc/demyx
, and /var/log/demyx
. Naturally, the Demyx Browser is also sharing the core log volume from the demyx
container. You can view several logs from multiple core Demyx containers.
Miscellaneous #
ctop – htop
but for containers, executes Docker commands through a GUI.
demyx-extension
– backs up the /home/demyx/.config/code-server/extensions
directory before updating all extensions.
Conclusion #
Need further help or just want to hangout and chat, we have multiple channels for you to visit. To show support for this project, please consider buying coffee.
- Email – [email protected]
- Discussions – https://demyx.sh/discussions
Join us on Discord for latest news, faster support, or just chill.
Support this project by buying coffee (please).