The easiest, and most secure way to access and protect all of your infrastructure.
teleport
A Docker Compose configuration for running Teleport - a modern security gateway for remotely accessing Linux servers, Kubernetes clusters, databases, and web applications.
Teleport provides secure access to infrastructure with:
3025: Auth service (API and SSH)3080: Web UI./teleport/config/teleport.yamlCreate the directory structure:
mkdir -p teleport/config teleport/data
Create a basic configuration (teleport/config/teleport.yaml):
version: v3
teleport:
data_dir: /var/lib/teleport
nodename: localhost
auth_service:
enabled: true
listen_addr: 0.0.0.0:3025
proxy_service:
enabled: true
web_listen_addr: 0.0.0.0:3080
public_addr: localhost:3080
ssh_service:
enabled: true
Start Teleport:
docker-compose up -d
Create an admin user:
docker exec -it teleport tctl users add admin --roles=editor,access --logins=root
This will output a signup link - open it in your browser to set your password.
Access the Web UI: Open http://localhost:3080 and log in with your admin credentials.
Create a new user:
docker exec -it teleport tctl users add <username> --roles=editor,access
View cluster status:
docker exec -it teleport tctl status
Reset admin password:
docker exec -it teleport tctl users reset admin
Stop Teleport:
docker-compose down
tsh CLI clientInstall the tsh client on your machine and connect:
tsh login --proxy=localhost:3080 --user=admin
tsh ls # List available servers
tsh ssh root@hostname # SSH into a server
./teleport/config - Configuration files./teleport/data - Certificates, audit logs, and session recordingspublic_addr in config matches how you access Teleportdocker-compose logs -f teleportservices:
teleport:
image: public.ecr.aws/gravitational/teleport-distroless:18.7.2
container_name: teleport
hostname: localhost
ports:
- "3025:3025" # Auth service
- "3080:3080" # Web UI
volumes:
- ./teleport/config:/etc/teleport
- ./teleport/data:/var/lib/teleport
command: start --config=/etc/teleport/teleport.yaml
restart: unless-stopped