From owner-freebsd-current@FreeBSD.ORG Fri Sep 7 12:03:10 2012 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F2918106564A for ; Fri, 7 Sep 2012 12:03:09 +0000 (UTC) (envelope-from ivoras@gmail.com) Received: from mail-vb0-f54.google.com (mail-vb0-f54.google.com [209.85.212.54]) by mx1.freebsd.org (Postfix) with ESMTP id 9E0068FC2B for ; Fri, 7 Sep 2012 12:03:09 +0000 (UTC) Received: by vbmv11 with SMTP id v11so4265803vbm.13 for ; Fri, 07 Sep 2012 05:03:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; bh=LQ6AoeoH+wZbxdpW8jnJSpYzzs9HfacXrnLFooXky+8=; b=AEeJ6iqljNV90loN8nCCIoDmX3LKKMZ/aXZUWc5ZPRzjVsmu5PhihMIXGlvQjDjOub 2ocWFpWXvTrAwNKNf+zRGbhlIiClVaBoI3ZJU9FCJQ8Vm5aacXWW33BROZn7P7DtZcYU oJewBlbGm82bAAV1fnEAM8bbTTSnHUzHvco3NG0bqCwO4JE1R28dGnt9zgQsuKrPpMIQ 6cAiFqLpCCn0219pb1tF/lBHkynTGabfM65xwIE+UTt6vpzgKS/VQ/GcNP3y9HinPSYH 1WcHDDQ9hn6z7wUMvTvNj5MyAVF0gnhZobMZAzuMHs3C0VBYulUmYdVAFzzfaADyE5Z8 T3Lg== Received: by 10.221.10.13 with SMTP id oy13mr6919217vcb.14.1347019388881; Fri, 07 Sep 2012 05:03:08 -0700 (PDT) MIME-Version: 1.0 Sender: ivoras@gmail.com Received: by 10.59.0.37 with HTTP; Fri, 7 Sep 2012 05:02:28 -0700 (PDT) In-Reply-To: <5049E060.9020602@infracaninophile.co.uk> References: <20120830141939.GJ64447@ithaqua.etoilebsd.net> <5048D2EC.70109@FreeBSD.org> <5049E060.9020602@infracaninophile.co.uk> From: Ivan Voras Date: Fri, 7 Sep 2012 14:02:28 +0200 X-Google-Sender-Auth: P0uIOEdPEHGAXl4MazSs6cuGWdo Message-ID: To: Matthew Seaman Content-Type: text/plain; charset=UTF-8 Cc: freebsd-current@freebsd.org Subject: Re: pkg (aka pkgng) 1.0 released X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Sep 2012 12:03:10 -0000 On 7 September 2012 13:54, Matthew Seaman wrote: > On 09/07/12 12:30, Ivan Voras wrote: >> On 06/09/2012 18:44, Matthew Seaman wrote: >>> On 06/09/2012 16:37, Ivan Voras wrote: >> >>>> Hi, >>>> >>>> It looks like the pkg port installs pkg.conf.sample with the line: >>>> >>>> PACKAGESITE : http://pkg.freebsd.org/${ABI}/latest >>>> >>>> ... which is finally a good step in the direction of making pkgng >>>> working by default, except that the "pkg.freebsd.org" site doesn't exist >>>> in DNS. Instead, pkgbeta.freebsd.org still exists. I suppose one should >>>> be a DNS CNAME for the other? >>> >>> It's a SRV record: >>> >>> seedling:~:% dig +short IN SRV _http._tcp.pkg.freebsd.org >>> 10 10 80 pkgbeta.FreeBSD.org. >> >> Hi, >> >> What are the benefits of doing it this way? > > Yeah -- it's a bit OTT right now given there's just the one publicly > available pkg repository available. It will pay off later when there > are more pkg repositories available -- repositories can be added to (or > removed from) the list in the SRV record without end-users having to > know the details. > > It may also be possible to replicate what portupdate has done and use > geolocation based services to steer end users to a nearby repository > site automatically. Ok, but all that can be done the "normal" way with A records. As far as I can tell, the intended benefits of the SRV record system is to disentangle services and hosts, so that, e.g. the same user-visible DNS name (e.g. "pkg.freebsd.org") resolves to a different host if asked for the HTTP service and the FTP service. I suppose this could work in FreeBSD's case if the record was created differently, instad of the "normal" _http._tcp record, introduce a new one, e.g. _pkgng._tcp, so when a web browser visits "pkg.freebsd.org" it gets a regular web page or some other user-visible content, and the specially made pkg client will resolve it to another service and another (possibly) server. This also can be done without the SRV record, by e.g. inspecting client's HTTP headers. I'm not saying that the SRV record is technically wrong in this case, I just don't see how is it useful (and surely there will be others trying to ping "pkg.freebsd.org" and complaining when it fails to resolve).