Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

merge latest code #2

Merged
merged 181 commits into from
Aug 24, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
181 commits
Select commit Hold shift + click to select a range
26afa34
[device] Misc fixes for Arista platforms (#1844)
Staphylo Jul 5, 2018
a8af2e5
[sonic_debian_extension.j2] Create /var/cache/sonic/ directory (#1845)
jleveque Jul 6, 2018
51bfc2e
[SAI] update SAI header to 1.3 (#1778)
prsunny Jul 6, 2018
7c632a9
[swss]: sonic-swss submodule update (#1847)
pavel-shirshov Jul 7, 2018
48e3e15
[broadcom]: update sai.mk (#1850)
lguohan Jul 8, 2018
a0bd656
[device/dell] Update Shared headroom values (#1846)
vharish02 Jul 10, 2018
a6b5acb
[mellanox]: Update MFT tools to v4.9.0 (#1851)
andriymoroz-mlnx Jul 11, 2018
3d043a1
[mellanox]: Update SAI pointer to 1.3 (#1852)
Jul 11, 2018
f598397
Pavelsh/restart swss counters (#1854)
pavel-shirshov Jul 12, 2018
daf590e
[broadcom sai] update Broadcom SDK/SAI version (#1853)
yxieca Jul 12, 2018
eb3ef2f
[mellanox]: fix mellanox SAI 1.3 build issue (#1859)
lguohan Jul 13, 2018
5e6d36c
[vs]: set platform=vs for orchagent (#1860)
lguohan Jul 13, 2018
1a93dd5
[sonic-dbsyncd]: Support empty string in lldp_rem_port_desc (#1857)
qiluo-msft Jul 13, 2018
2ccfefc
[caclmgrd] Add a rule to allow all connections from localhost (#1858)
jleveque Jul 13, 2018
2944f3e
[swss]: sonic-swss submodule update (#1856)
lguohan Jul 13, 2018
015d2d1
[sonic-dbsyncd]: Fix parse_chassis on partial lldp data (#1861)
qiluo-msft Jul 13, 2018
1955a43
[vs]: clean up process running in server namespace for vstests (#1862)
lguohan Jul 14, 2018
0008347
[sonic-utilities]: update submodule (#1865)
sihuihan88 Jul 17, 2018
f033cbe
[bcm syncd]: Wait initializing led_proc for 60 seconds (#1863)
pavel-shirshov Jul 18, 2018
c52fb76
Convert arp_update into a 'start-it-once' mode (#1864)
pavel-shirshov Jul 18, 2018
0ec9322
Change dx010 console speed (#1867)
Jul 19, 2018
927c41f
[nephos]: add support sai 1.3.0 (#1868)
simonJi2018 Jul 23, 2018
dadc17d
[Mellanox] Use MAC from EEPROM for PortChannels and VLAN Interfaces (…
andriymoroz-mlnx Jul 23, 2018
76391ba
[devices]: Added sensors.conf for S6100/Z9100 platform (#1788)
Jul 24, 2018
216d2fa
[vs-test]: not forward routes with no-export community (#1869)
sihuihan88 Jul 24, 2018
93905d3
[barefoot]: Support for platforms based on Barefoot Networks' device …
mkbalani Jul 24, 2018
e3abf0c
[docker] Exit if docker run fails (#1870)
qiluo-msft Jul 25, 2018
3c33737
[make] introducing new build option KERNEL_PROCURE_METHOD (#1837)
yxieca Jul 25, 2018
10b4bbc
[swss]: Start counter from swss container (#1875)
pavel-shirshov Jul 26, 2018
da12f57
[sonic-utilities]: update submodule (#1871)
sihuihan88 Jul 26, 2018
7cbadb7
Update submodule: swss-common, swss (#1878)
qiluo-msft Jul 27, 2018
b86c3ee
[build]: add barefoot master build badge (#1881)
lguohan Jul 27, 2018
77b899b
[submodule] advance sonic-linux-kernel submodule (#1882)
yxieca Jul 27, 2018
c3c8f7f
Fix for bash's memory-leak (#1879)
rodnymolina Jul 28, 2018
81ee8fa
[platform]: add sonic port alias for mellanox SN2700 platform (#1883)
lguohan Jul 28, 2018
5011622
[platform]: bfn intf: allow-hotplug for usb0 interface (#1889)
mkbalani Jul 30, 2018
d166a01
[submodule] Update submodule: swss-common (#1885)
qiluo-msft Jul 30, 2018
530e2dc
Only keep most recent one in old_config (#1884)
taoyl-ms Jul 31, 2018
d389c09
[submodule] Update submodule: swss-common (#1895)
qiluo-msft Aug 1, 2018
2522565
[devices]: Move Arista bfn platforms under platform/barefoot (#1894)
Staphylo Aug 1, 2018
a8c41d9
[device] Update arista driver submodule (#1897)
yurypm Aug 1, 2018
8e74230
[Ingrasys] Add platform support for S9180-32X/S9280-64X with Barefoot…
fengkm Aug 2, 2018
a215bcd
[mlnx-sfp-plugin] enhancement to support transceiver sensor monitorin…
keboliu Aug 2, 2018
38beca6
[docker-platform-monitor] make file and supervisord conf change for n…
keboliu Aug 3, 2018
c822b3c
Update arista driver submodule (#1900)
zzhiyuan Aug 3, 2018
7536104
[device]: add support for celestica E1031 (#1528)
lguohan Aug 5, 2018
1a55ae2
update sonic-platform-common submodule for xcvrd support (#1901)
keboliu Aug 6, 2018
33b713e
[submodule] update snmpagent and dbsyncd, extending/implementing ieee…
mykolaf Aug 7, 2018
3d13765
[minigraph.py] add support to parse deployment id of neighbor devices…
taoyl-ms Aug 7, 2018
634814b
change buffer template and fix some device driver bug (#1903)
simonJi2018 Aug 7, 2018
b7eeba8
Moving get_routing_stack() to a centralized location to avoid code du…
rodnymolina Aug 7, 2018
314eae5
[minigraph.py] Support parsing console ports (#1898)
taoyl-ms Aug 7, 2018
4d784d8
Upgrade azure-keyvault to known compatible version (#1906)
qiluo-msft Aug 9, 2018
7aefa18
Download newer version (8.23.0-2) of rsyslog from jessie-backports in…
jleveque Aug 10, 2018
3c3c19e
[lldp]: LLDP is misbehaving if netlink messages were lost due to timi…
zhenggen-xu Aug 10, 2018
36e9ad5
[devices]: update submodule platform/nephos/sonic-platform-modules-in…
simonJi2018 Aug 10, 2018
ae84318
[Mellanox] Update hw-management service config (#1914)
andriymoroz-mlnx Aug 10, 2018
9e2ceb7
[sonic-platform-common] Update submodule (#1915)
jleveque Aug 11, 2018
4d701ad
[baseimage]: update base image from jessie to stretch
lguohan Sep 5, 2017
ff1f508
[baseimage]: use debian 4.9.0-3 kernel
lguohan Sep 1, 2017
b6af83c
[baseimage]: upgrade initramfs to 0.130
lguohan Sep 1, 2017
72d70e9
[baseimage]: install systemd-sysv in the base image
lguohan Sep 2, 2017
f64ffe8
[baseimage]: build root filesystem via overlay fs instead of aufs
lguohan Sep 2, 2017
dabbe63
[baseimage]: Disable consistent network device naming
lguohan Sep 3, 2017
b03e974
[baseimage]: let docker in base image use overlay fs instead of aufs
lguohan Sep 5, 2017
376cabe
[baseimage]: update igb driver to 5.3.5.10
lguohan Sep 3, 2017
87ec4f1
[docker-syncd]: install kmod in docker-syncd-brcm without prompt
lguohan Sep 5, 2017
8d43f3b
[sonic-slave]: add deps for build initramfs 0.130
lguohan Sep 9, 2017
8c72d8c
[build]: insert overlay kmod for base image build
lguohan Sep 13, 2017
a87da7b
[build]: build stretch-based sonic slave docker
lguohan Sep 23, 2017
a719293
[build]: sonic-slave-stretch- sha both Dockerfile and Dockerfile.user
lguohan Sep 26, 2017
540a87a
[opennsl]: use opennsl kernel module based on kernel 4.9.0-3
lguohan Sep 5, 2017
5d1a7a1
[temp]: disable building platform drivers tempoerarily
lguohan Sep 3, 2017
23c3bfe
[kernel]: fix linux-headers common deb file name
lguohan Nov 6, 2017
a0280dd
update build instructions
lguohan Nov 6, 2017
2449faf
[kernel]: update kernel submodule and remove standalone igb driver
lguohan Dec 6, 2017
0e141a5
[baseimage]: install acl package
lguohan Dec 11, 2017
0827ed3
[baseimage]: install tacacs dependencies
lguohan Dec 11, 2017
9aebe09
[Mellanox]: Upgrade MFT package to 4.8.26 (#3)
marian-pritsak Dec 27, 2017
cd1d1b1
[Mellanox]: Update recipe for hw-management (#4)
marian-pritsak Dec 30, 2017
13c83ac
[platform]: enable platform driver for dell s6000 (#5)
lguohan Jan 3, 2018
35ab7a6
[kernel]: upgrade linux kernel to 4.9.0-5 (4.9.65-3+deb9u2) (#8)
lguohan Jan 10, 2018
5ae64e7
[ixgbe]: compile and install ixgbe to 4.9.0-5 kernel
lguohan Jan 10, 2018
f9c5783
[mellanox]: Adapt to new hw-management package (#12)
marian-pritsak Jan 26, 2018
9801ba9
[devices]: enable platform modules for various platforms
lguohan Feb 12, 2018
759edc9
[dell]: update to stretch-kernel based dell modules
lguohan Feb 13, 2018
f489bea
[platform]: incorporate sonic-platform-modules-cel into sonic buildim…
lguohan Feb 16, 2018
ec9dc57
[devices]: enable sonic-platform-modules-cel
lguohan Feb 16, 2018
025dad0
[celestica] change to use lm75 standard driver (#19)
pwisutti Feb 28, 2018
4142d7f
[Delta]: Modify delta-ag9032v1 driver for kernel 4.9 (#20)
nealtai Mar 1, 2018
0edb380
[build]: add stretch target to build in stretch docker
lguohan Mar 1, 2018
5364926
[build]: build initramfs, libwrap, tacacs packages under stretch docker
lguohan Mar 1, 2018
689bbd2
[broadcom]: update opennsl module to 3.4.1.11-1
lguohan Mar 3, 2018
91891af
[bug fix]: fix delta ag9032v1 driver compilation. disable ag9064
lguohan Mar 3, 2018
0d2ffd8
[baseimage]: move update initramfs to later stage
lguohan Mar 5, 2018
764a7ed
[device]: Enable arista drivers for sonic-linux-kernel 4.9 (#21)
Staphylo Mar 27, 2018
cbf204b
[device]: add the new platform ag9064 (#23)
Mar 27, 2018
d50332f
[devices]: Added new Mellanox MSN2010 platform (#24)
Apr 2, 2018
244aaca
[devices]: disable compiling ag9064 and ag5648
lguohan Apr 6, 2018
b53fa5e
[devices]: Modified and fixed delta ag5648 modules. (#30)
StanleyCi Apr 14, 2018
c77ddbc
[devices]: modified and fixed delta ag9064 modules (#28)
Apr 14, 2018
420f003
[mellanox]: fix SAI build makefile (#29)
mykolaf Apr 14, 2018
0fb3882
[devices]: disable compiling ag9064 and ag5648
lguohan Apr 6, 2018
6a0909e
[baseimage]: Add derived package to initramfs-tools (#33)
yurypm Apr 18, 2018
0f0e7ab
Add support 4.9 support for 7260CX3 (#34)
Staphylo Apr 27, 2018
145aa4f
[delta]: Enable ag5648, et-6248brb, ag9064 and fix the build error o…
StanleyCi May 2, 2018
ecfca8b
[devices]: DellEMC new platform support for z9264f - 64x100 (#26)
Jun 22, 2018
f7c16e3
[devices]: change celestica platform modules version back to 0.6
lguohan Jul 10, 2018
39b0e80
[device] Update arista driver submodule (#38)
yurypm Jul 14, 2018
16e16f5
[Mellanox]: Update recipe for hw-management (#4)
marian-pritsak Dec 30, 2017
46b0847
[baseimage]: use original stretch bash in the base image
lguohan Jul 30, 2018
a32b741
[kernel]: update sonic linux kernel submodule
lguohan Jul 30, 2018
b8a01dc
[build]: add .gitignore for cel, delta and inventec
lguohan Aug 5, 2018
8e0f1f5
[celestica]: update dx010 fan driver to support fault alarm
lguohan Aug 5, 2018
7d13479
[celestica]: Add dx010 gpio sysfs exported when platform modules load.
lguohan Aug 5, 2018
3021e4e
[devices]: add celstica haliburton
lguohan Aug 5, 2018
aa2e340
[broadcom]: build broadcom kernel modules from gpl source codes
lguohan Aug 7, 2018
5d46e05
[devices]: move platform modules of accton, ingrasys, mitac, quanta i…
lguohan Aug 8, 2018
0338379
[devices]: enable ingress and ariata devices on barefoot platform
lguohan Aug 8, 2018
678d4d4
[mellanox]: Update SDK pointer (#41)
Aug 10, 2018
6a3c05f
[mellanox]: Update recipe for hw-mgmt according to latest changes (#40)
Aug 10, 2018
be0328a
Update arista-drivers submodules (#42)
Staphylo Aug 10, 2018
002bff4
[baseimage]: use rsyslog in baseimage from stretch repo
lguohan Aug 11, 2018
4005975
[submodules]: update submodule for platform modules dell, s6000 and k…
lguohan Aug 11, 2018
88ea503
[doc]: update build instruction for debian stretch build
lguohan Aug 11, 2018
7f7a2a0
[sshd]: regenerate ssh key if ssh_host_rsa_key is not present
lguohan Aug 11, 2018
66ffca2
[kernel]: set default option to build kernel
lguohan Aug 11, 2018
1533bc5
[dockerbase]: use libwrarp0 7.6.q-26 in docker base
lguohan Aug 12, 2018
8910c7e
update .gitignore
lguohan Aug 12, 2018
9e37d50
Merge pull request #1335 from lguohan/stretch
lguohan Aug 12, 2018
6246b16
[doc]: update build instruction for debian stretch
lguohan Aug 12, 2018
d761630
Fix potential blackholing/looping traffic when link-local was used an…
zhenggen-xu Aug 12, 2018
58db7f1
[device & platform] led and transceiver deamon for inventec switch d7…
klhaung Aug 12, 2018
eefd3f4
[platform]: update centec platform drivers and sai (#1702)
yangbashuang Aug 13, 2018
add2444
[barefoot]: build platform modules for bfn, bfn-montara, wnc-osw1800
lguohan Aug 13, 2018
647af39
[build]: create empty /var/lib/docker if needed (#1920)
lguohan Aug 13, 2018
f3ca7c4
[rsyslog]: use # to separate container name and program name in syslo…
lguohan Aug 13, 2018
0cd4ef0
[socat]: build socat with readline (#1919)
lguohan Aug 13, 2018
9047edc
[platform]: move dell platform modules into buildimage repo
lguohan Aug 13, 2018
859d0e1
[bcmsh]: add inactivity timeout for bcmsh (default 300 seconds) (#1921)
lguohan Aug 13, 2018
40bb27c
Simplify script to install docker (#1925)
qiluo-msft Aug 14, 2018
e15cf2d
[build]: print error message when use root or sudo to build. (#1923)
lguohan Aug 14, 2018
4547d9a
[nephos]: build platform modules in debian stretch docker
lguohan Aug 14, 2018
cdc2717
[submodule update]: sonic-quagga. Add dscp flag settings (#1926)
pavel-shirshov Aug 14, 2018
746ad96
[mellanox]: Fix post stop action in swss service template (#1928)
Aug 14, 2018
6918a22
[Inventec] Add D7264 platform support (#1675)
Aug 14, 2018
c4e2f3e
[mellanox]: Update hw-mgmt service with the stop action (#1929)
Aug 14, 2018
f0d4a07
[submodule] update snmpagent pointer (#1930)
mykolaf Aug 15, 2018
9f54545
Added picocom and pexpect to base image, for use in consutil (#1935)
cawand Aug 16, 2018
7d27660
[common]: Update sonic-swss-common submodule (#1934)
Aug 16, 2018
c1e17c3
[mellanox]: Fix qos.json.j2: apply qos config for active ports (#1932)
stepanblyschak Aug 16, 2018
38f3eba
[kernel]: upgrade kernel to 4.9.0-7 (4.9.110-3+deb9u1) (#1922)
lguohan Aug 16, 2018
cd9c5e7
Allow similar devices configs sharing (#1933)
stepanblyschak Aug 16, 2018
fd5bce5
[device/dx010] configuration port index start from 1 (#1927)
pphuchar Aug 16, 2018
986a857
[mellanox]: Fix problem with system EEPROM in "hw-mgmt" (#1938)
Aug 16, 2018
a8ccf58
[build]: Makefile: make new step "make stretch" optional (#1936)
yxieca Aug 16, 2018
86205b8
[devices/a7050]: Separate ECN/WRED profile per queue to maintain a co…
wendani Aug 17, 2018
ec8a7f5
[broadcom]: fix delay to load led proc init (#1940)
lguohan Aug 17, 2018
5a17a04
[mlnx-platform] enhancement for xcvrd implementation on mlnx platform…
keboliu Aug 17, 2018
c059d99
[baseimage]: install picocom 3.1 in base image (#1943)
lguohan Aug 17, 2018
f499254
[swsssdk]: update DBInterface submodule (#1942)
keboliu Aug 17, 2018
f05ee30
[sai]: upgrade SAI to version 1.3.3 (#1944)
lguohan Aug 17, 2018
98082d5
[baseimage]: Download picocom version 3.1-2 from stretch-backports; N…
jleveque Aug 18, 2018
4aa3f7a
[mellanox]: Fix system EEPROM for MSN2740 platform (#1950)
Aug 20, 2018
e7ef637
[config-bcm] move broadcom config files to device folder (#1947)
yxieca Aug 20, 2018
9413fa9
[interfaces]: Move IP/MTU information from interfaces file into datab…
Aug 20, 2018
d9527ec
[utilities]: Update sonic-utilities submodule (#1949)
Aug 20, 2018
4546905
[kernel]: upgrade kernel to 4.9.0-7 (4.9.110-3+deb9u2) (#1955)
qiluo-msft Aug 21, 2018
c692d2d
[baseimage]: Build specific revision of initramfs-tools (#1957)
qiluo-msft Aug 21, 2018
450cb04
[utilities]: Update sonic-utilities submodule (#1956)
Aug 21, 2018
788b20e
[arista]: Fix mount point discovery in boot0 for overlayfs (#1959)
Staphylo Aug 21, 2018
a01791e
[vs-test]: support python docker 3.5.0 (#1958)
lguohan Aug 21, 2018
de0e892
[arista] Fix arista-convertfs script (#1961)
yurypm Aug 21, 2018
d7be9a4
[kernel]: Update sonic-linux-kernel pointer (#1964)
Staphylo Aug 22, 2018
ada1140
[mellanox]: Fix sysfs path for PSU devices in psuutil plugin (#1966)
Aug 22, 2018
80c6453
[swss]: simplify swss systemd service file (#1965)
lguohan Aug 22, 2018
a5fd3be
[mellanox]: Enable WRED red color profile on mellanox platform (#1968)
wendani Aug 22, 2018
7eacb68
[baseimage]: update make file for initramfs-tools (#1967)
yxieca Aug 22, 2018
a990083
[dell]: Remove depmod -a from the platform initialization script (#1954)
Aug 23, 2018
27bdc00
[platform/device] - Update Haliburton platform modules and device con…
Aug 23, 2018
ad5b14c
[vs]: Add pip install six (#1978)
Aug 24, 2018
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ fs.*
target/
*.deb
*.changes
*.buildinfo

# Subdirectories in src
src/hiredis/*
Expand Down
29 changes: 6 additions & 23 deletions .gitmodules
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
[submodule "sonic-linux-kernel"]
path = src/sonic-linux-kernel
url = https://github.com/Azure/sonic-linux-kernel
branch = stretch
[submodule "sonic-sairedis"]
path = src/sonic-sairedis
url = https://github.com/Azure/sonic-sairedis
Expand Down Expand Up @@ -35,30 +36,15 @@
[submodule "src/sonic-utilities"]
path = src/sonic-utilities
url = https://github.com/Azure/sonic-utilities
[submodule "platform/broadcom/sonic-platform-modules-s6000"]
path = platform/broadcom/sonic-platform-modules-s6000
url = https://github.com/Azure/sonic-platform-modules-s6000
[submodule "platform/broadcom/sonic-platform-modules-arista"]
path = platform/broadcom/sonic-platform-modules-arista
url = https://github.com/aristanetworks/sonic
[submodule "platform/broadcom/sonic-platform-modules-dell"]
path = platform/broadcom/sonic-platform-modules-dell
url = https://github.com/Azure/sonic-platform-modules-dell
[submodule "platform/broadcom/sonic-platform-modules-ingrasys"]
path = platform/broadcom/sonic-platform-modules-ingrasys
url = https://github.com/Ingrasys-sonic/sonic-platform-modules-ingrasys
[submodule "src/sonic-platform-common"]
path = src/sonic-platform-common
url = https://github.com/Azure/sonic-platform-common
[submodule "src/sonic-platform-daemons"]
path = src/sonic-platform-daemons
url = https://github.com/Azure/sonic-platform-daemons
[submodule "platform/broadcom/sonic-platform-modules-accton"]
path = platform/broadcom/sonic-platform-modules-accton
url = https://github.com/edge-core/sonic-platform-modules-accton.git
[submodule "platform/broadcom/sonic-platform-modules-cel"]
path = platform/broadcom/sonic-platform-modules-cel
url = https://github.com/celestica-Inc/sonic-platform-modules-cel.git
[submodule "src/sonic-frr/frr"]
path = src/sonic-frr/frr
url = https://github.com/FRRouting/frr.git
Expand All @@ -71,12 +57,9 @@
[submodule "platform/nephos/sonic-platform-modules-ingrasys"]
path = platform/nephos/sonic-platform-modules-ingrasys
url = https://github.com/Ingrasys-sonic/sonic-platform-modules-ingrasys-nephos.git
[submodule "platform/broadcom/sonic-platform-modules-quanta"]
path = platform/broadcom/sonic-platform-modules-quanta
url = https://github.com/QuantaSwitchONIE/sonic-platform-modules-quanta.git
[submodule "platform/broadcom/sonic-platform-modules-mitac"]
path = platform/broadcom/sonic-platform-modules-mitac
url = https://github.com/MiTAC-EBU/sonic-platform-modules-mitac.git
[submodule "platform/p4/sonic-platform-modules-arista"]
path = platform/p4/sonic-platform-modules-arista
[submodule "platform/barefoot/sonic-platform-modules-arista"]
path = platform/barefoot/sonic-platform-modules-arista
url = https://github.com/aristanetworks/sonic
[submodule "platform/mellanox/hw-management/hw-mgmt"]
path = platform/mellanox/hw-management/hw-mgmt
url = https://github.com/Mellanox/hw-mgmt/
137 changes: 14 additions & 123 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,129 +1,20 @@
###############################################################################
## Wrapper for starting make inside sonic-slave container
#
# Supported parameters:
#
# * PLATFORM: Specific platform we wish to build images for.
# * BUILD_NUMBER: Desired version-number to pass to the building-system.
# * ENABLE_DHCP_GRAPH_SERVICE: Enables get-graph service to fetch minigraph files
# through http.
# * SHUTDOWN_BGP_ON_START: Sets admin-down state for all bgp peerings after restart.
# * ENABLE_PFCWD_ON_START: Enable PFC Watchdog (PFCWD) on server-facing ports
# * by default for TOR switch.
# * SONIC_ENABLE_SYNCD_RPC: Enables rpc-based syncd builds.
# * USERNAME: Desired username -- default at rules/config
# * PASSWORD: Desired password -- default at rules/config
# * KEEP_SLAVE_ON: Keeps slave container up after building-process concludes.
# * SOURCE_FOLDER: host path to be mount as /var/$(USER)/src, only effective when KEEP_SLAVE_ON=yes
# * SONIC_BUILD_JOB: Specifying number of concurrent build job(s) to run
#
###############################################################################
# SONiC make file

SHELL = /bin/bash

USER := $(shell id -un)
PWD := $(shell pwd)

# Remove lock file in case previous run was forcefully stopped
$(shell rm -f .screen)

MAKEFLAGS += -B

SLAVE_BASE_TAG = $(shell sha1sum sonic-slave/Dockerfile | awk '{print substr($$1,0,11);}')
SLAVE_TAG = $(shell cat sonic-slave/Dockerfile.user sonic-slave/Dockerfile | sha1sum | awk '{print substr($$1,0,11);}')
SLAVE_BASE_IMAGE = sonic-slave-base
SLAVE_IMAGE = sonic-slave-$(USER)

DOCKER_RUN := docker run --rm=true --privileged \
-v $(PWD):/sonic \
-w /sonic \
-e "http_proxy=$(http_proxy)" \
-e "https_proxy=$(https_proxy)" \
-i$(if $(TERM),t,)

DOCKER_BASE_BUILD = docker build --no-cache \
-t $(SLAVE_BASE_IMAGE) \
--build-arg http_proxy=$(http_proxy) \
--build-arg https_proxy=$(https_proxy) \
sonic-slave && \
docker tag $(SLAVE_BASE_IMAGE):latest $(SLAVE_BASE_IMAGE):$(SLAVE_BASE_TAG)

DOCKER_BUILD = docker build --no-cache \
--build-arg user=$(USER) \
--build-arg uid=$(shell id -u) \
--build-arg guid=$(shell id -g) \
--build-arg hostname=$(shell echo $$HOSTNAME) \
-t $(SLAVE_IMAGE) \
-f sonic-slave/Dockerfile.user \
sonic-slave && \
docker tag $(SLAVE_IMAGE):latest $(SLAVE_IMAGE):$(SLAVE_TAG)

SONIC_BUILD_INSTRUCTION := make \
-f slave.mk \
PLATFORM=$(PLATFORM) \
BUILD_NUMBER=$(BUILD_NUMBER) \
ENABLE_DHCP_GRAPH_SERVICE=$(ENABLE_DHCP_GRAPH_SERVICE) \
SHUTDOWN_BGP_ON_START=$(SHUTDOWN_BGP_ON_START) \
SONIC_ENABLE_PFCWD_ON_START=$(ENABLE_PFCWD_ON_START) \
ENABLE_SYNCD_RPC=$(ENABLE_SYNCD_RPC) \
PASSWORD=$(PASSWORD) \
USERNAME=$(USERNAME) \
SONIC_BUILD_JOBS=$(SONIC_BUILD_JOBS) \
HTTP_PROXY=$(http_proxy) \
HTTPS_PROXY=$(https_proxy) \
SONIC_ENABLE_SYSTEM_TELEMETRY=$(ENABLE_SYSTEM_TELEMETRY)

.PHONY: sonic-slave-build sonic-slave-bash init reset

.DEFAULT_GOAL := all
NOSTRETCH ?= 0

%::
@docker inspect --type image $(SLAVE_BASE_IMAGE):$(SLAVE_BASE_TAG) &> /dev/null || \
{ echo Image $(SLAVE_BASE_IMAGE):$(SLAVE_BASE_TAG) not found. Building... ; \
$(DOCKER_BASE_BUILD) ; }
@docker inspect --type image $(SLAVE_IMAGE):$(SLAVE_TAG) &> /dev/null || \
{ echo Image $(SLAVE_IMAGE):$(SLAVE_TAG) not found. Building... ; \
$(DOCKER_BUILD) ; }
ifeq "$(KEEP_SLAVE_ON)" "yes"
ifdef SOURCE_FOLDER
@$(DOCKER_RUN) -v $(SOURCE_FOLDER):/var/$(USER)/src $(SLAVE_IMAGE):$(SLAVE_TAG) bash -c "$(SONIC_BUILD_INSTRUCTION) $@; /bin/bash"
else
@$(DOCKER_RUN) $(SLAVE_IMAGE):$(SLAVE_TAG) bash -c "$(SONIC_BUILD_INSTRUCTION) $@; /bin/bash"
endif
else
@$(DOCKER_RUN) $(SLAVE_IMAGE):$(SLAVE_TAG) $(SONIC_BUILD_INSTRUCTION) $@
@echo "+++ --- Making $@ --- +++"
ifeq ($(NOSTRETCH), 0)
BLDENV=stretch make -f Makefile.work stretch
endif
make -f Makefile.work $@

sonic-slave-build :
$(DOCKER_BASE_BUILD)
$(DOCKER_BUILD)

sonic-slave-bash :
@docker inspect --type image $(SLAVE_BASE_IMAGE):$(SLAVE_BASE_TAG) &> /dev/null || \
{ echo Image $(SLAVE_BASE_IMAGE):$(SLAVE_BASE_TAG) not found. Building... ; \
$(DOCKER_BASE_BUILD) ; }
@docker inspect --type image $(SLAVE_IMAGE):$(SLAVE_TAG) &> /dev/null || \
{ echo Image $(SLAVE_IMAGE):$(SLAVE_TAG) not found. Building... ; \
$(DOCKER_BUILD) ; }
@$(DOCKER_RUN) -t $(SLAVE_IMAGE):$(SLAVE_TAG) bash

showtag:
@echo $(SLAVE_IMAGE):$(SLAVE_TAG)
@echo $(SLAVE_BASE_IMAGE):$(SLAVE_BASE_TAG)

init :
@git submodule update --init --recursive
@git submodule foreach --recursive '[ -f .git ] && echo "gitdir: $$(realpath --relative-to=. $$(cut -d" " -f2 .git))" > .git'
stretch:
@echo "+++ Making $@ +++"
ifeq ($(NOSTRETCH), 0)
BLDENV=stretch make -f Makefile.work stretch
endif

reset :
@echo && echo -n "Warning! All local changes will be lost. Proceed? [y/N]: "
@read ans && \
if [ $$ans == y ]; then \
git clean -xfdf; \
git reset --hard; \
git submodule foreach --recursive git clean -xfdf; \
git submodule foreach --recursive git reset --hard; \
git submodule update --init --recursive;\
else \
echo "Reset aborted"; \
fi
clean reset init configure showtag sonic-slave-build sonic-slave-bash :
@echo "+++ Making $@ +++"
make -f Makefile.work $@
147 changes: 147 additions & 0 deletions Makefile.work
Original file line number Diff line number Diff line change
@@ -0,0 +1,147 @@
###############################################################################
## Wrapper for starting make inside sonic-slave container
#
# Supported parameters:
#
# * PLATFORM: Specific platform we wish to build images for.
# * BUILD_NUMBER: Desired version-number to pass to the building-system.
# * ENABLE_DHCP_GRAPH_SERVICE: Enables get-graph service to fetch minigraph files
# through http.
# * SHUTDOWN_BGP_ON_START: Sets admin-down state for all bgp peerings after restart.
# * ENABLE_PFCWD_ON_START: Enable PFC Watchdog (PFCWD) on server-facing ports
# * by default for TOR switch.
# * SONIC_ENABLE_SYNCD_RPC: Enables rpc-based syncd builds.
# * USERNAME: Desired username -- default at rules/config
# * PASSWORD: Desired password -- default at rules/config
# * KEEP_SLAVE_ON: Keeps slave container up after building-process concludes.
# * SOURCE_FOLDER: host path to be mount as /var/$(USER)/src, only effective when KEEP_SLAVE_ON=yes
# * SONIC_BUILD_JOBS: Specifying number of concurrent build job(s) to run
# * KERNEL_PROCURE_METHOD: Specifying method of obtaining kernel Debian package: download or build
#
###############################################################################

SHELL = /bin/bash

USER := $(shell id -un)
PWD := $(shell pwd)

ifeq ($(USER), root)
$(error Add your user account to docker group and use your user account to make. root or sudo are not supported!)
endif

# Remove lock file in case previous run was forcefully stopped
$(shell rm -f .screen)

MAKEFLAGS += -B

ifeq ($(BLDENV), stretch)
SLAVE_BASE_TAG = $(shell sha1sum sonic-slave-stretch/Dockerfile | awk '{print substr($$1,0,11);}')
SLAVE_TAG = $(shell cat sonic-slave-stretch/Dockerfile.user sonic-slave-stretch/Dockerfile | sha1sum | awk '{print substr($$1,0,11);}')
SLAVE_BASE_IMAGE = sonic-slave-stretch-base
SLAVE_IMAGE = sonic-slave-stretch-$(USER)
SLAVE_DIR = sonic-slave-stretch
else
SLAVE_BASE_TAG = $(shell sha1sum sonic-slave/Dockerfile | awk '{print substr($$1,0,11);}')
SLAVE_TAG = $(shell cat sonic-slave/Dockerfile.user sonic-slave/Dockerfile | sha1sum | awk '{print substr($$1,0,11);}')
SLAVE_BASE_IMAGE = sonic-slave-base
SLAVE_IMAGE = sonic-slave-$(USER)
SLAVE_DIR = sonic-slave
endif

INSMOD_OVERLAY := sudo modprobe overlay
DOCKER_RUN := docker run --rm=true --privileged \
-v $(PWD):/sonic \
-w /sonic \
-e "http_proxy=$(http_proxy)" \
-e "https_proxy=$(https_proxy)" \
-i$(if $(TERM),t,)

DOCKER_BASE_BUILD = docker build --no-cache \
-t $(SLAVE_BASE_IMAGE) \
--build-arg http_proxy=$(http_proxy) \
--build-arg https_proxy=$(https_proxy) \
$(SLAVE_DIR) && \
docker tag $(SLAVE_BASE_IMAGE):latest $(SLAVE_BASE_IMAGE):$(SLAVE_BASE_TAG)

DOCKER_BUILD = docker build --no-cache \
--build-arg user=$(USER) \
--build-arg uid=$(shell id -u) \
--build-arg guid=$(shell id -g) \
--build-arg hostname=$(shell echo $$HOSTNAME) \
-t $(SLAVE_IMAGE) \
-f $(SLAVE_DIR)/Dockerfile.user \
$(SLAVE_DIR) && \
docker tag $(SLAVE_IMAGE):latest $(SLAVE_IMAGE):$(SLAVE_TAG)

SONIC_BUILD_INSTRUCTION := make \
-f slave.mk \
PLATFORM=$(PLATFORM) \
BUILD_NUMBER=$(BUILD_NUMBER) \
ENABLE_DHCP_GRAPH_SERVICE=$(ENABLE_DHCP_GRAPH_SERVICE) \
SHUTDOWN_BGP_ON_START=$(SHUTDOWN_BGP_ON_START) \
SONIC_ENABLE_PFCWD_ON_START=$(ENABLE_PFCWD_ON_START) \
ENABLE_SYNCD_RPC=$(ENABLE_SYNCD_RPC) \
PASSWORD=$(PASSWORD) \
USERNAME=$(USERNAME) \
SONIC_BUILD_JOBS=$(SONIC_BUILD_JOBS) \
KERNEL_PROCURE_METHOD=$(KERNEL_PROCURE_METHOD) \
HTTP_PROXY=$(http_proxy) \
HTTPS_PROXY=$(https_proxy) \
SONIC_ENABLE_SYSTEM_TELEMETRY=$(ENABLE_SYSTEM_TELEMETRY)

.PHONY: sonic-slave-build sonic-slave-bash init reset

.DEFAULT_GOAL := all

%::
@docker inspect --type image $(SLAVE_BASE_IMAGE):$(SLAVE_BASE_TAG) &> /dev/null || \
{ echo Image $(SLAVE_BASE_IMAGE):$(SLAVE_BASE_TAG) not found. Building... ; \
$(DOCKER_BASE_BUILD) ; }
@docker inspect --type image $(SLAVE_IMAGE):$(SLAVE_TAG) &> /dev/null || \
{ echo Image $(SLAVE_IMAGE):$(SLAVE_TAG) not found. Building... ; \
$(DOCKER_BUILD) ; }
@$(INSMOD_OVERLAY)
ifeq "$(KEEP_SLAVE_ON)" "yes"
ifdef SOURCE_FOLDER
@$(DOCKER_RUN) -v $(SOURCE_FOLDER):/var/$(USER)/src $(SLAVE_IMAGE):$(SLAVE_TAG) bash -c "$(SONIC_BUILD_INSTRUCTION) $@; /bin/bash"
else
@$(DOCKER_RUN) $(SLAVE_IMAGE):$(SLAVE_TAG) bash -c "$(SONIC_BUILD_INSTRUCTION) $@; /bin/bash"
endif
else
@$(DOCKER_RUN) $(SLAVE_IMAGE):$(SLAVE_TAG) $(SONIC_BUILD_INSTRUCTION) $@
endif

sonic-slave-build :
$(DOCKER_BASE_BUILD)
$(DOCKER_BUILD)

sonic-slave-bash :
@docker inspect --type image $(SLAVE_BASE_IMAGE):$(SLAVE_BASE_TAG) &> /dev/null || \
{ echo Image $(SLAVE_BASE_IMAGE):$(SLAVE_BASE_TAG) not found. Building... ; \
$(DOCKER_BASE_BUILD) ; }
@docker inspect --type image $(SLAVE_IMAGE):$(SLAVE_TAG) &> /dev/null || \
{ echo Image $(SLAVE_IMAGE):$(SLAVE_TAG) not found. Building... ; \
$(DOCKER_BUILD) ; }
@$(INSMOD_OVERLAY)
@$(DOCKER_RUN) -t $(SLAVE_IMAGE):$(SLAVE_TAG) bash

showtag:
@echo $(SLAVE_IMAGE):$(SLAVE_TAG)
@echo $(SLAVE_BASE_IMAGE):$(SLAVE_BASE_TAG)

init :
@git submodule update --init --recursive
@git submodule foreach --recursive '[ -f .git ] && echo "gitdir: $$(realpath --relative-to=. $$(cut -d" " -f2 .git))" > .git'

reset :
@echo && echo -n "Warning! All local changes will be lost. Proceed? [y/N]: "
@read ans && \
if [ $$ans == y ]; then \
git clean -xfdf; \
git reset --hard; \
git submodule foreach --recursive git clean -xfdf; \
git submodule foreach --recursive git reset --hard; \
git submodule update --init --recursive;\
else \
echo "Reset aborted"; \
fi
14 changes: 11 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
*master*: Broadcom: [![Broadcom](https://sonic-jenkins.westus2.cloudapp.azure.com/job/broadcom/job/buildimage-brcm-all/badge/icon)](https://sonic-jenkins.westus2.cloudapp.azure.com/job/broadcom/job/buildimage-brcm-all)
*master*:
Barefoot: [![Barefoot](https://sonic-jenkins.westus2.cloudapp.azure.com/job/barefoot/job/buildimage-bf-all/badge/icon)](https://sonic-jenkins.westus2.cloudapp.azure.com/job/barefoot/job/buildimage-bf-all)
Broadcom: [![Broadcom](https://sonic-jenkins.westus2.cloudapp.azure.com/job/broadcom/job/buildimage-brcm-all/badge/icon)](https://sonic-jenkins.westus2.cloudapp.azure.com/job/broadcom/job/buildimage-brcm-all)
Mellanox: [![Mellanox](https://sonic-jenkins.westus2.cloudapp.azure.com/job/mellanox/job/buildimage-mlnx-all/badge/icon)](https://sonic-jenkins.westus2.cloudapp.azure.com/job/mellanox/job/buildimage-mlnx-all)
Nephos: [![Nephos](https://sonic-jenkins.westus2.cloudapp.azure.com/job/nephos/job/buildimage-nephos-all/badge/icon)](https://sonic-jenkins.westus2.cloudapp.azure.com/job/nephos/job/buildimage-nephos-all)
P4: [![P4](https://sonic-jenkins.westus2.cloudapp.azure.com/job/p4/job/buildimage-p4-all/badge/icon)](https://sonic-jenkins.westus2.cloudapp.azure.com/job/p4/job/buildimage-p4-all)
Expand Down Expand Up @@ -56,7 +58,11 @@ To build SONiC installer image and docker images, run the following commands:
# Execute make configure once to configure ASIC
make configure PLATFORM=[ASIC_VENDOR]

make
# build debian stretch required targets (optional)
BLDENV=stretch make stretch

# build SONiC image
make all

**NOTE**:

Expand All @@ -78,11 +84,13 @@ The SONiC installer contains all docker images needed. SONiC uses one image for
For Broadcom ASIC, we build ONIE and EOS image. EOS image is used for Arista devices, ONIE image is used for all other Broadcom ASIC based devices.

make configure PLATFORM=broadcom
# build debian stretch required targets
BLDENV=stretch make stretch
# build ONIE image
make target/sonic-broadcom.bin
# build EOS image
make target/sonic-aboot-broadcom.swi

You may find the rules/config file useful. It contains configuration options for the build process, like adding more verbosity or showing dependencies, username and password for base image etc.

Every docker image is built and saved to target/ directory.
Expand Down
Loading