Merge lp:~martin-nowack/maas/fix-enlistment into lp:maas/trunk

Proposed by Martin Nowack on 2015-02-26
Status: Merged
Approved by: Andres Rodriguez on 2015-02-26
Approved revision: 3560
Merged at revision: 3569
Proposed branch: lp:~martin-nowack/maas/fix-enlistment
Merge into: lp:maas/trunk
Diff against target: 16 lines (+2/-2)
1 file modified
etc/maas/templates/commissioning-user-data/snippets/maas_enlist.sh (+2/-2)
To merge this branch: bzr merge lp:~martin-nowack/maas/fix-enlistment
Reviewer Review Type Date Requested Status
Andres Rodriguez 2015-02-26 Approve on 2015-02-26
Review via email: mp+251099@code.launchpad.net

Commit message

Fix incorrect handling of '-' in dns name during enlistment.

To post a comment you must log in.
Andres Rodriguez (andreserl) wrote :

lgtm!

review: Approve
MAAS Lander (maas-lander) wrote :
Download full text (27.0 KiB)

The attempt to merge lp:~martin-nowack/maas/fix-enlistment into lp:maas failed. Below is the output from the failed tests.

Ign http://security.ubuntu.com trusty-security InRelease
Ign http://nova.clouds.archive.ubuntu.com trusty InRelease
Hit http://security.ubuntu.com trusty-security Release.gpg
Hit http://security.ubuntu.com trusty-security Release
Ign http://nova.clouds.archive.ubuntu.com trusty-updates InRelease
Hit http://nova.clouds.archive.ubuntu.com trusty Release.gpg
Hit http://nova.clouds.archive.ubuntu.com trusty-updates Release.gpg
Hit http://nova.clouds.archive.ubuntu.com trusty Release
Hit http://nova.clouds.archive.ubuntu.com trusty-updates Release
Hit http://security.ubuntu.com trusty-security/main Sources
Hit http://security.ubuntu.com trusty-security/universe Sources
Hit http://security.ubuntu.com trusty-security/main amd64 Packages
Hit http://nova.clouds.archive.ubuntu.com trusty/main Sources
Hit http://security.ubuntu.com trusty-security/universe amd64 Packages
Hit http://security.ubuntu.com trusty-security/main Translation-en
Hit http://nova.clouds.archive.ubuntu.com trusty/universe Sources
Hit http://security.ubuntu.com trusty-security/universe Translation-en
Hit http://nova.clouds.archive.ubuntu.com trusty/main amd64 Packages
Hit http://nova.clouds.archive.ubuntu.com trusty/universe amd64 Packages
Hit http://nova.clouds.archive.ubuntu.com trusty/main Translation-en
Hit http://nova.clouds.archive.ubuntu.com trusty/universe Translation-en
Hit http://nova.clouds.archive.ubuntu.com trusty-updates/main Sources
Hit http://nova.clouds.archive.ubuntu.com trusty-updates/universe Sources
Hit http://nova.clouds.archive.ubuntu.com trusty-updates/main amd64 Packages
Hit http://nova.clouds.archive.ubuntu.com trusty-updates/universe amd64 Packages
Hit http://nova.clouds.archive.ubuntu.com trusty-updates/main Translation-en
Hit http://nova.clouds.archive.ubuntu.com trusty-updates/universe Translation-en
Ign http://nova.clouds.archive.ubuntu.com trusty/main Translation-en_US
Ign http://nova.clouds.archive.ubuntu.com trusty/universe Translation-en_US
Reading package lists...
sudo DEBIAN_FRONTEND=noninteractive apt-get -y \
     --no-install-recommends install apache2 authbind bind9 bind9utils build-essential bzr-builddeb chromium-browser chromium-chromedriver curl daemontools debhelper dh-apport distro-info dnsutils firefox freeipmi-tools gjs ipython isc-dhcp-common libjs-angularjs libjs-jquery libjs-raphael libjs-yui3-full libjs-yui3-min libpq-dev make nodejs-legacy npm pep8 postgresql pyflakes python-bson python-bzrlib python-convoy python-crochet python-cssselect python-curtin python-dev python-distro-info python-django python-django-piston python-django-south python-djorm-ext-pgarray python-docutils python-extras python-fixtures python-flake8 python-formencode python-hivex python-httplib2 python-iscpy python-jinja2 python-jsonschema python-lockfile python-lxml python-mock python-netaddr python-netifaces python-nose python-oauth python-openssl python-paramiko python-pexpect python-pip python-pocket-lint python-psycopg2 python-pyinotify python-pyparsing python-pyscss python-seamicroclient python-simplejson python-simplestreams python-...

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'etc/maas/templates/commissioning-user-data/snippets/maas_enlist.sh'
2--- etc/maas/templates/commissioning-user-data/snippets/maas_enlist.sh 2015-01-15 01:36:33 +0000
3+++ etc/maas/templates/commissioning-user-data/snippets/maas_enlist.sh 2015-02-26 15:25:12 +0000
4@@ -199,10 +199,10 @@
5 serverurl="maas.local"
6 servername="$serverurl"
7 fi
8-if echo "$serverurl" | egrep -q '(^[a-z]+://|^)[a-z0-9\.]+($|/$)'; then
9+if echo "$serverurl" | egrep -q '(^[a-z]+://|^)[a-z0-9\.\-]+($|/$)'; then
10 api_url="MAAS/api/1.0/nodes/"
11 else
12- api_url=`echo $serverurl | sed 's#^\(\|[a-z]\+://\)[a-zA-Z0-9\.]\+\(\|\:[0-9]\+\)/##'`
13+ api_url=`echo $serverurl | sed 's#^\(\|[a-z]\+://\)[a-zA-Z0-9\.\-]\+\(\|\:[0-9]\+\)/##'`
14 fi
15
16 #TODO: Auto-detect hostname?