L2 Cache

Behold the power of |!

User Tools

Site Tools



This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
snipets:solaris:build-zone [2014/09/30 19:37]
sjorge [packages]
snipets:solaris:build-zone [2014/10/09 22:02] (current)
Line 49: Line 49:
 </​code>​ </​code>​
 +Enable sendmail so you get local maildrop
 +<code bash>
 +svcadm enable svc:/​network/​smtp:​sendmail
 ===== illumos-omnios environment ===== ===== illumos-omnios environment =====
 :!: don't forget to set the correct the USER in the paths! :!: don't forget to set the correct the USER in the paths!
Line 176: Line 180:
 # #
 PKGARCHIVE="​${PARENT_WS}/​packages/​${MACH}/​nightly"; ​    ​export PKGARCHIVE PKGARCHIVE="​${PARENT_WS}/​packages/​${MACH}/​nightly"; ​    ​export PKGARCHIVE
-PKGPUBLISHER_REDIST="​on-nightly"; ​                    ​export PKGPUBLISHER_REDIST+PKGPUBLISHER_REDIST="​testing"; ​                    ​export PKGPUBLISHER_REDIST
 # PKGPUBLISHER_NONREDIST="​on-extra"; ​                   export PKGPUBLISHER_NONREDIST # PKGPUBLISHER_NONREDIST="​on-extra"; ​                   export PKGPUBLISHER_NONREDIST
Line 253: Line 257:
 </​file>​ </​file>​
 +===== user profile =====
 +You probably want to tweak your user profile for whatever shell you are using.
 +I ''​source ~/​illumos-omnios.env''​ inside my .zshrc, I also update my path with ''​
 +export PATH=$PATH:/​opt/​onbld/​bin:​~/​.bin''​
 +===== extra helper scripts =====
 +==== pserv (thanks richlowe) ====
 +<file bash /​export/​home/​USER/​.bin/​pserv>​
 +source ~/​illumos-omnios.env
 +while getopts dp: opt; do
 +case $opt in
 +d) REPODIR=nightly;;​
 +shift $(($OPTIND - 1))
 +WS=$(cd $1; pwd)
 +/​usr/​lib/​pkg.depotd -d $PARENT_WS/​packages/​$(mach)/​$REPODIR/​repo.redist -p $PORT \
 +  --readonly --log-access=none
 +===== building using nightly =====
 +It takes about 2h for me so I run inside a tmux session.
 +<code bash>
 +# build the nightly and nightly-nd repositories (no output! but you should get an e-mail if you set STAFFER)
 +nightly illumos-omnios.env
 +# serv said repositories
 +===== testing the stuff =====
 +I use a vm that pxe boots with the following kayak config.
 +<code bash kayak_cfg>​
 +### configuration
 +## rpool
 +BuildRpool c1t0d0
 +SetHostname omnios-nightly
 +SetTimezone Europe/​Brussels
 +RootPW '​$5$o.b1VKc/​$GgHl.du5uL6CYm6pRqRR7Lifj92CcBq.qDEAKUXZL21'​
 +Postboot '/​usr/​sbin/​bootadm set-menu timeout=5'​
 +## network
 +# dynamic ip address
 +Postboot '/​sbin/​ipadm create-if e1000g0'​
 +Postboot '/​sbin/​ipadm create-addr -T dhcp e1000g0/​v4'​
 +# dns
 +EnableDNS example.org
 +## add publishers
 +## onu testing automation
 +Postboot '/​usr/​gnu/​bin/​sed -i "​s/​PermitRootLogin no/​PermitRootLogin yes/g" /​etc/​ssh/​sshd_config'​
 +Postboot '/​usr/​bin/​pkg install --no-backup-be pkg:/​developer/​build/​onbld'​
 +Postboot '/​usr/​sbin/​svcadm disable svc:/​network/​sendmail-client:​default'​
 +Postboot '/​opt/​onbld/​bin/​onu -v -u http://​leonov.example.org:​9001 -U testing -t omnios-testing'​
 +Postboot '/​usr/​sbin/​beadm unmount omnios-testing'​
 +Postboot '/​usr/​sbin/​beadm mount omnios-testing /a'
 +Postboot '/​usr/​gnu/​bin/​rm /​a/​.initialboot'​
 +Postboot '/​usr/​sbin/​shutdown -i6 -g0 -y'
 +On the initial boot it will install onu and create a new BE populated with the updated packages and reboot. It will then drop you in the new system running a freshly build gate :)
snipets/solaris/build-zone.1412098634.txt.gz · Last modified: 2014/10/09 22:02 (external edit)