Kafka 笔记 (Non-Root/Container)

目录

  • [1. Kafka 笔记 (Non-Root/Container)](#1. Kafka 笔记 (Non-Root/Container))
    • [1.1. 启动](#1.1. 启动)
    • [1.2. bitnami/kafka](#1.2. bitnami/kafka)
      • [1.2.1. Non-Root Containers](#1.2.1. Non-Root Containers)

1. Kafka 笔记 (Non-Root/Container)

1.1. 启动

Kafka 需要与 ZooKeeper 一起启动:

Kafka with ZooKeeper

Run the following commands in order to start all services in the correct order:

sh 复制代码
# Start the ZooKeeper service
bin/zkServer.sh start

Open another terminal session and run:

sh 复制代码
# Start the Kafka broker service
bin/kafka-server-start.sh config/server.properties

Once all services have successfully launched, you will have a basic Kafka environment running and ready to use.

1.2. bitnami/kafka

1.2.1. Non-Root Containers

Work With Non-Root Containers for Bitnami Applications

这是一种没有 root 用户的容器 (默认没开启)。

开启方法: Using Non-Root Containers as Root Containers

If you wish to run a Bitnami non-root container image as a root container image, you can do so by adding the line user: root right after the image: directive in the container's docker-compose.yml. After making this change, simply restart the container and it will run as the root user with all privileges instead of an unprivileged user.

docker-compose.yml 文件里面的 image: 行下再加一行: user: root

相关推荐
m_136873 小时前
Mac Intel 芯片部署 YOLO(Docker 方式,支持离线打包与 Compose 管理)
yolo·macos·docker
潘晓可4 小时前
Nextcloud 实战:打造属于你的私有云与在线协作平台
docker
衍余未了4 小时前
centos9 docker启动不起来,docker启动发生堵塞问题!
运维·docker·容器
tianyuanwo6 小时前
Docker Registry 实现原理、适用场景、常用操作及搭建详解
运维·docker·容器·registry
专注代码七年9 小时前
Docker 本地开发环境搭建(MySQL5.7 + Redis7 + Nginx + 达梦8)- Windows11 版 2.0
nginx·docker·容器
THMAIL9 小时前
量化基金从小白到大师 - 金融数据获取大全:从免费API到Tick级数据实战指南
人工智能·python·深度学习·算法·机器学习·金融·kafka
帅得不敢出门10 小时前
Docker安装Ubuntu搭建Android SDK编译环境
android·ubuntu·docker
janthinasnail10 小时前
使用Docker安装Stirling-PDF(PDF工具)
docker·pdf
m_1368712 小时前
Mac Intel 芯片 Docker 一键部署 Neo4j 最新版本教程
macos·docker·neo4j
Lin_Aries_042112 小时前
在 CentOS 9 上安装 Docker 的完整指南
linux·docker·centos