.gitignore | ||
.gitlab-ci.yml | ||
Dockerfile | ||
nginx.conf | ||
npmextra.json | ||
package-lock.json | ||
package.json | ||
readme.hints.md | ||
readme.md | ||
tsconfig.json | ||
tslint.json |
ht-docker-elk
elastic stack with full basic authentication
Install
To use the ht-docker-elk
in your project, you need Docker installed on your machine. If Docker is not yet installed, follow the installation instructions for your specific operating system on the official Docker website.
Once Docker is up and running, you can proceed with the setup of ht-docker-elk
. Since this project is set to private, and the setup may require access to a proprietary or internal registry, ensure you have the necessary permissions or access tokens to pull the Docker image.
Usage
The ht-docker-elk
project provides an easy and secure way to deploy the Elastic Stack with full basic authentication. This section will cover several use cases and show how to utilize the project effectively in different scenarios, ensuring you can leverage the full suite of features offered by the Elastic Stack, securely and efficiently.
Basic Setup
To get started, you'll need to run the Docker container provided by ht-docker-elk
. This can be achieved by executing the following command in your terminal:
docker run --rm -d --name elstack \
-p 3000:3000 -p 9200:9201 \
-e SSL=true \
-e ELSK_USER="anyuser" \
-e ELSK_PASS="anypass" \
registry.gitlab.com/hosttoday/ht-docker-elk
This command accomplishes the following:
- Starts a Docker container in detached mode (
-d
) and names itelstack
. - Maps port
3000
on the host to port3000
on the container, and port9200
on the host to port9201
on the container. These ports are essential for accessing Kibana and Elasticsearch, respectively. - Enables SSL encryption (
SSL=true
) for secure communication. - Sets up basic authentication with the given username (
ELSK_USER
) and password (ELSK_PASS
).
Advanced Configuration
Assuming more advanced configurations are not omitted from this template due to its conciseness, an advanced use case might involve setting up persistent storage for Elasticsearch or configuring custom Kibana plugins. For persistent storage, you would typically use Docker volumes:
docker run --rm -d --name elstack \
-p 3000:3000 -p 9200:9201 \
-e SSL=true \
-e ELSK_USER="anyuser" \
-e ELSK_PASS="anypass" \
-v my-elasticsearch-data:/usr/share/elasticsearch/data \
registry.gitlab.com/hosttoday/ht-docker-elk
This example attaches a volume named my-elasticsearch-data
to the Elasticsearch data directory inside the container, ensuring that your data persists across container restarts.
For configuring custom Kibana plugins, one might need to build a custom Docker image based on ht-docker-elk
, where the Dockerfile includes steps to install additional plugins. This could look something like this:
FROM registry.gitlab.com/hosttoday/ht-docker-elk
# Example: Installing a custom Kibana plugin
RUN kibana-plugin install <plugin-url>
Monitoring & Management
Utilizing the capabilities of the Elastic Stack, you may want to enable features like monitoring or alerting to keep an eye on the health and performance of your deployment. Enabling X-Pack monitoring within the Elasticsearch and Kibana can provide deep insights into your stack's operation.
Given the project's setup, specific configuration files would need to be adjusted to enable and configure these features, typically by mounting a custom configuration file into the Docker container.
This could be achieved with an additional volume mount in your docker run
command:
-v ./my_custom_kibana.yml:/usr/share/kibana/config/kibana.yml
Here, my_custom_kibana.yml
contains your specific configurations for Kibana, including the setup for monitoring, alerting, and any other X-Pack features you wish to enable.
Conclusion
ht-docker-elk
provides a robust and secure way to deploy the Elastic Stack, catering to both simple and complex use cases with ease. By ensuring secure access through basic authentication and the possibility for SSL encryption, it stands as a solid choice for anyone looking to deploy Elasticsearch, Logstash, and Kibana in a Dockerized environment.
License and Legal Information
This repository contains open-source code that is licensed under the MIT License. A copy of the MIT License can be found in the license file within this repository.
Please note: The MIT License does not grant permission to use the trade names, trademarks, service marks, or product names of the project, except as required for reasonable and customary use in describing the origin of the work and reproducing the content of the NOTICE file.
Trademarks
This project is owned and maintained by Task Venture Capital GmbH. The names and logos associated with Task Venture Capital GmbH and any related products or services are trademarks of Task Venture Capital GmbH and are not included within the scope of the MIT license granted herein. Use of these trademarks must comply with Task Venture Capital GmbH's Trademark Guidelines, and any usage must be approved in writing by Task Venture Capital GmbH.
Company Information
Task Venture Capital GmbH
Registered at District court Bremen HRB 35230 HB, Germany
For any legal inquiries or if you require further information, please contact us via email at hello@task.vc.
By using this repository, you acknowledge that you have read this section, agree to comply with its terms, and understand that the licensing of the code does not imply endorsement by Task Venture Capital GmbH of any derivative works.