Sign inSign up

ruslanys/megacmd

By ruslanys

•Updated over 2 years ago

Image
0

8.4K

ruslanys/megacmd repository overview

⁠MegaCMD Docker image

Docker Automated build Docker Pulls

⁠How it works

  1. Run container with Mega CMD server and mounted configuration and data directories.
  2. Obtain session using your login and password.
  3. Execute necessary commands.

⁠Start a Daemon

Because of the issue #623⁠ we need to have a unique UUID at /etc/machine-id. Otherwise, mega-sync will not work.

We have 2 options:

  1. Bypass the machine-id from the host.
docker run -d --name megacmd --restart always \
    -v /etc/machine-id:/etc/machine-id:ro \
    -v /opt/MEGA/config:/root/.megaCmd \
    -v /opt/MEGA/data:/root/MEGA \
    ruslanys/megacmd
  1. Generate a new UUID for the container.
docker run -d --name megacmd --restart always \
    -v /opt/MEGA/config:/root/.megaCmd \
    -v /opt/MEGA/data:/root/MEGA \
    ruslanys/megacmd
docker exec -it megacmd bash
cat /proc/sys/kernel/random/uuid /etc/machine-id

⁠Commands Execution

docker exec -it megacmd mega-login $username $password
docker exec -it megacmd mega-sync /root/MEGA /

Tag summary

Content type

Image

Digest

sha256:b5afd3efb…

Size

98.8 MB

Last updated

over 2 years ago

docker pull ruslanys/megacmd