Docker
Run your container anywhere.
While using Docker is not necessary for this project, it simplifies deployment for a variety of environments. The pre-built Docker images are available on the GitHub Container Registry.
Tags
Docker Tags | Description |
---|---|
ghcr.io/medama-io/medama:latest | Latest stable release. |
ghcr.io/medama-io/medama:edge | Latest development build. |
ghcr.io/medama-io/medama:<version> | Specific version. |
ghcr.io/medama-io/medama:sha-<commit-sha> | Specific commit (short format). |
Setup
Run Container
Docker Run
Docker Run
Create a Docker volume to store the database files:
Then run the container with the following command:
/app/data
directory within the containers. You can create a volume or use bind mounts to redirect where data is stored on your local system. Learn more about Docker volumes here.Docker Compose
Docker Compose
If you prefer using Docker Compose, create a docker-compose.yml
file with the following content:
Then start the container with the following command:
Build from source
Build from source
If you want to build from source using Docker, clone the medama-io/medama
repository and build the image from there:
Configure Deployment
Before you can start collecting data, you may want to configure your analytics instance to suit your needs. It is recommended to refer to the Environment Variables configuration page.
These variables can be set using the -e
flag in docker run
or the environment
property in Docker Compose.
Afterwards, ensure your analytics instance is configured to be accessible from the internet. You must also set up SSL certificates for your deployment.
Add Your First Website
Success! You can now add your first website to the analytics instance by visiting the web interface at http://localhost:8080
or the publicly accessible hostname for your deployment.
The default login credentials are:
- Username:
admin
- Password:
CHANGE_ME_ON_FIRST_LOGIN
localhost
or a HTTPS
connection. Logging in via an unencrypted HTTP
connection will not work. If your hosting provider does not automatically provision SSL certificates to your machine, you may want to use the automatic SSL setup feature.
Embed Tracking Snippet
Then, embed the following HTML tracking snippet in the <head>
element of your website to start collecting data: