Dockerfile文件详细教程
写在前面
Dockerfile是用来构建镜像的,他实际上就是把在linux下的命令操作写到了Dockerfile中,通过Dockerfile去执行设置好的操作命令,保证通过Dockerfile的构建镜像是一致的。
实战分析
该例子来自于 chromium 项目
主要干的事情:
- 来指定用哪个镜像;
- 安装一些编译需要的环境:C++编译环境,Java环境等
# This Dockerfile specifies the recipe for creating an image for the tests
# to run in.
#
# We install as many test dependencies here as we can, because these setup
# steps can be cached. They do *not* run every time we run the build.
# The Docker image is only rebuilt when the Dockerfile (ie. this file)
# changes.# 指定了使用什么镜像 debian
# Base Dockerfile for gRPC dev images
FROM debian:latest# 添加软件源
# Apt source for old Python versions.
RUN echo 'deb http://ppa.launchpad.net/fkrull/deadsnakes/ubuntu trusty main' > /etc/apt/sources.list.d/deadsnakes.list && \apt-key adv --keyserver keyserver.ubuntu.com --recv-keys DB82666C# Apt source for Oracle Java.
RUN echo 'deb http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main' > /etc/apt/sources.list.d/webupd8team-java-trusty.list && \apt-key adv --keyserver keyserver.ubuntu.com --recv-keys EEA14886 && \echo "oracle-java7-installer shared/accepted-oracle-license-v1-1 select true" | debconf-set-selections# Apt source for Mono
RUN echo "deb http://download.mono-project.com/repo/debian wheezy main" | tee /etc/apt/sources.list.d/mono-xamarin.list && \echo "deb http://download.mono-project.com/repo/debian wheezy-libjpeg62-compat main" | tee -a /etc/apt/sources.list.d/mono-xamarin.list && \apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF# Apt source for php
RUN echo "deb http://ppa.launchpad.net/ondrej/php/ubuntu trusty main" | tee /etc/apt/sources.list.d/various-php.list && \apt-key adv --keyserver keyserver.ubuntu.com --recv-keys F4FCBB07# Install dotnet SDK based on https://www.microsoft.com/net/core#debian
# (Ubuntu instructions need apt to support https)
RUN apt-get update && apt-get install -y --force-yes curl libunwind8 gettext && \curl -sSL -o dotnet.tar.gz https://go.microsoft.com/fwlink/?LinkID=847105 && \mkdir -p /opt/dotnet && tar zxf dotnet.tar.gz -C /opt/dotnet && \ln -s /opt/dotnet/dotnet /usr/local/bin# Install dependencies. We start with the basic ones require to build protoc
# and the C++ build
RUN apt-get clean && apt-get update && apt-get install -y --force-yes \autoconf \autotools-dev \build-essential \bzip2 \ccache \curl \gcc \git \libc6 \libc6-dbg \libc6-dev \libgtest-dev \libtool \make \parallel \time \wget \# -- For csharp --mono-devel \referenceassemblies-pcl \nunit \# -- For all Java builds -- \maven \# -- For java_jdk6 -- \# oops! not in jessie. too old? openjdk-6-jdk \# -- For java_jdk7 -- \openjdk-7-jdk \# -- For java_oracle7 -- \oracle-java7-installer \# -- For python / python_cpp -- \python-setuptools \python-pip \python-dev \python2.6-dev \python3.3-dev \python3.4-dev \# -- For Ruby --ruby \# -- For C++ benchmarks --cmake \# -- For PHP --php5.6 \php5.6-dev \php5.6-xml \php7.0 \php7.0-dev \php7.0-xml \phpunit \valgrind \libxml2-dev \&& apt-get clean##################
# C# dependenciesRUN wget www.nuget.org/NuGet.exe -O /usr/local/bin/nuget.exe##################
# Python dependencies# These packages exist in apt-get, but their versions are too old, so we have
# to get updates from pip.RUN pip install pip --upgrade
RUN pip install virtualenv tox yattag##################
# Ruby dependencies# Install rvm
RUN gpg --keyserver hkp://keys.gnupg.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3
RUN \curl -sSL https://get.rvm.io | bash -s stable# Install Ruby 2.1, Ruby 2.2 and JRuby 1.7
RUN /bin/bash -l -c "rvm install ruby-2.1"
RUN /bin/bash -l -c "rvm install ruby-2.2"
RUN /bin/bash -l -c "rvm install jruby-1.7"
RUN /bin/bash -l -c "echo 'gem: --no-ri --no-rdoc' > ~/.gemrc"
RUN /bin/bash -l -c "echo 'export PATH=/usr/local/rvm/bin:$PATH' >> ~/.bashrc"
RUN /bin/bash -l -c "gem install bundler --no-ri --no-rdoc"##################
# Java dependencies# This step requires compiling protoc. :(ENV MAVEN_REPO /var/maven_local_repository
ENV MVN mvn --batch-modeRUN cd /tmp && \git clone https://github.com/google/protobuf.git && \cd protobuf && \git reset --hard 129a6e2aca95dcfb6c3e717d7b9cca1f104fde39 && \./autogen.sh && \./configure && \make -j4 && \cd java && \$MVN install dependency:go-offline -Dmaven.repo.local=$MAVEN_REPO && \cd ../javanano && \$MVN install dependency:go-offline -Dmaven.repo.local=$MAVEN_REPO##################
# PHP dependencies.
RUN wget http://am1.php.net/get/php-5.5.38.tar.bz2/from/this/mirror
RUN mv mirror php-5.5.38.tar.bz2
RUN tar -xvf php-5.5.38.tar.bz2
RUN cd php-5.5.38 && ./configure --enable-maintainer-zts --prefix=/usr/local/php-5.5-zts && \make && make install && cd ..
RUN cd php-5.5.38 && make clean && ./configure --enable-bcmath --prefix=/usr/local/php-5.5 && \make && make install && cd ..RUN wget http://am1.php.net/get/php-5.6.30.tar.bz2/from/this/mirror
RUN mv mirror php-5.6.30.tar.bz2
RUN tar -xvf php-5.6.30.tar.bz2
RUN cd php-5.6.30 && ./configure --enable-maintainer-zts --prefix=/usr/local/php-5.6-zts && \make && make install && cd ..
RUN cd php-5.6.30 && make clean && ./configure --enable-bcmath --prefix=/usr/local/php-5.6 && \make && make install && cd ..RUN wget http://am1.php.net/get/php-7.0.18.tar.bz2/from/this/mirror
RUN mv mirror php-7.0.18.tar.bz2
RUN tar -xvf php-7.0.18.tar.bz2
RUN cd php-7.0.18 && ./configure --enable-maintainer-zts --prefix=/usr/local/php-7.0-zts && \make && make install && cd ..
RUN cd php-7.0.18 && make clean && ./configure --enable-bcmath --prefix=/usr/local/php-7.0 && \make && make install && cd ..RUN wget http://am1.php.net/get/php-7.1.4.tar.bz2/from/this/mirror
RUN mv mirror php-7.1.4.tar.bz2
RUN tar -xvf php-7.1.4.tar.bz2
RUN cd php-7.1.4 && ./configure --enable-maintainer-zts --prefix=/usr/local/php-7.1-zts && \make && make install && cd ..
RUN cd php-7.1.4 && make clean && ./configure --enable-bcmath --prefix=/usr/local/php-7.1 && \make && make install && cd ..RUN php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
RUN php composer-setup.php
RUN mv composer.phar /usr/bin/composer
RUN php -r "unlink('composer-setup.php');"
RUN composer config -g -- disable-tls true
RUN composer config -g -- secure-http false
RUN cd /tmp && \rm -rf protobuf && \git clone https://github.com/google/protobuf.git && \cd protobuf && \git reset --hard 49b44bff2b6257a119f9c6a342d6151c736586b8 && \cd php && \ln -sfn /usr/local/php-5.5/bin/php /usr/bin/php && \ln -sfn /usr/local/php-5.5/bin/php-config /usr/bin/php-config && \ln -sfn /usr/local/php-5.5/bin/phpize /usr/bin/phpize && \composer install && \mv vendor /usr/local/vendor-5.5 && \ln -sfn /usr/local/php-5.6/bin/php /usr/bin/php && \ln -sfn /usr/local/php-5.6/bin/php-config /usr/bin/php-config && \ln -sfn /usr/local/php-5.6/bin/phpize /usr/bin/phpize && \composer install && \mv vendor /usr/local/vendor-5.6 && \ln -sfn /usr/local/php-7.0/bin/php /usr/bin/php && \ln -sfn /usr/local/php-7.0/bin/php-config /usr/bin/php-config && \ln -sfn /usr/local/php-7.0/bin/phpize /usr/bin/phpize && \composer install && \mv vendor /usr/local/vendor-7.0 && \ln -sfn /usr/local/php-7.1/bin/php /usr/bin/php && \ln -sfn /usr/local/php-7.1/bin/php-config /usr/bin/php-config && \ln -sfn /usr/local/php-7.1/bin/phpize /usr/bin/phpize && \composer install && \mv vendor /usr/local/vendor-7.1##################
# Go dependencies.
RUN apt-get install -y \# -- For go -- \golang##################
# Javascript dependencies.
RUN apt-get install -y \# -- For javascript -- \npm##################
# Python 3.5 3.6 dependencies.
RUN apt-get clean && apt-get update && apt-get install -y --force-yes \python3.5-dev \python3.6-dev \&& apt-get clean# On Debian/Ubuntu, nodejs binary is named 'nodejs' because the name 'node'
# is taken by another legacy binary. We don't have that legacy binary and
# npm expects the binary to be named 'node', so we just create a symbol
# link here.
RUN ln -s `which nodejs` /usr/bin/node##################
# Prepare ccacheRUN ln -s /usr/bin/ccache /usr/local/bin/gcc
RUN ln -s /usr/bin/ccache /usr/local/bin/g++
RUN ln -s /usr/bin/ccache /usr/local/bin/cc
RUN ln -s /usr/bin/ccache /usr/local/bin/c++
RUN ln -s /usr/bin/ccache /usr/local/bin/clang
RUN ln -s /usr/bin/ccache /usr/local/bin/clang++# Define the default command.
CMD ["bash"]
常见命令解释
FROM 指定镜像源
FROM ubuntu
# Base Dockerfile for gRPC dev images
FROM debian:latest
网站:http://hub.docker.com
FROM命令是用来指定你需要用哪个镜像作为基础镜像进行构建,一般来说Dockerfile的第一行都会先指定一个镜像,官方仓库中有很多镜像,可以通过http://hub.docker.com进行搜索,建议尽量使用官方镜像作为基础镜像,因为官方镜像都是精简过的稳定版。
RUN 执行linux命令
比如我们需要安装vim
写法1:
RUN apt-get update -y
RUN apt-get install -y vim
RUN是用来执行linux命令的指令,例如ubuntu系统下,需要更新软件包list,就需要执行apt-get update,之后会跟着执行apt-get install
写法2:
RUN apt-get update -y \&& apt-get install -y vim
参考例子:
# Apt source for old Python versions.
RUN echo 'deb http://ppa.launchpad.net/fkrull/deadsnakes/ubuntu trusty main' > /etc/apt/sources.list.d/deadsnakes.list && \apt-key adv --keyserver keyserver.ubuntu.com --recv-keys DB82666C# Apt source for Oracle Java.
RUN echo 'deb http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main' > /etc/apt/sources.list.d/webupd8team-java-trusty.list && \apt-key adv --keyserver keyserver.ubuntu.com --recv-keys EEA14886 && \echo "oracle-java7-installer shared/accepted-oracle-license-v1-1 select true" | debconf-set-selections# Apt source for Mono
RUN echo "deb http://download.mono-project.com/repo/debian wheezy main" | tee /etc/apt/sources.list.d/mono-xamarin.list && \echo "deb http://download.mono-project.com/repo/debian wheezy-libjpeg62-compat main" | tee -a /etc/apt/sources.list.d/mono-xamarin.list && \apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF# Apt source for php
RUN echo "deb http://ppa.launchpad.net/ondrej/php/ubuntu trusty main" | tee /etc/apt/sources.list.d/various-php.list && \apt-key adv --keyserver keyserver.ubuntu.com --recv-keys F4FCBB07# Install dotnet SDK based on https://www.microsoft.com/net/core#debian
# (Ubuntu instructions need apt to support https)
RUN apt-get update && apt-get install -y --force-yes curl libunwind8 gettext && \curl -sSL -o dotnet.tar.gz https://go.microsoft.com/fwlink/?LinkID=847105 && \mkdir -p /opt/dotnet && tar zxf dotnet.tar.gz -C /opt/dotnet && \ln -s /opt/dotnet/dotnet /usr/local/bin# Install dependencies. We start with the basic ones require to build protoc
# and the C++ build
RUN apt-get clean && apt-get update && apt-get install -y --force-yes \autoconf \autotools-dev \build-essential \bzip2 \ccache \curl \gcc \git \libc6 \libc6-dbg \libc6-dev \libgtest-dev \libtool \make \parallel \time \wget \# -- For csharp --mono-devel \referenceassemblies-pcl \nunit \# -- For all Java builds -- \maven \# -- For java_jdk6 -- \# oops! not in jessie. too old? openjdk-6-jdk \# -- For java_jdk7 -- \openjdk-7-jdk \# -- For java_oracle7 -- \oracle-java7-installer \# -- For python / python_cpp -- \python-setuptools \python-pip \python-dev \python2.6-dev \python3.3-dev \python3.4-dev \# -- For Ruby --ruby \# -- For C++ benchmarks --cmake \# -- For PHP --php5.6 \php5.6-dev \php5.6-xml \php7.0 \php7.0-dev \php7.0-xml \phpunit \valgrind \libxml2-dev \&& apt-get clean##################
# C# dependenciesRUN wget www.nuget.org/NuGet.exe -O /usr/local/bin/nuget.exe##################
# Python dependencies# These packages exist in apt-get, but their versions are too old, so we have
# to get updates from pip.RUN pip install pip --upgrade
RUN pip install virtualenv tox yattag##################
# Ruby dependencies# Install rvm
RUN gpg --keyserver hkp://keys.gnupg.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3
RUN \curl -sSL https://get.rvm.io | bash -s stable# Install Ruby 2.1, Ruby 2.2 and JRuby 1.7
RUN /bin/bash -l -c "rvm install ruby-2.1"
RUN /bin/bash -l -c "rvm install ruby-2.2"
RUN /bin/bash -l -c "rvm install jruby-1.7"
RUN /bin/bash -l -c "echo 'gem: --no-ri --no-rdoc' > ~/.gemrc"
RUN /bin/bash -l -c "echo 'export PATH=/usr/local/rvm/bin:$PATH' >> ~/.bashrc"
RUN /bin/bash -l -c "gem install bundler --no-ri --no-rdoc"
USER 指定当前用户
USER root
USER username
EXPOSE 暴露端口
声明端口,作用是帮助镜像使用者理解这个镜像服务的守护端口,以方便配置映射。在运行时使用随机端口映射时,也就是 docker run -P时,会自动随机映射EXPOSE的端口。
EXPOSE <端口1> [<端口2>...]
在 Dockerfile 中写入这样的声明有两个好处:
- 一个是帮助镜像使用者理解这个镜像服务的守护端口,以方便配置映射;
- 另一个用处则是在运行时使用随机端口映射时,也就是 docker run -P 时,会自动随机映射 EXPOSE 的端口。
例子:
EXPOSE 端口号
EXPOSE 端口号/协议
默认协议是 TCP
EXPOSE 80/tcp
EXPOSE 80/udp
FROM nginx
EXPOSE 80
在docker-compose中
通常在docker-compose中,会通过ports来映射并暴露端口,docker-compose用法如下:
ports:- "8001:80"
相关文章:
Dockerfile文件详细教程
写在前面 Dockerfile是用来构建镜像的,他实际上就是把在linux下的命令操作写到了Dockerfile中,通过Dockerfile去执行设置好的操作命令,保证通过Dockerfile的构建镜像是一致的。 实战分析 该例子来自于 chromium 项目 主要干的事情…...
机器学习-模型评估与选择
文章目录 评估方法留出法交叉验证自助法 性能的衡量回归问题分类问题查准率、查全率与F1ROC与AUC 在机器学习中,我们通常面临两个主要问题:欠拟合和过拟合。欠拟合指模型无法在训练数据上获得足够低的误差,通常是因为模型太简单,无…...
分享一下办公自动化常用的思想
目录 网页获取数据需求①大体思路:PythonseleniumXpath 网页获取数据需求②大体思路:requests爬虫 批量生成需求①文件的移动、重命名②word、Excel批量生成 匹配需求 网页获取数据需求① 大体思路:PythonseleniumXpath 我们在利用Python做…...
mac vscode 使用 clangd
C 的智能提示 IntelliSense 非常不准,我们可以使用 clangd clangd 缺点就是配置繁琐,优点就是跳转和提示代码精准 开启 clangd 之后会提示你关闭 IntelliSense 1、安装插件 clangd 搜索第一个下载多的就是 2、配置 clangd 可执行程序路径 clangd 插…...
DSI及DPHY的学习
DSI的物理层PHY只能是DPHY 本节讲述的DSI是V1.02.00---2010.6.28 从DSI V1.02开始DSI支持图像数据包RGB和YCbCr的传输,在此版本之前只支持RGB传输。 本节内容与CSICDPHY相同时 请参考: CSI2与CDPHY学习-CSDN博客 同时本节会做一些与CSICDPHY的比较 …...
环形链表(C++解法)
题目 给你一个链表的头节点 head ,判断链表中是否有环。 如果链表中有某个节点,可以通过连续跟踪 next 指针再次到达,则链表中存在环。 为了表示给定链表中的环,评测系统内部使用整数 pos 来表示链表尾连接到链表中的位置&#…...
星闪技术 NearLink 一种专门用于短距离数据传输的新型无线通信技术
本心、输入输出、结果 文章目录 星闪技术 NearLink 一种专门用于短距离数据传输的新型无线通信技术前言星闪技术 NearLink 的诞生背景星闪技术 NearLink 简介星闪技术 NearLink 技术是一种蓝牙技术吗星闪技术 NearLink 优势星闪技术 NearLink 应用前景弘扬爱国精神星闪技术 Nea…...
【Python机器学习】零基础掌握RandomForestRegressor集成学习
如何预测房价是不是一直困扰着大家?特别是在房地产市场波动不定的情况下,这样的预测可以说是切实需要。 要解决这个问题,一个可行的方法是利用历史房价数据和房屋的各种属性(如面积、楼层、地理位置等)进行分析。通过这些数据,可以用一个模型来预测未来房价。 假设有以…...
FreeRTOS深入教程(任务创建的深入和任务调度机制分析)
文章目录 前言一、深入理解任务的创建二、任务的调度机制1.FreeRTOS中任务调度的策略2.FreeRTOS任务调度策略实现的核心3.FreeRTOS内部链表源码解析4.如何通过就绪链表管理任务的执行顺序 三、一个任务能够运行多久1.高优先级任务可抢占低优先级任务一直运行2.相同优先级的任务…...
Megatron-LM GPT 源码分析(一) Tensor Parallel分析
引言 本文基于开源代码 GitHub - NVIDIA/Megatron-LM: Ongoing research training transformer models at scale ,通过GPT的模型运行示例,从三个维度 - 模型结构、代码运行、代码逻辑说明 对其源码做深入的分析。 Tensor Parallel源码分析...
分类预测 | MATLAB实现SSA-CNN-GRU麻雀算法优化卷积门控循环单元数据分类预测
分类预测 | MATLAB实现SSA-CNN-GRU麻雀算法优化卷积门控循环单元数据分类预测 目录 分类预测 | MATLAB实现SSA-CNN-GRU麻雀算法优化卷积门控循环单元数据分类预测分类效果基本描述程序设计参考资料 分类效果 基本描述 1.MATLAB实现SSA-CNN-GRU麻雀算法优化卷积门控循环单元数据…...
婚礼的魅力
昨日有幸被邀请去当伴郎,虽然是替补,即别人鸽了,过去救急,但总归是去起作用。 婚礼的魅力,感受到了,满满的仪式感,紧凑的流程,还有不断的拍照,做视频,留下美好…...
【计算机网络笔记】DNS报文格式
DNS 提供域名到主机IP地址的映射 域名服务的三大要素: 域(Domain)和域名(Domain name): 域指由地 理位置或业务类型而联系在一起的一组计算机构 成。 主机:由域名来标识。域名是由字符和(或&a…...
10月28日
...
【性能测试】初识 Jmeter 中的 BeanShell
初识 Jmeter 中的 BeanShell 1.简介1.1 应用场景1.2 BeanShell 类型 2.常用内置变量2.1 log 日志模块2.2 vars 模块2.3 props 模块2.4 prev 模块 3.常见应用场景3.1 Java 文件处理3.2 导入外部 jar 包 BeanShell 是一个小型嵌入式 Java 源代码解释器,完全兼容 Java …...
Rust实现基于Tokio的限制内存占用的channel
Rust实现基于Tokio的限制内存占用的channel 简介 本文介绍如何基于tokio的channel实现一个限制内存占用的channel。 Tokio提供了多种协程间同步的接口,用于在不同的协程中同步数据。 常用的channel有两种:bounded和unbounded,其中ubbounded的channel可…...
【C++】C++入门(上)--命名空间 输入输出 缺省参数 函数重载
目录 一 命名空间 1 命名空间的定义 2 命名空间的使用 二 C输入和输出 1 输出 2 输入 三 缺省参数 1 缺省参数概念 2 缺省参数分类 (1) 全缺省参数 (2)半缺省参数 四 函数重载 1 函数重载概念 2 分类 1 参数类型不同 2 参数个数不同 3 参数类型顺序不同 3 C为什…...
设计模式:原型模式(C#、JAVA、JavaScript、C++、Python、Go、PHP)
上一篇《访问者模式》 下一篇《享元模式》 简介: 原型模式,它是一种创建型设计模式,它允许通过复制原型对象来创建新的对象,而无需知道创建的细节。其工作原…...
SpringMVC 资源状态转移RESTful
文章目录 1、RESTful简介a>资源b>资源的表述c>状态转移 2、RESTful的实现HiddenHttpMethodFilterRESTful案例 1、RESTful简介 REST:Representational State Transfer,表现层资源状态转移。 a>资源 资源是一种看待服务器的方式,…...
verilog vscode linux
安装 vscode 插件 插件:Verilog-HDL/SystemVerilog/Bluespec SystemVerilog 功能:.xdc .ucf .v 等代码高亮、代码格式化、语法检查(Linting)、光标放到变量上提示变量的信息等 关于其他语言的依赖工具等信息查看插件说明 代码对齐…...
OpenLayers 可视化之热力图
注:当前使用的是 ol 5.3.0 版本,天地图使用的key请到天地图官网申请,并替换为自己的key 热力图(Heatmap)又叫热点图,是一种通过特殊高亮显示事物密度分布、变化趋势的数据可视化技术。采用颜色的深浅来显示…...
Vue记事本应用实现教程
文章目录 1. 项目介绍2. 开发环境准备3. 设计应用界面4. 创建Vue实例和数据模型5. 实现记事本功能5.1 添加新记事项5.2 删除记事项5.3 清空所有记事 6. 添加样式7. 功能扩展:显示创建时间8. 功能扩展:记事项搜索9. 完整代码10. Vue知识点解析10.1 数据绑…...
Lombok 的 @Data 注解失效,未生成 getter/setter 方法引发的HTTP 406 错误
HTTP 状态码 406 (Not Acceptable) 和 500 (Internal Server Error) 是两类完全不同的错误,它们的含义、原因和解决方法都有显著区别。以下是详细对比: 1. HTTP 406 (Not Acceptable) 含义: 客户端请求的内容类型与服务器支持的内容类型不匹…...
51c自动驾驶~合集58
我自己的原文哦~ https://blog.51cto.com/whaosoft/13967107 #CCA-Attention 全局池化局部保留,CCA-Attention为LLM长文本建模带来突破性进展 琶洲实验室、华南理工大学联合推出关键上下文感知注意力机制(CCA-Attention),…...
sqlserver 根据指定字符 解析拼接字符串
DECLARE LotNo NVARCHAR(50)A,B,C DECLARE xml XML ( SELECT <x> REPLACE(LotNo, ,, </x><x>) </x> ) DECLARE ErrorCode NVARCHAR(50) -- 提取 XML 中的值 SELECT value x.value(., VARCHAR(MAX))…...
ardupilot 开发环境eclipse 中import 缺少C++
目录 文章目录 目录摘要1.修复过程摘要 本节主要解决ardupilot 开发环境eclipse 中import 缺少C++,无法导入ardupilot代码,会引起查看不方便的问题。如下图所示 1.修复过程 0.安装ubuntu 软件中自带的eclipse 1.打开eclipse—Help—install new software 2.在 Work with中…...
k8s业务程序联调工具-KtConnect
概述 原理 工具作用是建立了一个从本地到集群的单向VPN,根据VPN原理,打通两个内网必然需要借助一个公共中继节点,ktconnect工具巧妙的利用k8s原生的portforward能力,简化了建立连接的过程,apiserver间接起到了中继节…...
IT供电系统绝缘监测及故障定位解决方案
随着新能源的快速发展,光伏电站、储能系统及充电设备已广泛应用于现代能源网络。在光伏领域,IT供电系统凭借其持续供电性好、安全性高等优势成为光伏首选,但在长期运行中,例如老化、潮湿、隐裂、机械损伤等问题会影响光伏板绝缘层…...
html-<abbr> 缩写或首字母缩略词
定义与作用 <abbr> 标签用于表示缩写或首字母缩略词,它可以帮助用户更好地理解缩写的含义,尤其是对于那些不熟悉该缩写的用户。 title 属性的内容提供了缩写的详细说明。当用户将鼠标悬停在缩写上时,会显示一个提示框。 示例&#x…...
初探Service服务发现机制
1.Service简介 Service是将运行在一组Pod上的应用程序发布为网络服务的抽象方法。 主要功能:服务发现和负载均衡。 Service类型的包括ClusterIP类型、NodePort类型、LoadBalancer类型、ExternalName类型 2.Endpoints简介 Endpoints是一种Kubernetes资源…...
