当前位置:网站首页>Earthly container image construction tool -- the road to dream
Earthly container image construction tool -- the road to dream
2022-06-24 08:44:00 【The road to dream】

Makefile + Dockerfile = Earthfile
In the use of Earthly Currently, when building images, it is strongly dependent on buildkit,Earthly adopt buildkit Supported some Dockerfile Extended syntax for , At the same time Dockerfile And Makefile Integrate , Make multi platform construction and coding Dockerfile Make it easier ; Use Earthly It can be completed more conveniently Dockerfile Code reuse and more friendly CI Automatic integration .
# install
sudo /bin/sh -c 'wget https://github.com/earthly/earthly/releases/latest/download/earthly-linux-amd64 -O /usr/local/bin/earthly && chmod +x /usr/local/bin/earthly && /usr/local/bin/earthly bootstrap --with-autocomplete'
After installation Earthly Will start a buildkitd Containers : earthly-buildkitd
# Example
cat main.go
package main
import "fmt"
func main() {
fmt.Println("hello world")
}
cat Earthlyfile
FROM golang:1.17-alpine
WORKDIR /go-example
build:
COPY main.go .
RUN go build -o build/go-example main.go
SAVE ARTIFACT build/go-example /go-example AS LOCAL build/go-example
docker:
COPY +build/go-example .
ENTRYPOINT ["/go-example/go-example"]
SAVE IMAGE go-example:latest
# Directory structure
~/t/earthlytest *** tree
.
├── Earthfile
└── main.go
0 directories, 2 files
# adopt earthly Build
~/t/earthlytest *** earthly +docker
I'll summarize later
More powerful container image building tools Earthly
GitHub - earthly/earthly: The effortless CI/CD framework that runs anywhere
边栏推荐
- QT writing security video monitoring system 36 onvif continuous movement
- js中通过key查找和更新对象中指定值的方法
- Distributed | how to make "secret calls" with dble
- Xiaohei ai4code code baseline nibble 1
- 获取屏幕宽高工具类
- MySQL 因字符集问题插入中文数据时提示代码 :1366
- Shell basic operators -- relational operators
- Vscode install the remote -wsl plug-in to connect to the local WSL
- pymysql 向MySQL 插入数据无故报错
- Picture tools
猜你喜欢

数据库迁移从PostgreSQL迁移到 MYSQL

【关于运维和网工的差别,一文说透】

ZUCC_ Principles of compiling language and compilation_ Experiment 05 regular expression, finite automata, lexical analysis

关于ETL看这篇文章就够了,三分钟让你明白什么是ETL
![[explain the difference between operation and maintenance and network engineering]](/img/2b/945f468588e729336e2e973e777623.jpg)
[explain the difference between operation and maintenance and network engineering]

表单图片上传在Chorme中无法查看请求体的二进制图片信息

Xiaohei ai4code code baseline nibble 1

【团队管理】测试团队绩效管理的25点小建议

Markdown to realize text link jump

關於ETL看這篇文章就够了,三分鐘讓你明白什麼是ETL
随机推荐
RuntimeError: Missing dependencies:XXX
Maya re deployment
Rust procedure macro simply imitates Lombok function
为什么ping不通,而traceroute却可以通
QPS, TPS, concurrent users, throughput relationship
Centos7安装jdk8以及mysql5.7以及Navicat连接虚拟机mysql的出错以及解决方法(附mysql下载出错解决办法)
ZUCC_ Principles of compiling language and compilation_ Experiment 05 regular expression, finite automata, lexical analysis
"Wechat cloud hosting" first practical battle | introduction to minimalist demo
Centos7 installation of jdk8, mysql5.7 and Navicat connection to virtual machine MySQL and solutions (solutions to MySQL download errors are attached)
Opencv get (propid) common values
Detailed explanation of Base64 coding and its variants (to solve the problem that the plus sign changes into a space in the URL)
liunx服务器 telnet 带用户名 端口登陆方法
JUC personal simple notes
Easydss anonymous live channel data volume instability optimization scheme sharing
解析互联网广告术语 CPM、CPC、CPA、CPS、CPL、CPR 是什么意思
Variable declaration and some special variables in shell
"Adobe international certification" Photoshop software, about drawing tutorial?
Several ways you can't move zero (sequel)
2021-06-24: find the length of the longest non repeating character substring in a string.
Qt源码分析--QObject(2)