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

相关推荐
G_whang4 分钟前
centos7下docker 容器实现redis主从同步
redis·docker·容器
认真学习的小雅兰.5 分钟前
如何在Ubuntu上利用Docker和Cpolar实现Excalidraw公网访问高效绘图——“cpolar内网穿透”
linux·ubuntu·docker
隔着天花板看星星41 分钟前
Spark-Streaming集成Kafka
大数据·分布式·中间件·spark·kafka
the丶only1 小时前
单点登录平台Casdoor搭建与使用,集成gitlab同步创建删除账号
linux·运维·服务器·docker·gitlab
书生-w1 小时前
Docker部署GitLab服务器
服务器·docker·gitlab
塔克拉玛攻城狮1 小时前
私有网盘+在线文档:内网离线搭建NextCloud+OnlyOffice详细指南
docker·在线文档·网盘
ccubee2 小时前
docker 安装 ftp
运维·docker·容器
TsengOnce3 小时前
Docker 安装 禅道-21.2版本-外部数据库模式
运维·docker·容器
无为扫地僧4 小时前
三、ubuntu18.04安装docker
ubuntu·docker
谷莠子9055 小时前
hadoop实验之创业有感
hadoop·docker·团队开发