pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: pbulk with read-only pkgsrc

After some digging I came to the conclusion that does not use the mk-fragement when bootstraping for pbulk :

     64 # Deploying pbulk packages:
     65 # - bootstrapping
     66 cat >${TMPDIR}/ <<EOF
     67 PKG_DEVELOPER=  yes
     68 EOF
     70 ${PKGSRCDIR}/bootstrap/bootstrap \
     71   ${unprivileged:+--unprivileged} \
     72   --mk-fragment=${TMPDIR}/ \
     73   --prefix=${PBULKPREFIX} \
     74   --workdir=${PBULKWORK}
     75 rm -rf ${PBULKWORK}
     76 rm -f ${TMPDIR}/

So I tried to manually bootstrap pkgsrc for pbulk using this command :

 bootstrap command: /usr/pkgsrc/bootstrap/bootstrap --prefix=/usr/pbulk --workdir=/tmp/work-pbulk --mk-fragment=/srv/pkgsrc/conf/mk.conf.frag

My mk.conf.frag is readable and belong to pbulk user even if not running a unpriviliged pbulk :

nbqc1-sparc6# su - pbulk
nbqc1-sparc6$ ls -lh /srv/pkgsrc/conf/mk.conf.frag
-rw-r--r--  1 pbulk  wheel  222B Oct 12 01:22 /srv/pkgsrc/conf/mk.conf.frag
nbqc1-sparc6$ cat /srv/pkgsrc/conf/mk.conf.frag
# Can be remote
# Must be local
nbqc1-sparc6$ whoami

Even with that configuration bootrap fails. It simply seems to ignore my mk.conf.frag :

nbqc1-sparc6# grep "bootstrap command" nohup.out.13
===> bootstrap command: /usr/pkgsrc/bootstrap/bootstrap --prefix=/usr/pbulk --workdir=/tmp/work-pbulk --mk-fragment=/srv/pkgsrc/conf/mk.conf.frag
nbqc1-sparc6# tail -15 nohup.out.13
=> Checking file-check results for cwrappers-20180325
=> Creating binary package /tmp/work-pbulk/wrk/pkgtools/cwrappers/work/.packages/cwrappers-20180325.tgz
===> Building binary package for cwrappers-20180325
=> Creating binary package /usr/pkgsrc/packages/All/cwrappers-20180325.tgz
mkdir: /usr/pkgsrc/packages/All: Read-only file system
*** Error code 1
bmake[1]: stopped in /usr/pkgsrc/pkgtools/cwrappers
*** Error code 1
bmake: stopped in /usr/pkgsrc/pkgtools/cwrappers
===> exited with status 1

I also tryied with env variables like this (mk.conf.frag remained untouched) : 

env PKG_DEVELOPER=yes DISTDIR=/srv/pkgsrc/distfiles PACKAGES=/srv/pkgsrc/packages WRKOBJDIR=/var/tmp/pkgbuild /usr/pkgsrc/bootstrap/bootstrap --prefix=/usr/pbulk --workdir=/tmp/work-pbulk --mk-fragment=/srv/pkgsrc/conf/mk.conf.frag  

Always end up with the same error. 
This method seems to be used by the community. I must have done some silly mistakes somewhere or missing something obvious...

On Wed, Oct 10, 2018 at 4:34 AM Jonathan Perkin <> wrote:
* On 2018-10-10 at 07:16 BST, Julien Savard wrote:

> Just wanted to know of it's still possible to run on pbulk with
> multiple architectures all using the pkgsrc tree mounted as read
> only ?

Yes, this should work.  I use it for all my builds.

> PACKAGES=/srv/pkgsrc/packages
> WRKOBJDIR=/var/tmp/pkgbuild

Neither of those settings match this output:

> => Creating binary package
> /tmp/work-pbulk/wrk/pkgtools/cwrappers/work/.packages/cwrappers-20180325.tgz
> ===> Building binary package for cwrappers-20180325
> => Creating binary package /usr/pkgsrc/packages/All/cwrappers-20180325.tgz

so you'll need to figure out why your mk.conf fragment isn't being
used.  I don't use so I'm not sure how it handles that,
sorry.  However, /tmp/work-pbulk isn't a standard directory, so it's
probably worth finding where that is set in your configuration and
going from there.

Jonathan Perkin  -  Joyent, Inc.  -

Home | Main Index | Thread Index | Old Index