alpine镜像安装sshd以进行远程debug
FROM alpine:latest RUN sed -i 's/dl-cdn.alpinelinux.org/mirrors.aliyun.com/g' /etc/apk/repositories RUN apk update && apk add --no-cache openssh-server openssh-sftp-server&& \
sed -i "s/#PermitRootLogin.*/PermitRootLogin yes/g" /etc/ssh/sshd_config && \
ssh-keygen -t rsa -P "" -f /etc/ssh/ssh_host_rsa_key && \
ssh-keygen -t ecdsa -P "" -f /etc/ssh/ssh_host_ecdsa_key && \
ssh-keygen -t ed25519 -P "" -f /etc/ssh/ssh_host_ed25519_key && \
echo "root:admin" | chpasswd EXPOSE 22 CMD ["/usr/sbin/sshd", "-D"]
alpine镜像安装sshd以进行远程debug的更多相关文章
- sh: /etc/init.d/sshd: not found Docker中的Alpine镜像安装sshd无法启动
问题描述 在Alpine镜像中安装了openssh-server和openssh之后,无法执行ssh localhost.发现未启动服务,开启服务时报以下错误 / # ls /etc/init.d/s ...
- 使用 Docker Alpine 镜像安装 nginx
微镜像Alpine,Alpine Linux 是一款独立的⾮商业性的通⽤ Linux 发行版,Alpine Linux 围绕 musl libc 和 busybox 构建,尽管体积很小,Apline ...
- alpine安装sshd/ssh server
1.下载alpine镜像 1 2 3 4 5 6 7 8 9 10 [root@docker43 ~]# docker pull alpine Using default tag: latest Tr ...
- Docker学习笔记:Alpine镜像+Python3安装+http服务器
编写Dockerfile文件使用最新的Alpine镜像并安装Python3环境,如下: 因为python高于3.4则不会默认安装pip,需要手动安装. 试了很多其他办法都没安装上,唯有下载get-pi ...
- Docker Alpine Dockerfile 安装nginx,最小镜像
Docker Alpine Dockerfile 安装nginx,最小镜像 FROM alpine MAINTAINER will ## 将alpine-linux:apk的安装源改为国内镜像 RUN ...
- HBase二次开发之搭建HBase调试环境,如何远程debug HBase源代码
版本 HDP:3.0.1.0 HBase:2.0.0 一.前言 之前的文章也提到过,最近工作中需要对HBase进行二次开发(参照HBase的AES加密方法,为HBase增加SMS4数据加密类型).研究 ...
- 微服务远程Debug,Nocalhost + Rainbond微服务开发第二弹
之前的文章中我们介绍了如何通过 Nocalhost 快速开发 Rainbond 上的微服务,介绍了基本的开发流程. 本文将续接上文继续介绍,使用 Nocalhost 开发配置文件 实现以下内容: 一键 ...
- 在VMware上安装ubuntu,并且SecureCRT远程连接
工具: VMware:VMware-workstation-full_12.5.5.17738.exe Ubuntu镜像:ubuntu-16.04-server-amd64.iso 远程连接工具-- ...
- Docker 实战(二)——centos7镜像安装nginx,将安装nginx的centos容器生成新的镜像,并导出
Docker centos7镜像安装nginx 1.安装docker 使用yum安装docker不再重复:见 Linux常用命令 2.pull centos 1)在docker仓库中搜索centos ...
- (亲测成功)在centos7.5上安装kvm,通过VNC远程连接并创建多台ubuntu虚拟机(ubuntu server版本)
在centos7.5上安装kvm,通过VNC远程连接并创建多台ubuntu虚拟机 前提:服务器端安装桌面版的centos系统 CentOS Linux release 7.5.1804 (Core) ...
随机推荐
- LeetCode-2038 如果相邻两个颜色均相同则删除当前颜色
来源:力扣(LeetCode)链接:https://leetcode-cn.com/problems/remove-colored-pieces-if-both-neighbors-are-the-s ...
- pat乙级 1018 锤子 剪刀 布
#include<stdio.h> #include<stdlib.h> #include<string.h> #include<math.h> int ...
- CRM管理系统界面
- 第五周作业-N67044-张铭扬
1. 搭建chrony服务完成多个主机的时间同步. [root@centos8 ~]# yum -y install chrony [root@centos8 ~]# vim /etc/chrony ...
- MSF后渗透常用命令
一.在meterpreter命令行下常用的操作 ps # 查看当前活跃进程 migrate pid # 将Meterpreter会话移植到进程数位pid的进程中 execute -H -i -f cm ...
- DataGridView添加新一行数据可添加到最后一行或第一行
整体代码如下: using System;using System.Collections.Generic;using System.ComponentModel;using System.Data; ...
- 访问第三方接口带Authorization认证
第一种方式 HttpHeaders httpHeaders = new HttpHeaders(); httpHeaders.add("Authorization", " ...
- Java面向对象之创建对象内存分析
创建对象内存分析 代码 内存分析 属性 属性:字段Field 成员变量 默认初始化: 1.数字: 0 0.0 2.char: u0000 3.boolean:false 4.引用数据类型:null 5 ...
- CSS3图片自适应各种尺寸的屏幕
img { max-width: 100%; height: auto;} 设置最大宽度,高度自适应.
- linux服务器连接数查询
linux服务器环境检查 CPU.内存使用情况 查看系统整体执行情况 命令执行 # 查看当前系统正在执行的进程的相关信息,包括进程ID.内存占用率.CPU占用率等 top # 返回结果 # 14:06 ...