Skip to content

gyl30/tmate-docker-compose

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

setup

  1. pull images

    docker-compose pull
    
  2. generate keys

    $ mkdir -p keys && ./create_keys.sh
    
  3. edit example configuration

    cp ./tmate.conf{.example,}
    

    preserve characterset and lengths of the secret key (except INTERNAL_API_AUTH_TOKEN)

  4. run migrations

    $ docker-compose up -d postgres
    $ docker-compose run master ./bin/tmate console
    
    # run comand twice
    Mix.Task.rerun("ecto.migrate", ["-r", Tmate.Repo, "--migrations-path", "./lib/tmate-0.1.1/priv/repo/migrations"])
    Mix.Task.rerun("ecto.migrate", ["-r", Tmate.Repo, "--migrations-path", "./lib/tmate-0.1.1/priv/repo/migrations"])
    
    # to exit type Ctrl+c followed by `a`
    
  5. launch services

    $ docker-compose up -d
    $ docker-compose logs -f
    
  6. configure tmate on the client: in your ~/.tmux.conf add:

    set -g tmate-server-host <external fqdn>
    set -g tmate-server-port 22
    set -g tmate-server-rsa-fingerprint "<finerprint of generated RSA key>"
    set -g tmate-server-ed25519-fingerprint "<finerprint of generated ED25519 key>"
    

    you can get fingerprints like:

     $ ssh-keygen -l -E sha256 -f  keys/ssh_host_ed25519_key.pub
    

    symlink ~/.tmate.conf to ~/.tmux.conf

About

self-hosted shell sharing based on tmux https://tmate.io

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Shell 100.0%