Service
An abstract way to expose an application running on a set of Pods as a network service.
With Kubernetes you don't need to modify your application to use an unfamiliar service discovery mechanism. Kubernetes gives Pods their own IP addresses and a single DNS name for a set of Pods, and can load-balance across them.
根據官方定義,Service 是 k8s 內定義的抽象化物件(object),看一下詳細說明:
Service(k8s 官網)
Kubernetes Service 概念詳解
Kubernetes Service 取路徑差異
Container
容器簡介:什麼是容器?(google)
重點節錄
容器提供一種邏輯封裝機制,能夠將應用程式從實際執行所在環境抽取出來。無論目標環境是私人資料中心、公用雲端還是開發人員的個人筆記型電腦,這種分離的方式都可以==輕鬆、一致地部署==容器型應用程式。容器化提供了一種俐落的==分工模式==,當==開發人員專注於應用程式邏輯與依附元件==時,==IT 營運團隊可將注意力集中到部署與管理==上,而不用擔心諸如特定軟體版本與應用程式特定設定之類的應用程式細節。
容器不像虛擬機器會將==硬體堆疊虛擬化==,而是會在==作業系統層級進行虛擬化==,讓多個容器直接在 OS 核心之上執行。這表示==容器遠比虛擬機器輕量==,不但共用 OS 核心、啟動速度較快,而且使用的記憶體量也比啟動完整 OS 要少很多。
容器讓開發人員能夠建立可以預測的環境,而且這個==環境是與其他應用程式隔離開的==。容器也可能包含應用程式需要的軟體依附元件,例如特定版本的程式設計語言執行階段與其他軟體程式庫。從開發人員的角度來看,無論最終應用程式將部署到何處,這==一切都能保證一致==。這一切全都代表生產力:開發人員與 IT 營運團隊可以==減少花費在偵錯與診斷環境差異上的時間,而將更多時間用在為使用者提供新功能==。而且開發人員現在可以在開發與測試環境中,做出同樣適用於實際工作環境的假設,因此錯誤的發生機率也會隨之降低。
節錄自:qwiklabs GSP767 Exploring Cost-optimization for GKE Virtual Machines
Cost Analysis
You're now running the same workload which required three e2-medium machines on one e2-standard-2 machine.
Take a look at the hourly cost for having an e2 standard and shared core machine types up:
The cost of three e2-medium machines would be about $0.1 an hour while one e2-standard-2 is listed at about $0.067 an hour.
Saving $.04 an hour may seem small, but this cost can add up over the lifetime of a running application. It would be even more noticeable at a larger scale too. Because the e2-standard-2 machine can pack your workload more efficiently and there's less unused space, the cost of scaling up would grow less quickly.
這篇筆記主要目的,是讓開發人員可以在本機 local 環境下架設私有鏈,以供開發及測試遊戲。
Prerequisite
Docker Desktop for Mac
EOSIO binaries
EOSIO Contract Development Toolkit(CDT)
在正式環境下,因為 os 是 RedHat 7.x,而且是最乾淨的那種,所以需要另外安裝套件才有辦法安裝 eosio bin,這部份最後再補充。