Welcome to Tesla Motors Club
Discuss Tesla's Model S, Model 3, Model X, Model Y, Cybertruck, Roadster and More.
Register

TeslaMate Super Thread

This site may earn commission on affiliate links.
Has anybody had any luck installing this on a Centos 7 linux machine? I have a dedicated server at home and I am adding another linux VM to install this on. I install the Centos and then use yum to install the Docker. But I am unfamiliar with docker and am not positive of the other requirements for TeslaMate to work.

All of the guides I am finding for TeslaMate want you to do this using a paid for cloud server that already has docker up and running. I really don't want to pay for a server when I have a perfectly good one right in my house.

Does anybody know of a good guide on setting this up on a fresh Linux install? I am not dedicated to using CentOS, that is just what I have used in the past and already had the install image. I just need to know what all needs to be installed to make this work.
 
I have Teslamate running inside a docker container on Ubuntu 18.04 Server. Here's how I got it working:

1) Install docker from the official Docker repository:
How to Install Docker On Ubuntu 18.04 {2020 Tutorial}

2) install docker-compose:
Install Docker Compose

3) Create a docker compose YML file that's specific to TeslaMate. It's not strictly necessary to do this but I run other software on my Linux server aside from Teslamate in their own docker containers. This way I can use docker-compose to start and update different groups of software independently from each other.

Create this file in your home directory:

~/teslamate-compose.yml

Put this in teslamate-compose.yml:

version: '3'

services:
teslamate:
image: teslamate/teslamate:latest
restart: unless-stopped
environment:
- DATABASE_USER=teslamate
- DATABASE_PASS=secret
- DATABASE_NAME=teslamate
- DATABASE_HOST=db
- MQTT_HOST=mosquitto
- VIRTUAL_HOST=<static IP address of your Linux server>
- TZ=America/Los_Angeles
ports:
- 4000:4000
cap_drop:
- all
dns:
- <static IP address of your DNS server>

db:
image: postgres:11
restart: always
environment:
- POSTGRES_USER=teslamate
- POSTGRES_PASSWORD=secret
volumes:
- teslamate-db:/var/lib/postgresql/data
dns:
- <static IP address of your DNS server>

grafana:
image: teslamate/grafana:latest
restart: always
environment:
- DATABASE_USER=teslamate
- DATABASE_PASS=secret
- DATABASE_NAME=teslamate
- DATABASE_HOST=db
ports:
- 3000:3000
volumes:
- teslamate-grafana-data:/var/lib/grafana
dns:
- <static IP address of your DNS server>

mosquitto:
image: eclipse-mosquitto:1.6
restart: always
ports:
- 1883:1883
volumes:
- mosquitto-conf:/mosquitto/config
- mosquitto-data:/mosquitto/data
dns:
- <static IP address of your DNS server>

volumes:
teslamate-db:
teslamate-grafana-data:
mosquitto-conf:
mosquitto-data:

4) Download the latest images:
% docker-compose -f teslamate-compose.yml pull

5) Start the containers:
% docker-compose -f teslamate-compose.yml -p teslamate up -d

Let it run for a minute or two, then try loading it in a web browser:
http://<IP_address_of_your_server>:4000

Whenever a new version of Teslamate is released, you can update and restart the images by running steps 4) and 5) again, then clean up/delete the old container images:

% docker image prune
 
Has anybody had any luck installing this on a Centos 7 linux machine? I have a dedicated server at home and I am adding another linux VM to install this on. I install the Centos and then use yum to install the Docker. But I am unfamiliar with docker and am not positive of the other requirements for TeslaMate to work.

All of the guides I am finding for TeslaMate want you to do this using a paid for cloud server that already has docker up and running. I really don't want to pay for a server when I have a perfectly good one right in my house.

Does anybody know of a good guide on setting this up on a fresh Linux install? I am not dedicated to using CentOS, that is just what I have used in the past and already had the install image. I just need to know what all needs to be installed to make this work.
If you have Docker running on any machine, installing and configuring it to run Teslamate is super easy. I'd break up your question into three.

Is your base operating system (CentOS) setup and running?
The CentOS website has these instructions.

Is Docker installed on it?
See the Docker documentation for installation on CentOS.

Is Teslamate installed on Docker?
See andy92782's post right above this one for getting Teslamate installed and running.

If you have specific questions for any of these steps, just post here and we'll try to help.
 
New M3 owner going a bit crazy with my Tesla sheltering in place with me. I’d love to generate more data to track!

I saw this nice YouTube video from Tethla showing how to set up Docker on Vultr server. I’ll probably start with this first and see how things go.
Teslamate Overview and Install
TeslaMate Setup - Tesla Spot

I’m Raspberry Pi 4 curious (newb to pi) - Is it as simple as Raspian - Docker install - Teslamate? I see there may be issues with the Grafana version and the ARM processor.
 
New M3 owner going a bit crazy with my Tesla sheltering in place with me. I’d love to generate more data to track!

I saw this nice YouTube video from Tethla showing how to set up Docker on Vultr server. I’ll probably start with this first and see how things go.
Teslamate Overview and Install
TeslaMate Setup - Tesla Spot

I’m Raspberry Pi 4 curious (newb to pi) - Is it as simple as Raspian - Docker install - Teslamate? I see there may be issues with the Grafana version and the ARM processor.
 
