2016-12-05 13:12:19 -06:00
###############################################################################
## Configuration parameters for SONiC build system
###############################################################################
# SONIC_CONFIG_PRINT_DEPENDENCIES - show dependencies for each invoked target.
# Before executing rule for each target its dependencies are printed to console.
# Uncomment next line to enable:
# SONIC_CONFIG_PRINT_DEPENDENCIES = y
# SONIC_CONFIG_BUILD_JOBS - set number of jobs for parallel build.
# Corresponding -j argument will be passed to make command inside docker
# container.
2017-03-07 14:32:39 -06:00
SONIC_CONFIG_BUILD_JOBS = 1
2016-12-05 13:12:19 -06:00
2017-09-01 17:28:33 -05:00
# SONIC_CONFIG_MAKE_JOBS - set number of parallel make jobs per package.
2017-07-07 07:32:50 -05:00
# Corresponding -j argument will be passed to make/dpkg commands that build separate packages
SONIC_CONFIG_MAKE_JOBS = $(shell nproc)
2020-03-23 11:45:43 -05:00
# DEFAULT_BUILD_LOG_TIMESTAMP - add timestamp in build log
# Supported format: simple, none
DEFAULT_BUILD_LOG_TIMESTAMP = none
2020-03-21 16:21:26 -05:00
2019-06-20 11:19:33 -05:00
# SONIC_USE_DOCKER_BUILDKIT - use docker buildkit for build.
# If set to y SONiC build system will set environment variable DOCKER_BUILDKIT=1
# to enable docker buildkit.
# This options will speed up docker image build time.
# NOTE: SONIC_USE_DOCKER_BUILDKIT will produce larger installable SONiC image
# because of a docker bug (more details: https://github.com/moby/moby/issues/38903)
# SONIC_USE_DOCKER_BUILDKIT = y
2018-11-01 20:00:00 -05:00
# SONIC_CONFIG_USE_NATIVE_DOCKERD_FOR_BUILD - use native dockerd for build.
2022-04-27 19:39:37 -05:00
# If set to y SONiC build container will use native dockerd instead of dind for faster build.
# Special handling of the docker image file names is needed to avoid conflicts with
# other SONiC build jobs on the same server. This requires changes to the Dockerfile.j2 FROM statement
# in the dockers/ and platform/ subdirs to use a variable reference instead of an explicit image name.
2018-11-01 20:00:00 -05:00
# SONIC_CONFIG_USE_NATIVE_DOCKERD_FOR_BUILD = y
2016-12-05 13:12:19 -06:00
# SONIC_CONFIG_ENABLE_COLORS - enable colored output in build system.
# Comment next line to disable:
# SONIC_CONFIG_ENABLE_COLORS = y
2023-02-23 17:36:37 -06:00
# CHANGE_DEFAULT_PASSWORD - enforce default user/users to change password on 1st login
CHANGE_DEFAULT_PASSWORD ?= n
2017-04-12 13:23:48 -05:00
# DEFAULT_USERNAME - default username for installer build
DEFAULT_USERNAME = admin
2016-12-05 13:12:19 -06:00
2017-04-12 13:23:48 -05:00
# DEFAULT_PASSWORD - default password for installer build
DEFAULT_PASSWORD = YourPaSsWoRd
2017-02-17 15:47:01 -06:00
# ENABLE_DHCP_GRAPH_SERVICE - specify the source of minigraph to generate configuration file.
2018-03-27 15:39:04 -05:00
# If set to y SONiC will get the minigraph from graph service. Graph service URL need to be
2017-02-17 15:47:01 -06:00
# passed through DHCP option 225.
# If not set (default behavior) the default minigraph built into the image will be used.
# ENABLE_DHCP_GRAPH_SERVICE = y
2019-12-04 06:50:56 -06:00
# ENABLE_ZTP - installs Zero Touch Provisioning support.
# ENABLE_ZTP = y
2021-07-24 18:24:43 -05:00
# INCLUDE_PDE - Enable platform development enviroment
# INCLUDE_PDE = y
2018-03-27 15:39:04 -05:00
# SHUTDOWN_BGP_ON_START - if set to y all bgp sessions will be in admin down state when
2017-06-12 13:05:22 -05:00
# bgp service starts.
# SHUTDOWN_BGP_ON_START = y
2018-03-06 01:55:37 -06:00
# ENABLE_PFCWD_ON_START - if set to y PFC Watchdog (PFCWD) will be enabled all server-facing ports
# by default for TOR switch
# ENABLE_PFCWD_ON_START = y
2019-08-15 04:20:18 -05:00
# INSTALL_DEBUG_TOOLS - installs debugging tools in baseline docker
2017-02-21 21:04:43 -06:00
# Uncomment next line to enable:
2019-08-15 04:20:18 -05:00
# INSTALL_DEBUG_TOOLS = y
2017-04-20 11:12:27 -05:00
2020-11-12 12:22:38 -06:00
# SONIC_USE_PDDF_FRAMEWORK - Use PDDF generic drivers and plugins
# Uncomment next line to enable:
SONIC_USE_PDDF_FRAMEWORK = y
2017-04-20 11:12:27 -05:00
# SONIC_ROUTING_STACK - specify the routing-stack being elected to drive SONiC's control-plane.
2018-10-02 12:24:59 -05:00
# Supported routing stacks on SONiC are:
2021-06-23 11:15:56 -05:00
# routing-stacks: frr.
2019-05-08 01:40:40 -05:00
SONIC_ROUTING_STACK = frr
2017-05-30 18:17:03 -05:00
# ENABLE_SYNCD_RPC - build docker-syncd with rpc packages for testing purposes.
# Uncomment to enable:
# ENABLE_SYNCD_RPC = y
2018-03-27 15:39:04 -05:00
2017-09-19 18:23:31 -05:00
# Enable Origanization Extensions - Specific to the deployment scenarios of the Organization
ENABLE_ORGANIZATION_EXTENSIONS = y
2018-03-27 15:39:04 -05:00
2018-06-19 17:59:12 -05:00
# Debugging option allows sonic debian packages to get built including symbols
# information. Profiling option, disables compiler optimizations (-O0) as well
# as includes symbols information. Given that 'profiling' option is a superset
# of 'debugging' one, user should only enable either one option or the other --
# if both options are enabled, the 'profiling' one will prevail.
#SONIC_DEBUGGING_ON = y
#SONIC_PROFILING_ON = y
2018-07-25 10:14:18 -05:00
# DEFAULT_KERNEL_PROCURE_METHOD - default method for obtaining kernel
# build: build kernel from source
# download: download pre-built kernel from Azure storage.
DEFAULT_KERNEL_PROCURE_METHOD = build
2018-11-26 20:19:12 -06:00
# FRR user and group id values. These only take effect when SONIC_ROUTING_STACK is frr.
# Note: these values match the admin uid/gid of the host's admin account. If these values
# change and user doesn't want the frr uid/gid to potentially match a random user on the
# host, then either the appropriate account and group will need to be created on the host
# manually or changes need to be made when the image is built to create the account and
# group during installation.
2019-01-16 20:34:41 -06:00
FRR_USER_UID = 300
FRR_USER_GID = 300
2019-03-29 17:25:17 -05:00
[build]: support for DPKG local caching (#4117)
DPKG caching framework provides the infrastructure to cache the sonic module/target .deb files into a local cache by tracking the target dependency files.SONIC build infrastructure is designed as a plugin framework where any new source code can be easily integrated into sonic as a module and that generates output as a .deb file. The source code compilation of a module is completely independent of other modules compilation. Inter module dependency is resolved through build artifacts like header files, libraries, and binaries in the form of Debian packages. For example module A depends on module B. While module A is being built, it uses B's .deb file to install it in the build docker.
The DPKG caching framework provides an infrastructure that caches a module's deb package and restores it back to the build directory if its dependency files are not modified. When a module is compiled for the first time, the generated deb package is stored at the DPKG cache location. On the subsequent build, first, it checks the module dependency file modification. If none of the dependent files is changed, it copies the deb package from the cache location, otherwise, it goes for local compilation and generates the deb package. The modified files should be checked-in to get the newer cache deb package.
This provides a huge improvement in build time and also supports the true incremental build by tracking the dependency files.
- How I did it
It takes two global arguments to enable the DPKG caching, the first one indicates the caching method and the second one describes the location of the cache.
SONIC_DPKG_CACHE_METHOD=cache
SONIC_DPKG_CACHE_SOURCE=
where SONIC_DPKG_CACHE_METHOD - Default method is 'cache' for deb package caching
none: no caching
cache: cache from local directory
Dependency file tracking:
Dependency files are tracked for each target in two levels.
1. Common make infrastructure files - rules/config, rules/functions, slave.mk etc.
2. Per module files - files which are specific to modules, Makefile, debian/rules, patch files, etc.
For example: dependency files for Linux Kernel - src/sonic-linux-kernel,
SPATH := $($(LINUX_HEADERS_COMMON)_SRC_PATH)
DEP_FILES := $(SONIC_COMMON_FILES_LIST) rules/linux-kernel.mk rules/linux-kernel.dep
DEP_FILES += $(SONIC_COMMON_BASE_FILES_LIST)
SMDEP_FILES := $(addprefix $(SPATH)/,$(shell cd $(SPATH) && git ls-files))
DEP_FLAGS := $(SONIC_COMMON_FLAGS_LIST) \
$(KERNEL_PROCURE_METHOD) $(KERNEL_CACHE_PATH)
$(LINUX_HEADERS_COMMON)_CACHE_MODE := GIT_CONTENT_SHA
$(LINUX_HEADERS_COMMON)_DEP_FLAGS := $(DEP_FLAGS)
$(LINUX_HEADERS_COMMON)_DEP_FILES := $(DEP_FILES)
$(LINUX_HEADERS_COMMON)_SMDEP_FILES := $(SMDEP_FILES)
$(LINUX_HEADERS_COMMON)_SMDEP_PATHS := $(SPATH)
Cache file tracking:
The Cache file is a compressed TAR ball of a module's target DEB file and its derived-target DEB files.
The cache filename is formed with the following format
FORMAT:
<module deb filename>.<24 byte of DEP SHA hash >-<24 byte of MOD SHA hash>.tgz
Eg:
linux-headers-4.9.0-9-2-common_4.9.168-1+deb9u3_all.deb-23658712fd21bb776fa16f47-c0b63ef593d4a32643bca228.tgz
< 24-byte DEP SHA value > - the SHA value is derived from all the dependent packages.
< 24-byte MOD SHA value > - the SHA value is derived from either of the following.
GIT_COMMIT_SHA - SHA value of the last git commit ID if it is a submodule
GIT_CONTENT_SHA - SHA value is generated from the content of the target dependency files.
Target Specific rules:
Caching can be enabled/disabled on a global level and also on the per-target level.
$(addprefix $(DEBS_PATH)/, $(SONIC_DPKG_DEBS)) : $(DEBS_PATH)/% : .platform $$(addsuffix -install,$$(addprefix $(DEBS_PATH)/,$$($$*_DEPENDS))) \
$(call dpkg_depend,$(DEBS_PATH)/%.dep )
$(HEADER)
# Load the target deb from DPKG cache
$(call LOAD_CACHE,$*,$@)
# Skip building the target if it is already loaded from cache
if [ -z '$($*_CACHE_LOADED)' ] ; then
.....
# Rules for Generating the target DEB file.
.....
# Save the target deb into DPKG cache
$(call SAVE_CACHE,$*,$@)
fi
$(FOOTER)
The make rule-'$(call dpkg_depend,$(DEBS_PATH)/%.dep )' checks for target dependency file modification. If it is newer than the target, it will go for re-generation of that target.
Two main macros 'LOAD_CACHE' and 'SAVE_CACHE' are used for loading and storing the cache contents.
The 'LOAD_CACHE' macro is used to load the cache file from cache storage and extracts them into the target folder. It is done only if target dependency files are not modified by checking the GIT file status, otherwise, cache loading is skipped and full compilation is performed.
It also updates the target-specific variable to indicate the cache is loaded or not.
The 'SAVE_CACHE' macro generates the compressed tarball of the cache file and saves them into cache storage. Saving into the cache storage is protected with a lock.
- How to verify it
The caching functionality is verified by enabling it in Linux kernel submodule.
It uses the cache directory as 'target/cache' where Linux cache file gets stored on the first-time build and it is picked from the cache location during the subsequent clean build.
- Description for the changelog
The DPKG caching framework provides the infrastructure to save the module-specific deb file to be cached by tracking the module's dependency files.
If the module's dependency files are not changed, it restores the module deb files from the cache storage.
- Description for the changelog
- A picture of a cute animal (not mandatory but encouraged)
DOCUMENT PR:
https://github.com/Azure/SONiC/pull/559
2020-03-11 22:04:52 -05:00
# DPKG cache allows the .deb files to be stored in the cache path. This allows the submodules
# package to be cached and restored back if its commit hash is not modified and its dependencies are not modified.
# SONIC_DPKG_CACHE_METHOD - Default method of deb package caching
# none : no caching
# rwcache : Use cache if exists else build the source and update the cache
# wcache : Dont use the cache and just build the source and update the cache
# rcache : Use cache if exists, but dont update the cache
# cache : Same as rwcache
# SONIC_DPKG_CACHE_SOURCE - Stores the cache location details
SONIC_DPKG_CACHE_METHOD ?= none
SONIC_DPKG_CACHE_SOURCE ?= /var/cache/sonic/artifacts
2019-03-29 17:25:17 -05:00
# Default VS build memory preparation
DEFAULT_VS_PREPARE_MEM = yes
2019-09-14 22:27:09 -05:00
2023-11-07 18:54:36 -06:00
# INCLUDE_SYSTEM_GNMI - build docker-sonic-gnmi for system gnmi support
INCLUDE_SYSTEM_GNMI = y
2020-04-04 17:24:06 -05:00
2024-01-31 00:14:23 -06:00
# INCLUDE_SYSTEM_EVENTD - build docker-eventd for system eventd support
INCLUDE_SYSTEM_EVENTD = y
2020-08-05 15:23:12 -05:00
# INCLUDE_SYSTEM_TELEMETRY - build docker-sonic-telemetry for system telemetry support
2023-11-07 18:54:36 -06:00
INCLUDE_SYSTEM_TELEMETRY = n
2020-08-05 15:23:12 -05:00
# INCLUDE_ICCPD - build docker-iccpd for mclag support
INCLUDE_ICCPD = n
2020-04-04 17:24:06 -05:00
2020-08-05 15:23:12 -05:00
# INCLUDE_SFLOW - build docker-sflow for sFlow support
INCLUDE_SFLOW = y
SONiC Management Framework Release 1.0 (#3488)
* Added sonic-mgmt-framework as submodule / docker
* fix build issues
* update sonic-mgmt-framework submodule branch to master
* Merged changes 70007e6d2ba3a4c0b371cd693ccc63e0a8906e77..00d4fcfed6a759e40d7b92120ea0ee1f08300fc6
00d4fcfed6a759e40d7b92120ea0ee1f08300fc6 Modified environemnt variables
* Changes to build sonic-mgmt-framework docker
* bumped up sonic-mgmt-framework commit-id
* version bump for sonic-mgmt-framework commit-it
* bumped up sonic-mgmt-framework commit-id
* Add python packages to docker
* Build fix for docker with python packages
* added libyang as dependent package
* Allow building images on NFS-mounted clones
Prior to this change, `build_debian.sh` would generate a Debian
filesystem in `./fsroot`. This needs root permissions, and one of the
tests that is performed is whether the user can create a character
special file in the filesystem (using mknod).
On most NFS deployments, `root` is the least privileged user, and cannot
run mknod. Also, attempting to run commands like rm or mv as root would
fail due to permission errors, since the root user gets mapped to an
unprivileged user like `nobody`.
This commit changes the location of the Debian filesystem to `/fsroot`,
which is a tmpfs mount within the slave Docker. The default squashfs,
docker tarball and zip files are also created within /tmp, before being
copied back to /sonic as the regular user.
The side effect of this change is that the contents of `/fsroot` are no
longer available once the slave container exits, however they are
available within the squashfs image.
Signed-off-by: Nirenjan Krishnan <Nirenjan.Krishnan@dell.com>
* bumped up sonc-mgmt-framework commit to include PR #18
* REST Server startup script is enahnced to read the settings from
ConfigDB. Below table provides mapping of db field to command line
argument name.
============================================================
ConfigDB entry key Field name REST Server argument
============================================================
REST_SERVER|default port -port
REST_SERVER|default client_auth -client_auth
REST_SERVER|default log_level -v
DEVICE_METADATA|x509 server_crt -cert
DEVICE_METADATA|x509 server_key -key
DEVICE_METADATA|x509 ca_crt -cacert
============================================================
* Replace src/telemetry as submodule to sonic-telemetry
* Update telemetry commit HEAD
* Update sonic-telemetry commit HEAD
* libyang env path update
* Add libyang dependency to telemetry
* Add scripts to create JSON files for CLI backend
Scripts to create /var/platform/syseeprom and /var/platform/system, which are back-end
files for CLI, for system EEPROM and system information.
Signed-off-by: Howard Persh <Howard_Persh@dell.com>
* In startup script, create directory where CLI back-end files live
Signed-off-by: Howard Persh <Howard_Persh@dell.com>
* build dependency pkgs added to docker for build failure fix
* Changes to fix build issue for mgmt framework
* Fix exec path issue with telemetry
* s5232[device] PSU detecttion and default led state support
* Processing of first boot in rc.local should not have premature exit
Signed-off-by: Howard Persh <Howard_Persh@dell.com>
* docker mount options added for platform, system features
* bumped up sonic-mgmt-framework commit id to pick 23rd July 2019 changes
* Added mount options for telemetry docker to get access for system and platform info.
* Update commit for sonic-utilities
* [dell]: Corrected dport map and renamed config files for S5232F
* Fix telemetry submodule commit
* added support for sonic-cli console
* [Dell S5232F, Z9264F] Harden FPGA driver kernel module
For Dell S5232F and Z9264F platforms, be more strict when checking state
in ISR of FPGA driver, to harden against spurious interrupts.
Signed-off-by: Howard Persh <Howard_Persh@dell.com>
* update mgmt-framework submodule to 27th Aug commit.
* remove changes not related to mgmt-framework and sonic-telemetry
* Revert "Replace src/telemetry as submodule to sonic-telemetry"
This reverts commit 11c31929759a17122782d4944066a6ac8453b78d.
* Revert "Replace src/telemetry as submodule to sonic-telemetry"
This reverts commit 11c31929759a17122782d4944066a6ac8453b78d.
* make submodule changes and remove a change not related to PR
* more changes
* Update .gitmodules
* Update Dockerfile.j2
* Update .gitmodules
* Update .gitmodules
* Update .gitmodules
reverting experimental change
* Removed syspoll for release_1.0
Signed-off-by: Jeff Yin <29264773+jeff-yin@users.noreply.github.com>
* Update docker-sonic-mgmt-framework.mk
* Update sonic-mgmt-framework.mk
* Update sonic-mgmt-framework.mk
* Update docker-sonic-mgmt-framework.mk
* Update docker-sonic-mgmt-framework.mk
* Revert "Processing of first boot in rc.local should not have premature exit"
This reverts commit e99a91ffc28a0fd13f4ad458719d2511c3665431.
* Remove old telemetry directory
* Update docker-sonic-mgmt-framework.mk
* Resolving merge conflict with Azure
* Reverting the wrong merge
* Use CVL_SCHEMA_PATH instead of changing directory for telemetry startup
* Add missing export
* Add python mmh3 to slave dockerfile
* Remove sonic-mgmt-framework build dep for telemetry, fix dialout startup issues
* Provided flag to disable compiling mgmt-framework
* Update sonic-utilites point latest commit id
* Point sonic-utilities to Azure accepted SHA
* Updating mgmt framework to right sha
* Add sonic-telemetry submodule
* Update the mgmt-framework commit id
Co-authored-by: jghalam <joe.ghalam@gmail.com>
Co-authored-by: Partha Dutta <51353699+dutta-partha@users.noreply.github.com>
Co-authored-by: srideepDell <srideep_devireddy@dell.com>
Co-authored-by: nirenjan <nirenjan@users.noreply.github.com>
Co-authored-by: Sachin Holla <51310506+sachinholla@users.noreply.github.com>
Co-authored-by: Eric Seifert <seiferteric@gmail.com>
Co-authored-by: Howard Persh <hpersh@yahoo.com>
Co-authored-by: Jeff Yin <29264773+jeff-yin@users.noreply.github.com>
Co-authored-by: Arunsundar Kannan <31632515+arunsundark@users.noreply.github.com>
Co-authored-by: rvasanthm <51932293+rvasanthm@users.noreply.github.com>
Co-authored-by: Ashok Daparthi-Dell <Ashok_Daparthi@Dell.com>
Co-authored-by: anand-kumar-subramanian <51383315+anand-kumar-subramanian@users.noreply.github.com>
2019-12-23 23:47:16 -06:00
2020-08-05 15:23:12 -05:00
# INCLUDE_MGMT_FRAMEWORK - build docker-sonic-mgmt-framework for CLI and REST server support
INCLUDE_MGMT_FRAMEWORK = y
2020-01-14 19:13:45 -06:00
2021-02-08 21:35:08 -06:00
# ENABLE_HOST_SERVICE_ON_START - enable sonic-host-server for mgmt-framework and/or
2023-11-07 18:54:36 -06:00
# gnmi containers to access host functionality by default
2023-02-15 00:40:09 -06:00
ENABLE_HOST_SERVICE_ON_START = y
2020-08-21 17:34:14 -05:00
2020-08-05 15:23:12 -05:00
# INCLUDE_RESTAPI - build docker-sonic-restapi for configuring the switch using REST APIs
2023-12-15 02:25:26 -06:00
INCLUDE_RESTAPI ?= n
2020-02-21 12:20:07 -06:00
2020-08-05 15:23:12 -05:00
# INCLUDE_NAT - build docker-nat for nat support
INCLUDE_NAT = y
2020-04-04 17:24:06 -05:00
2021-07-15 12:35:56 -05:00
# INCLUDE_DHCP_RELAY - build and install dhcp-relay package
INCLUDE_DHCP_RELAY = y
2023-09-11 11:15:56 -05:00
# INCLUDE_DHCP_SERVER - build and install dhcp-server package
2023-11-30 15:52:54 -06:00
INCLUDE_DHCP_SERVER ?= n
2023-09-11 11:15:56 -05:00
2021-12-07 13:11:25 -06:00
# INCLUDE_P4RT - build docker-p4rt for P4RT support
2023-09-01 13:07:50 -05:00
INCLUDE_P4RT = n
2021-12-07 13:11:25 -06:00
2021-11-15 23:56:37 -06:00
# ENABLE_AUTO_TECH_SUPPORT - Enable the configuration for event-driven techsupport & coredump mgmt feature
ENABLE_AUTO_TECH_SUPPORT = y
2022-09-19 01:54:08 -05:00
# ENABLE_TRANSLIB_WRITE - Enable translib write/config operations via the gNMI interface.
2020-06-25 10:04:43 -05:00
# Uncomment to enable:
2022-09-19 01:54:08 -05:00
# ENABLE_TRANSLIB_WRITE = y
2021-07-15 21:48:55 -05:00
2022-11-29 02:58:27 -06:00
# ENABLE_NATIVE_WRITE - Enable native write/config operations via the gNMI interface.
2023-04-27 00:08:07 -05:00
ENABLE_NATIVE_WRITE = y
2022-11-29 02:58:27 -06:00
2021-07-19 23:17:47 -05:00
# INCLUDE_MACSEC - build docker-macsec for macsec support
INCLUDE_MACSEC = y
2023-10-25 02:39:03 -05:00
# INCLUDE_GBSYNCD - build docker-gbsyncd-* for gearbox support
INCLUDE_GBSYNCD ?= y
2022-12-13 04:06:30 -06:00
# INCLUDE_TEAMD - build docker-teamd for LAG protocol support
INCLUDE_TEAMD ?= y
# INCLUDE_ROUTER_ADVERTISER - build docker-router-advertiser for router advertisements support
INCLUDE_ROUTER_ADVERTISER ?= y
2020-08-05 15:23:12 -05:00
# INCLUDE_KUBERNETES - if set to y kubernetes packages are installed to be able to
2020-04-13 10:41:18 -05:00
# run as worker node in kubernetes cluster.
2023-01-10 09:56:44 -06:00
INCLUDE_KUBERNETES ?= n
2020-04-13 10:41:18 -05:00
2021-07-19 23:17:47 -05:00
KUBE_DOCKER_PROXY = http://172.16.1.1:3128/
2021-02-23 15:22:45 -06:00
2020-04-13 10:41:18 -05:00
# KUBERNETES_VERSION - Set to the required version.
# K8s_GCR_IO_PAUSE_VERSION - Version of k8s universal pause container image
2020-08-05 15:23:12 -05:00
# These are Used *only* when INCLUDE_KUBERNETES=y
2020-04-13 10:41:18 -05:00
# NOTE: As a worker node it has to run version compatible to kubernetes master.
#
2022-08-13 10:01:35 -05:00
KUBERNETES_VERSION = 1.22.2-00
2023-03-16 19:21:37 -05:00
KUBERNETES_CNI_VERSION = 0.8.7-00
2022-08-13 10:01:35 -05:00
K8s_GCR_IO_PAUSE_VERSION = 3.5
# INCLUDE_KUBERNETES_MASTER - if set to y kubernetes packages are installed o be able
# to run as master node in kubernetes cluster
INCLUDE_KUBERNETES_MASTER ?= n
# MASTER_KUBERNETES_VERSION - version of k8s components
# MASTER_PAUSE_VERSION - version of pause container image
# MASTER_COREDNS_VERSION - version of coredns container image
# MASTER_ETCD_VERSION = version of etcd container image
Add k8s master code new (#15716)
Why I did it
Currently, k8s master image is generated from a separate branch which we created by ourselves, not release ones. We need to commit these k8s master related code to master branch for a better way to do k8s master image build out.
Work item tracking
Microsoft ADO (number only):
19998138
How I did it
Install k8s dashboard docker images
Install geneva mds and mdsd and fluentd docker images and tag them as latest, tagging latest will help create container always with the latest version
Install azure-storage-blob and azure-identity, this will help do etcd backup and restore.
Install kubernetes python client packages, this will help read worker and container state, we can send these metric to Geneva.
Remove mdm debian package, will replace it with the mdm docker image
Add k8s master entrance script, this script will be called by rc-local service when system startup. we have some master systemd services in compute-move repo, when VMM service create master VM, VMM will copy all master service files inside VM, the entrance script will setup all services according to the service files.
When the entrance script content changed, the PR build will set include_kubernetes_master=y to help do validation for k8s master related code change. The default value of include_kubernetes_master should be always n for public master branch. We will generate master image from internal master branch
How to verify it
Build with INCLUDE_KUBERNETES_MASTER = y
2023-07-24 18:44:59 -05:00
# MASTER_CRI_DOCKERD = version of cri-dockerd container image
# MASTER_UI_METRIC_VERSION = version of k8s metrics server container image
# MASTER_UI_DASH_VERSION = version of k8s dashboard container image
# MASTER_MDM_VERSION = version of mdm container image
# MASTER_MDS_VERSION = version of mds container image
# MASTER_FLUENTD_VERSION = version of fluentd container image
2022-08-13 10:01:35 -05:00
MASTER_KUBERNETES_VERSION = 1.22.2-00
MASTER_KUBERNETES_CONTAINER_IMAGE_VERSION = v1.22.2
MASTER_PAUSE_VERSION = 3.5
MASTER_COREDNS_VERSION = v1.8.4
MASTER_ETCD_VERSION = 3.5.0-0
2024-02-27 20:09:12 -06:00
MASTER_CRI_DOCKERD = 0.3.10
Add k8s master code new (#15716)
Why I did it
Currently, k8s master image is generated from a separate branch which we created by ourselves, not release ones. We need to commit these k8s master related code to master branch for a better way to do k8s master image build out.
Work item tracking
Microsoft ADO (number only):
19998138
How I did it
Install k8s dashboard docker images
Install geneva mds and mdsd and fluentd docker images and tag them as latest, tagging latest will help create container always with the latest version
Install azure-storage-blob and azure-identity, this will help do etcd backup and restore.
Install kubernetes python client packages, this will help read worker and container state, we can send these metric to Geneva.
Remove mdm debian package, will replace it with the mdm docker image
Add k8s master entrance script, this script will be called by rc-local service when system startup. we have some master systemd services in compute-move repo, when VMM service create master VM, VMM will copy all master service files inside VM, the entrance script will setup all services according to the service files.
When the entrance script content changed, the PR build will set include_kubernetes_master=y to help do validation for k8s master related code change. The default value of include_kubernetes_master should be always n for public master branch. We will generate master image from internal master branch
How to verify it
Build with INCLUDE_KUBERNETES_MASTER = y
2023-07-24 18:44:59 -05:00
MASTER_UI_METRIC_VERSION = v1.0.8
MASTER_UI_DASH_VERSION = v2.7.0
MASTER_MDM_VERSION = 2.2023.505.1124-45da18-20230505t1700
MASTER_MDS_VERSION = mariner_20230517.1
MASTER_FLUENTD_VERSION = mariner_20230517.1
2020-04-13 10:41:18 -05:00
2020-06-09 02:25:17 -05:00
# SONIC_ENABLE_IMAGE_SIGNATURE - enable image signature
# To not use the auto-generated self-signed certificate, the required files to sign the image as below:
# SIGNING_KEY =
# SIGNING_CERT =
# CA_CERT =
# The relative path is build root folder.
SONIC_ENABLE_IMAGE_SIGNATURE ?= n
2020-12-21 01:31:10 -06:00
2022-04-19 00:23:15 -05:00
# SONIC_ENABLE_SECUREBOOT_SIGNATURE - enable SONiC kernel signing to support UEFI secureboot
# To support UEFI secureboot chain of trust requires EFI kernel to be signed as a PE binary
# SIGNING_KEY =
# SIGNING_CERT =
# The absolute path should be provided.
SONIC_ENABLE_SECUREBOOT_SIGNATURE ?= n
2023-03-14 07:55:22 -05:00
# Full Secure Boot feature flags.
# SECURE_UPGRADE_DEV_SIGNING_KEY - path to development signing key, used for image signing during build
2023-04-24 13:17:51 -05:00
# SECURE_UPGRADE_SIGNING_CERT - path to development signing certificate, used for image signing during build
2023-03-14 07:55:22 -05:00
# SECURE_UPGRADE_MODE - enum value for secure upgrade mode, valid options are "dev", "prod" and "no_sign"
# SECURE_UPGRADE_PROD_SIGNING_TOOL - path to a vendor signing tool for production flow.
2023-05-16 00:36:13 -05:00
# SECURE_UPGRADE_PROD_TOOL_ARGS - Extra arguments options for vendor to use to run his specific prod signing script
2023-04-18 17:48:47 -05:00
SECURE_UPGRADE_DEV_SIGNING_KEY ?=
2023-04-24 13:17:51 -05:00
SECURE_UPGRADE_SIGNING_CERT ?=
2023-03-14 07:55:22 -05:00
SECURE_UPGRADE_MODE = "no_sign"
SECURE_UPGRADE_PROD_SIGNING_TOOL ?=
2023-05-16 00:36:13 -05:00
SECURE_UPGRADE_PROD_TOOL_ARGS ?=
2020-12-21 01:31:10 -06:00
# PACKAGE_URL_PREFIX - the package url prefix
PACKAGE_URL_PREFIX ?= https://packages.trafficmanager.net/public/packages
# TRUSTED_GPG_URLS - the trusted gpgs, separated by comma
TRUSTED_GPG_URLS = https://packages.trafficmanager.net/debian/public_key.gpg,https://packages.microsoft.com/keys/microsoft.asc
# SONIC_VERSION_CONTROL_COMPONENTS - Valid values: none|all|components..., the components consist of one or multiple: deb,py2,py3,web,git,docker, seperated by comma
# none : disable the version control
# all : enable the version control for all components
# deb : debian packages
# py2 : python2 packages
# py3 : python3 pakcages
# web : web packages, downloaded by wget, curl
# git : git repositories, donloaded by git clone
# docker: docker base images
SONIC_VERSION_CONTROL_COMPONENTS ?= none
2020-12-26 12:30:51 -06:00
2023-01-13 02:16:35 -06:00
# MIRROR_SNAPSHOT - support mirror snapshot flag
MIRROR_SNAPSHOT ?= n
2022-12-11 19:20:56 -06:00
# SONIC_VERSION_CACHE allows the .deb,.py, wget, git, docker and go files to be stored in the cache path. This allows the submodules to
# cache standard installation package and restored back to avoid the package download every time.
# SONIC_VERSION_CACHE - Method of deb package caching
# none : no caching
# cache : Use cache if exists else build the source and update the cache
# SONIC_VERSION_CACHE_SOURCE - Defines the version cache location details
SONIC_VERSION_CACHE_METHOD ?= none
SONIC_VERSION_CACHE_SOURCE ?= $(SONIC_DPKG_CACHE_SOURCE)/vcache
2020-12-26 12:30:51 -06:00
# SONiC docker registry
#
2021-07-14 03:27:25 -05:00
# Set the env variable ENABLE_DOCKER_BASE_PULL = y to enable pulling sonic-slave docker from registry
REGISTRY_PORT ?= 443
REGISTRY_SERVER ?= sonicdev-microsoft.azurecr.io
2023-05-04 03:41:10 -05:00
REGISTRY_SERVER_PATH ?=
2021-09-01 19:28:13 -05:00
# BUILD_MULTIASIC_KVM - if set to y multi-asic KVM images will be generated.
BUILD_MULTIASIC_KVM = n
2021-01-25 19:43:56 -06:00
# INCLUDE_MUX - build docker-mux for dual ToR (Gemini)
INCLUDE_MUX = y
2022-02-09 05:29:18 -06:00
# ENABLE_ASAN - enable address sanitizer
ENABLE_ASAN ?= n
2022-03-14 05:09:20 -05:00
# reset default container registry from dockerhub to other
DEFAULT_CONTAINER_REGISTRY ?=
2022-05-05 18:21:30 -05:00
2022-07-06 06:03:31 -05:00
# INCLUDE_BOOTCHART - install systemd-bootchart
INCLUDE_BOOTCHART = y
# ENABLE_BOOTCHART - whether to enable systemd-bootchart on boot
ENABLE_BOOTCHART = n
2023-07-13 10:00:38 -05:00
# INCLUDE_FIPS - support FIPS feature, only for amd64 or arm64, armhf not supported yet
2022-05-05 18:21:30 -05:00
# ENABLE_FIPS - support FIPS flag, if enabled, no additional config requred for the image to support FIPS
2023-07-13 10:00:38 -05:00
INCLUDE_FIPS ?= y
2022-05-05 18:21:30 -05:00
ENABLE_FIPS ?= n
2022-06-16 01:13:01 -05:00
# SONIC_SLAVE_DOCKER_DRIVER - set the sonic slave docker storage driver
SONIC_SLAVE_DOCKER_DRIVER ?= vfs
2022-12-17 16:38:31 -06:00
# GZ_COMPRESS_PROGRAM - select pigz (a parallel implementation of gzip) to reduce a build time
# and speed up a decompression of docker images on target system
GZ_COMPRESS_PROGRAM ?= gzip
2023-04-11 20:20:08 -05:00
# SONIC_OS_VERSION - sonic os version
2023-08-21 12:49:54 -05:00
SONIC_OS_VERSION ?= 12
2023-10-23 05:05:22 -05:00
# PIP timeout for http connection
PIP_HTTP_TIMEOUT ?= 60
2023-10-23 21:01:58 -05:00
# BUILD_REDUCE_IMAGE_SIZE - reduce the image size as much as possbible
BUILD_REDUCE_IMAGE_SIZE = n