Hey all - just seen these postings about Teslamate and it thrills me that this is possible. I have a 2018 Mac mini that's my 24/7 server, so I'd like to get Docker+Teslamate running on it. Are there any tips for someone who's never done anything like this before? I'm computer/tech savvy (set up HomeBridge etc), but this is a little different and looks a tad complicated.

Thanks in advance!
 
Hey all - just seen these postings about Teslamate and it thrills me that this is possible. I have a 2018 Mac mini that's my 24/7 server, so I'd like to get Docker+Teslamate running on it. Are there any tips for someone who's never done anything like this before? I'm computer/tech savvy (set up HomeBridge etc), but this is a little different and looks a tad complicated.

Thanks in advance!

TBH I forget exactly how I did it (so I have no tips), but mine’s running on the same setup.
 
TBH I forget exactly how I did it (so I have no tips), but mine’s running on the same setup.

No worries. I got it running using the "Simple" setup.

adriankumpf/teslamate

I don't have outside access in a standard web browser or anything, but that's fine. Got it up and running in just a few mins. The longest part was downloading Docker and creating a username! Awesome stuff, though. Since my Mac is up 24/7 it makes the perfect server.
 
  • Like
Reactions: TydalForce
No worries. I got it running using the "Simple" setup.

adriankumpf/teslamate

I don't have outside access in a standard web browser or anything, but that's fine. Got it up and running in just a few mins. The longest part was downloading Docker and creating a username! Awesome stuff, though. Since my Mac is up 24/7 it makes the perfect server.


If you want outside access you can probably open a port through your router, and possibly get a dynamic DNS name - but you’re probably better off not doing that for security reasons.
 
Hey all - just seen these postings about Teslamate and it thrills me that this is possible. I have a 2018 Mac mini that's my 24/7 server, so I'd like to get Docker+Teslamate running on it. Are there any tips for someone who's never done anything like this before? I'm computer/tech savvy (set up HomeBridge etc), but this is a little different and looks a tad complicated.

Thanks in advance!
If you already set up the Docker container configuration of Homebridge, it's that's easy. I love Docker because everything is pre-built, doesn't poison the computer operating system, and is very easy to upgrade the container.

So just install Docker for Mac Community Edition, then follow the TeslaMate installation instructions for Docker. It's literally 2-3 commands in Terminal.
 
If you already set up the Docker container configuration of Homebridge, it's that's easy. I love Docker because everything is pre-built, doesn't poison the computer operating system, and is very easy to upgrade the container.

So just install Docker for Mac Community Edition, then follow the TeslaMate installation instructions for Docker. It's literally 2-3 commands in Terminal.

Yep yep. It is. I got it working in under 60 seconds. I guess my issue was I was trying to get it to work outside of my home network - which is much more tricky and involves FQDN etc. I said meh to that and was up and running locally in quick fashion.
 
I have this running on a CentOS7 VM. Very easy to do just the basic install. I also set it up to be accessible outside, the httpd guide on the repo is decent, but I chose to run it in another docker container rather than running it on the host itself.

To be accessible outside is a great deal more complicated for even the above-average Joe. The simple install is very, very simple.
 
To be accessible outside is a great deal more complicated for even the above-average Joe. The simple install is very, very simple.
Yeah, but it's not that bad.

Easiest way is to buy a domain and use some kind of dyndns setup to keep your Public IP up to date. Port forward is simple enough in the router, and the simple auth and SSL encryption are detailed pretty well in the setup docs.
 
Yeah, but it's not that bad.

Easiest way is to buy a domain and use some kind of dyndns setup to keep your Public IP up to date. Port forward is simple enough in the router, and the simple auth and SSL encryption are detailed pretty well in the setup docs.

Yeah not worth the effort for me. I don’t need the stats while out and about and even if I did I can Remote Desktop and view them there. I can see the appeal for some people though.
 
Yeah not worth the effort for me. I don’t need the stats while out and about and even if I did I can Remote Desktop and view them there. I can see the appeal for some people though.
It's not really about the stats for me, I didn't make grafana available externally, just the TM app. I found myself losing huge chunks of drives due to the sleep cycle settings and the car's inconsistency on whether or not it'll sleep on the first attempt. Now I have the ability to confirm the car is in the correct state before taking a drive. I usually don't even check, but before a long drive that I want to have stats for I make an effort to check.
 
It's not really about the stats for me, I didn't make grafana available externally, just the TM app. I found myself losing huge chunks of drives due to the sleep cycle settings and the car's inconsistency on whether or not it'll sleep on the first attempt. Now I have the ability to confirm the car is in the correct state before taking a drive. I usually don't even check, but before a long drive that I want to have stats for I make an effort to check.

Sure. I can still do that too. I have noticed since getting it up and running that I have periods where the car is “Offline.” Dunno what that mean versus “Asleep.”
 
anyone get this up and running on unraid with a reverse proxy? I tried the docker-compose route, but it can't create the traefik proxy container because it uses the same ports as letsencrypt/nginx. I'm not sure what the config looks like routing through letsencrypt and I changing the ports used for traefik doesn't seem to work
 
anyone get this up and running on unraid with a reverse proxy? I tried the docker-compose route, but it can't create the traefik proxy container because it uses the same ports as letsencrypt/nginx. I'm not sure what the config looks like routing through letsencrypt and I changing the ports used for traefik doesn't seem to work
The docker-compose setup is using traefik to terminate the SSL traffic, as well as serve the challenge file for letsencrypt so it's configured to use both 80/443.

What are you using nginx for? You should probably just add the reverse proxy setup to your nginx conf.