Date: Wednesday, September 13, 2017 @ 15:57:55 Author: foxxx0 Revision: 257443
archrelease: copy trunk to community-i686, community-x86_64 Added: consul/repos/community-i686/PKGBUILD (from rev 257442, consul/trunk/PKGBUILD) consul/repos/community-i686/consul.default (from rev 257442, consul/trunk/consul.default) consul/repos/community-i686/consul.install (from rev 257442, consul/trunk/consul.install) consul/repos/community-i686/consul.service (from rev 257442, consul/trunk/consul.service) consul/repos/community-i686/consul.sysusers (from rev 257442, consul/trunk/consul.sysusers) consul/repos/community-i686/disable-broken-api-test.patch (from rev 257442, consul/trunk/disable-broken-api-test.patch) consul/repos/community-i686/example.json (from rev 257442, consul/trunk/example.json) consul/repos/community-x86_64/PKGBUILD (from rev 257442, consul/trunk/PKGBUILD) consul/repos/community-x86_64/consul.default (from rev 257442, consul/trunk/consul.default) consul/repos/community-x86_64/consul.install (from rev 257442, consul/trunk/consul.install) consul/repos/community-x86_64/consul.service (from rev 257442, consul/trunk/consul.service) consul/repos/community-x86_64/consul.sysusers (from rev 257442, consul/trunk/consul.sysusers) consul/repos/community-x86_64/disable-broken-api-test.patch (from rev 257442, consul/trunk/disable-broken-api-test.patch) consul/repos/community-x86_64/example.json (from rev 257442, consul/trunk/example.json) Deleted: consul/repos/community-i686/PKGBUILD consul/repos/community-i686/consul.service consul/repos/community-x86_64/PKGBUILD consul/repos/community-x86_64/consul.service ------------------------------------------------+ /PKGBUILD | 144 +++++++++++++++++++++++ /consul.service | 32 +++++ community-i686/PKGBUILD | 45 ------- community-i686/consul.default | 1 community-i686/consul.install | 9 + community-i686/consul.service | 14 -- community-i686/consul.sysusers | 1 community-i686/disable-broken-api-test.patch | 118 ++++++++++++++++++ community-i686/example.json | 7 + community-x86_64/PKGBUILD | 45 ------- community-x86_64/consul.default | 1 community-x86_64/consul.install | 9 + community-x86_64/consul.service | 14 -- community-x86_64/consul.sysusers | 1 community-x86_64/disable-broken-api-test.patch | 118 ++++++++++++++++++ community-x86_64/example.json | 7 + 16 files changed, 448 insertions(+), 118 deletions(-) Deleted: community-i686/PKGBUILD =================================================================== --- community-i686/PKGBUILD 2017-09-13 15:51:31 UTC (rev 257442) +++ community-i686/PKGBUILD 2017-09-13 15:57:55 UTC (rev 257443) @@ -1,45 +0,0 @@ -# $Id$ -# Maintainer: Felix Yan <felixonm...@archlinux.org> - -pkgname=consul -pkgver=0.8.4 -pkgrel=1 -pkgdesc="A tool for service discovery, monitoring and configuration." -arch=('i686' 'x86_64') -url="https://www.consul.io" -license=('MPL') -depends=('glibc') -makedepends=('git' 'go') -source=("$pkgname-$pkgver.tar.gz::https://github.com/hashicorp/consul/archive/v$pkgver.tar.gz" - consul.service) -sha512sums=('4bbb167a603f1d20940330bd9615ba0f50e0113e1d96ce47773f5d2813635f76dd1aec8f43dae4c8c547cec8a891eb0726eeeda7bd7c5b1d495029b359378e68' - '0f39434e73a3f5d79919e3fad28de834688765edebfce8793aa471f272af61d9cebd13237a7aeb4f8b89f1749a891a63cd710881d58a9590990deedd43dffdba') - -prepare() { - cd consul-$pkgver - - mkdir build - mkdir -p .gopath/src/github.com/hashicorp - ln -sf "$PWD" .gopath/src/github.com/hashicorp/consul - export GOPATH="$PWD/.gopath" - - sed -e "s/Version = \"unknown\"/Version = \"$pkgver\"/" \ - -e "s/VersionPrerelease = \"unknown\"/VersionPrerelease = \"\"/" \ - -e "s/release = \"dev\"/release = \"\"/" \ - -i version/version.go -} - -build() { - cd consul-$pkgver - - go get github.com/mitchellh/cli - go build -o build/consul # -gccgoflags "$CFLAGS $LDFLAGS" -} - -package() { - cd consul-$pkgver - - install -Dm755 build/consul "$pkgdir"/usr/bin/consul - install -Dm644 "$srcdir"/consul.service "$pkgdir"/usr/lib/systemd/system/consul.service - install -d "$pkgdir"/etc/consul.d -} Copied: consul/repos/community-i686/PKGBUILD (from rev 257442, consul/trunk/PKGBUILD) =================================================================== --- community-i686/PKGBUILD (rev 0) +++ community-i686/PKGBUILD 2017-09-13 15:57:55 UTC (rev 257443) @@ -0,0 +1,72 @@ +# $Id$ +# Maintainer: Thore Bödecker <fox...@archlinux.org> +# Maintainer: Felix Yan <felixonm...@archlinux.org> + +pkgname=consul +pkgver=0.9.3 +pkgrel=1 +pkgdesc="A tool for service discovery, monitoring and configuration." +arch=('i686' 'x86_64') +_gocli_commit='65fcae5817c8600da98ada9d7edf26dd1a84837b' # HEAD +url="https://www.consul.io" +license=('MPL') +depends=('glibc') +makedepends=('git' 'go' 'procps-ng' 'syslog-ng') +source=("$pkgname-$pkgver.tar.gz::https://github.com/hashicorp/consul/archive/v$pkgver.tar.gz" + "git+https://github.com/mitchellh/cli#commit=${_gocli_commit}" + consul.service + consul.default + consul.sysusers + example.json + disable-broken-api-test.patch) +install=consul.install +sha512sums=('a1c9cdd3e197afbf088bd1866af15c1864cb8d042dc65d2fcc0d9070b8bf2f9380cf2ceadaff6d5bba7ecd379d53f4b8191e1ae6832f1b2c82f21c62f07d8b0f' + 'SKIP' + 'c70b9d1556f6c7ecb2e915ab685f289cef0e31198bd2e50c74a0483bbfb387beec67334f539a90adbf68b61b07946e98b300ab8a8e26e53b35f4ab4894adeb04' + 'ec5a800529a297c709fa383c094ecf106351cf0f8ac7b613b972d415d77fe001088902d7ab805e63e78a8e6360323fec1b795db5a4446df1e21b9b4ed31e7079' + 'ef872aedb2bc022a29292b7972a792b22e684c1ccb904a2b2cfec6d8966c28fb19be1452ce060821c419f1b646b236ba2e783175595e4bb6926d164c27a15c87' + 'c4292b8f56ee955ed7385a49843fd90d6434029891b3e1e724cb2fc841514c06e2554a26d3937c114371b18c2168c4e64319eb2cbd726ee8b35870df19089348' + 'ad5b5ea1fd4ec443c98a89da9fb581d32894c4583dec3707ce9096ed45706bc800f8eb20e5a0c68f6de437d228e09a97bad5815b5bba9b18ae339bcf9a42f8f7') + +prepare() { + export GOPATH="${srcdir}" + export PATH="$PATH:$GOPATH/bin" + mkdir -p "src/github.com/mitchellh" + mkdir -p "src/github.com/hashicorp" + + mv "${pkgname}-${pkgver}" "src/github.com/hashicorp/${pkgname}" + mv "cli" "src/github.com/mitchellh/cli" + + cd "src/github.com/hashicorp/${pkgname}" + + # TODO: debug failing tests + # + TestTombstoneGC + #rm ./agent/consul/state/tombstone_gc_test.go + # + TestAPI_ClientTLSOptions + #patch -p0 ./api/api_test.go < "${srcdir}/disable-broken-api-test.patch" + # + TestSyslogFilter (need to start syslog-ng within the chroot container) + #rm ./logger/syslog_test.go + #make test +} + +build() { + cd "src/github.com/hashicorp/${pkgname}" + # build local arch only, from: https://github.com/hashicorp/consul/#developing-consul + CONSUL_DEV=1 make +} + +package() { + cd "src/github.com/hashicorp/${pkgname}" + + install -D -d -m750 -o 208 -g 208 "${pkgdir}/var/lib/consul" + install -D -d -m750 -o 0 -g 208 "${pkgdir}/etc/consul.d" + + install -D -m644 "${srcdir}/consul.default" "${pkgdir}/etc/default/consul" + install -D -m640 -o 0 -g 208 "${srcdir}/example.json" "${pkgdir}/etc/consul.d/example.json" + install -Dm755 bin/consul "${pkgdir}/usr/bin/consul" + + install -Dm644 "${srcdir}/consul.service" "${pkgdir}/usr/lib/systemd/system/consul.service" + install -Dm644 "${srcdir}/consul.sysusers" "${pkgdir}/usr/lib/sysusers.d/consul.conf" +} + +# vim:set ts=2 sw=2 et: Copied: consul/repos/community-i686/consul.default (from rev 257442, consul/trunk/consul.default) =================================================================== --- community-i686/consul.default (rev 0) +++ community-i686/consul.default 2017-09-13 15:57:55 UTC (rev 257443) @@ -0,0 +1 @@ +CONSUL_FLAGS="" Copied: consul/repos/community-i686/consul.install (from rev 257442, consul/trunk/consul.install) =================================================================== --- community-i686/consul.install (rev 0) +++ community-i686/consul.install 2017-09-13 15:57:55 UTC (rev 257443) @@ -0,0 +1,9 @@ +post_upgrade() { + # improved permissions since 0.9.3-1 + if [ "$(vercmp "$2" "0.9.3")" -lt 0 ]; then + chown 0:208 /etc/consul.d + chmod 0750 /etc/consul.d + echo -en "----\nThe directory permissions for /etc/consul.d/ have been fixed.\n----\n" + fi + true +} Deleted: community-i686/consul.service =================================================================== --- community-i686/consul.service 2017-09-13 15:51:31 UTC (rev 257442) +++ community-i686/consul.service 2017-09-13 15:57:55 UTC (rev 257443) @@ -1,14 +0,0 @@ -[Unit] -Description=Consul Agent -Requires=network-online.target -After=network-online.target - -[Service] -EnvironmentFile=-/etc/default/consul -Restart=on-failure -ExecStart=/usr/bin/consul agent $CONSUL_FLAGS -config-dir=/etc/consul.d -ExecReload=/usr/bin/kill -HUP $MAINPID -KillSignal=SIGINT - -[Install] -WantedBy=multi-user.target Copied: consul/repos/community-i686/consul.service (from rev 257442, consul/trunk/consul.service) =================================================================== --- community-i686/consul.service (rev 0) +++ community-i686/consul.service 2017-09-13 15:57:55 UTC (rev 257443) @@ -0,0 +1,16 @@ +[Unit] +Description=Consul Agent +Requires=network-online.target +After=network-online.target + +[Service] +User=consul +Group=consul +EnvironmentFile=-/etc/default/consul +Restart=on-failure +ExecStart=/usr/bin/consul agent $CONSUL_FLAGS -config-dir=/etc/consul.d +ExecReload=/usr/bin/kill -HUP $MAINPID +KillSignal=SIGINT + +[Install] +WantedBy=multi-user.target Copied: consul/repos/community-i686/consul.sysusers (from rev 257442, consul/trunk/consul.sysusers) =================================================================== --- community-i686/consul.sysusers (rev 0) +++ community-i686/consul.sysusers 2017-09-13 15:57:55 UTC (rev 257443) @@ -0,0 +1 @@ +u consul 208 - /var/lib/consul Copied: consul/repos/community-i686/disable-broken-api-test.patch (from rev 257442, consul/trunk/disable-broken-api-test.patch) =================================================================== --- community-i686/disable-broken-api-test.patch (rev 0) +++ community-i686/disable-broken-api-test.patch 2017-09-13 15:57:55 UTC (rev 257443) @@ -0,0 +1,118 @@ +--- ./api/api_test.go 2017-09-08 18:43:36.000000000 +0200 ++++ /tmp/api_test.go 2017-09-13 16:20:25.950467396 +0200 +@@ -253,115 +253,6 @@ + } + } + +-func TestAPI_ClientTLSOptions(t *testing.T) { +- t.Parallel() +- // Start a server that verifies incoming HTTPS connections +- _, srvVerify := makeClientWithConfig(t, nil, func(conf *testutil.TestServerConfig) { +- conf.CAFile = "../test/client_certs/rootca.crt" +- conf.CertFile = "../test/client_certs/server.crt" +- conf.KeyFile = "../test/client_certs/server.key" +- conf.VerifyIncomingHTTPS = true +- }) +- defer srvVerify.Stop() +- +- // Start a server without VerifyIncomingHTTPS +- _, srvNoVerify := makeClientWithConfig(t, nil, func(conf *testutil.TestServerConfig) { +- conf.CAFile = "../test/client_certs/rootca.crt" +- conf.CertFile = "../test/client_certs/server.crt" +- conf.KeyFile = "../test/client_certs/server.key" +- conf.VerifyIncomingHTTPS = false +- }) +- defer srvNoVerify.Stop() +- +- // Client without a cert +- t.Run("client without cert, validation", func(t *testing.T) { +- client, err := NewClient(&Config{ +- Address: srvVerify.HTTPSAddr, +- Scheme: "https", +- TLSConfig: TLSConfig{ +- Address: "consul.test", +- CAFile: "../test/client_certs/rootca.crt", +- }, +- }) +- if err != nil { +- t.Fatal(err) +- } +- +- // Should fail +- _, err = client.Agent().Self() +- if err == nil || !strings.Contains(err.Error(), "bad certificate") { +- t.Fatal(err) +- } +- }) +- +- // Client with a valid cert +- t.Run("client with cert, validation", func(t *testing.T) { +- client, err := NewClient(&Config{ +- Address: srvVerify.HTTPSAddr, +- Scheme: "https", +- TLSConfig: TLSConfig{ +- Address: "consul.test", +- CAFile: "../test/client_certs/rootca.crt", +- CertFile: "../test/client_certs/client.crt", +- KeyFile: "../test/client_certs/client.key", +- }, +- }) +- if err != nil { +- t.Fatal(err) +- } +- +- // Should succeed +- _, err = client.Agent().Self() +- if err != nil { +- t.Fatal(err) +- } +- }) +- +- // Client without a cert +- t.Run("client without cert, no validation", func(t *testing.T) { +- client, err := NewClient(&Config{ +- Address: srvNoVerify.HTTPSAddr, +- Scheme: "https", +- TLSConfig: TLSConfig{ +- Address: "consul.test", +- CAFile: "../test/client_certs/rootca.crt", +- }, +- }) +- if err != nil { +- t.Fatal(err) +- } +- +- // Should succeed +- _, err = client.Agent().Self() +- if err != nil { +- t.Fatal(err) +- } +- }) +- +- // Client with a valid cert +- t.Run("client with cert, no validation", func(t *testing.T) { +- client, err := NewClient(&Config{ +- Address: srvNoVerify.HTTPSAddr, +- Scheme: "https", +- TLSConfig: TLSConfig{ +- Address: "consul.test", +- CAFile: "../test/client_certs/rootca.crt", +- CertFile: "../test/client_certs/client.crt", +- KeyFile: "../test/client_certs/client.key", +- }, +- }) +- if err != nil { +- t.Fatal(err) +- } +- +- // Should succeed +- _, err = client.Agent().Self() +- if err != nil { +- t.Fatal(err) +- } +- }) +-} +- + func TestAPI_SetQueryOptions(t *testing.T) { + t.Parallel() + c, s := makeClient(t) Copied: consul/repos/community-i686/example.json (from rev 257442, consul/trunk/example.json) =================================================================== --- community-i686/example.json (rev 0) +++ community-i686/example.json 2017-09-13 15:57:55 UTC (rev 257443) @@ -0,0 +1,7 @@ +{ + "data_dir": "/var/lib/consul", + "disable_update_check": true, + "log_level": "INFO", + "node_name": "example.localdomain", + "server": true +} Deleted: community-x86_64/PKGBUILD =================================================================== --- community-x86_64/PKGBUILD 2017-09-13 15:51:31 UTC (rev 257442) +++ community-x86_64/PKGBUILD 2017-09-13 15:57:55 UTC (rev 257443) @@ -1,45 +0,0 @@ -# $Id$ -# Maintainer: Felix Yan <felixonm...@archlinux.org> - -pkgname=consul -pkgver=0.8.4 -pkgrel=1 -pkgdesc="A tool for service discovery, monitoring and configuration." -arch=('i686' 'x86_64') -url="https://www.consul.io" -license=('MPL') -depends=('glibc') -makedepends=('git' 'go') -source=("$pkgname-$pkgver.tar.gz::https://github.com/hashicorp/consul/archive/v$pkgver.tar.gz" - consul.service) -sha512sums=('4bbb167a603f1d20940330bd9615ba0f50e0113e1d96ce47773f5d2813635f76dd1aec8f43dae4c8c547cec8a891eb0726eeeda7bd7c5b1d495029b359378e68' - '0f39434e73a3f5d79919e3fad28de834688765edebfce8793aa471f272af61d9cebd13237a7aeb4f8b89f1749a891a63cd710881d58a9590990deedd43dffdba') - -prepare() { - cd consul-$pkgver - - mkdir build - mkdir -p .gopath/src/github.com/hashicorp - ln -sf "$PWD" .gopath/src/github.com/hashicorp/consul - export GOPATH="$PWD/.gopath" - - sed -e "s/Version = \"unknown\"/Version = \"$pkgver\"/" \ - -e "s/VersionPrerelease = \"unknown\"/VersionPrerelease = \"\"/" \ - -e "s/release = \"dev\"/release = \"\"/" \ - -i version/version.go -} - -build() { - cd consul-$pkgver - - go get github.com/mitchellh/cli - go build -o build/consul # -gccgoflags "$CFLAGS $LDFLAGS" -} - -package() { - cd consul-$pkgver - - install -Dm755 build/consul "$pkgdir"/usr/bin/consul - install -Dm644 "$srcdir"/consul.service "$pkgdir"/usr/lib/systemd/system/consul.service - install -d "$pkgdir"/etc/consul.d -} Copied: consul/repos/community-x86_64/PKGBUILD (from rev 257442, consul/trunk/PKGBUILD) =================================================================== --- community-x86_64/PKGBUILD (rev 0) +++ community-x86_64/PKGBUILD 2017-09-13 15:57:55 UTC (rev 257443) @@ -0,0 +1,72 @@ +# $Id$ +# Maintainer: Thore Bödecker <fox...@archlinux.org> +# Maintainer: Felix Yan <felixonm...@archlinux.org> + +pkgname=consul +pkgver=0.9.3 +pkgrel=1 +pkgdesc="A tool for service discovery, monitoring and configuration." +arch=('i686' 'x86_64') +_gocli_commit='65fcae5817c8600da98ada9d7edf26dd1a84837b' # HEAD +url="https://www.consul.io" +license=('MPL') +depends=('glibc') +makedepends=('git' 'go' 'procps-ng' 'syslog-ng') +source=("$pkgname-$pkgver.tar.gz::https://github.com/hashicorp/consul/archive/v$pkgver.tar.gz" + "git+https://github.com/mitchellh/cli#commit=${_gocli_commit}" + consul.service + consul.default + consul.sysusers + example.json + disable-broken-api-test.patch) +install=consul.install +sha512sums=('a1c9cdd3e197afbf088bd1866af15c1864cb8d042dc65d2fcc0d9070b8bf2f9380cf2ceadaff6d5bba7ecd379d53f4b8191e1ae6832f1b2c82f21c62f07d8b0f' + 'SKIP' + 'c70b9d1556f6c7ecb2e915ab685f289cef0e31198bd2e50c74a0483bbfb387beec67334f539a90adbf68b61b07946e98b300ab8a8e26e53b35f4ab4894adeb04' + 'ec5a800529a297c709fa383c094ecf106351cf0f8ac7b613b972d415d77fe001088902d7ab805e63e78a8e6360323fec1b795db5a4446df1e21b9b4ed31e7079' + 'ef872aedb2bc022a29292b7972a792b22e684c1ccb904a2b2cfec6d8966c28fb19be1452ce060821c419f1b646b236ba2e783175595e4bb6926d164c27a15c87' + 'c4292b8f56ee955ed7385a49843fd90d6434029891b3e1e724cb2fc841514c06e2554a26d3937c114371b18c2168c4e64319eb2cbd726ee8b35870df19089348' + 'ad5b5ea1fd4ec443c98a89da9fb581d32894c4583dec3707ce9096ed45706bc800f8eb20e5a0c68f6de437d228e09a97bad5815b5bba9b18ae339bcf9a42f8f7') + +prepare() { + export GOPATH="${srcdir}" + export PATH="$PATH:$GOPATH/bin" + mkdir -p "src/github.com/mitchellh" + mkdir -p "src/github.com/hashicorp" + + mv "${pkgname}-${pkgver}" "src/github.com/hashicorp/${pkgname}" + mv "cli" "src/github.com/mitchellh/cli" + + cd "src/github.com/hashicorp/${pkgname}" + + # TODO: debug failing tests + # + TestTombstoneGC + #rm ./agent/consul/state/tombstone_gc_test.go + # + TestAPI_ClientTLSOptions + #patch -p0 ./api/api_test.go < "${srcdir}/disable-broken-api-test.patch" + # + TestSyslogFilter (need to start syslog-ng within the chroot container) + #rm ./logger/syslog_test.go + #make test +} + +build() { + cd "src/github.com/hashicorp/${pkgname}" + # build local arch only, from: https://github.com/hashicorp/consul/#developing-consul + CONSUL_DEV=1 make +} + +package() { + cd "src/github.com/hashicorp/${pkgname}" + + install -D -d -m750 -o 208 -g 208 "${pkgdir}/var/lib/consul" + install -D -d -m750 -o 0 -g 208 "${pkgdir}/etc/consul.d" + + install -D -m644 "${srcdir}/consul.default" "${pkgdir}/etc/default/consul" + install -D -m640 -o 0 -g 208 "${srcdir}/example.json" "${pkgdir}/etc/consul.d/example.json" + install -Dm755 bin/consul "${pkgdir}/usr/bin/consul" + + install -Dm644 "${srcdir}/consul.service" "${pkgdir}/usr/lib/systemd/system/consul.service" + install -Dm644 "${srcdir}/consul.sysusers" "${pkgdir}/usr/lib/sysusers.d/consul.conf" +} + +# vim:set ts=2 sw=2 et: Copied: consul/repos/community-x86_64/consul.default (from rev 257442, consul/trunk/consul.default) =================================================================== --- community-x86_64/consul.default (rev 0) +++ community-x86_64/consul.default 2017-09-13 15:57:55 UTC (rev 257443) @@ -0,0 +1 @@ +CONSUL_FLAGS="" Copied: consul/repos/community-x86_64/consul.install (from rev 257442, consul/trunk/consul.install) =================================================================== --- community-x86_64/consul.install (rev 0) +++ community-x86_64/consul.install 2017-09-13 15:57:55 UTC (rev 257443) @@ -0,0 +1,9 @@ +post_upgrade() { + # improved permissions since 0.9.3-1 + if [ "$(vercmp "$2" "0.9.3")" -lt 0 ]; then + chown 0:208 /etc/consul.d + chmod 0750 /etc/consul.d + echo -en "----\nThe directory permissions for /etc/consul.d/ have been fixed.\n----\n" + fi + true +} Deleted: community-x86_64/consul.service =================================================================== --- community-x86_64/consul.service 2017-09-13 15:51:31 UTC (rev 257442) +++ community-x86_64/consul.service 2017-09-13 15:57:55 UTC (rev 257443) @@ -1,14 +0,0 @@ -[Unit] -Description=Consul Agent -Requires=network-online.target -After=network-online.target - -[Service] -EnvironmentFile=-/etc/default/consul -Restart=on-failure -ExecStart=/usr/bin/consul agent $CONSUL_FLAGS -config-dir=/etc/consul.d -ExecReload=/usr/bin/kill -HUP $MAINPID -KillSignal=SIGINT - -[Install] -WantedBy=multi-user.target Copied: consul/repos/community-x86_64/consul.service (from rev 257442, consul/trunk/consul.service) =================================================================== --- community-x86_64/consul.service (rev 0) +++ community-x86_64/consul.service 2017-09-13 15:57:55 UTC (rev 257443) @@ -0,0 +1,16 @@ +[Unit] +Description=Consul Agent +Requires=network-online.target +After=network-online.target + +[Service] +User=consul +Group=consul +EnvironmentFile=-/etc/default/consul +Restart=on-failure +ExecStart=/usr/bin/consul agent $CONSUL_FLAGS -config-dir=/etc/consul.d +ExecReload=/usr/bin/kill -HUP $MAINPID +KillSignal=SIGINT + +[Install] +WantedBy=multi-user.target Copied: consul/repos/community-x86_64/consul.sysusers (from rev 257442, consul/trunk/consul.sysusers) =================================================================== --- community-x86_64/consul.sysusers (rev 0) +++ community-x86_64/consul.sysusers 2017-09-13 15:57:55 UTC (rev 257443) @@ -0,0 +1 @@ +u consul 208 - /var/lib/consul Copied: consul/repos/community-x86_64/disable-broken-api-test.patch (from rev 257442, consul/trunk/disable-broken-api-test.patch) =================================================================== --- community-x86_64/disable-broken-api-test.patch (rev 0) +++ community-x86_64/disable-broken-api-test.patch 2017-09-13 15:57:55 UTC (rev 257443) @@ -0,0 +1,118 @@ +--- ./api/api_test.go 2017-09-08 18:43:36.000000000 +0200 ++++ /tmp/api_test.go 2017-09-13 16:20:25.950467396 +0200 +@@ -253,115 +253,6 @@ + } + } + +-func TestAPI_ClientTLSOptions(t *testing.T) { +- t.Parallel() +- // Start a server that verifies incoming HTTPS connections +- _, srvVerify := makeClientWithConfig(t, nil, func(conf *testutil.TestServerConfig) { +- conf.CAFile = "../test/client_certs/rootca.crt" +- conf.CertFile = "../test/client_certs/server.crt" +- conf.KeyFile = "../test/client_certs/server.key" +- conf.VerifyIncomingHTTPS = true +- }) +- defer srvVerify.Stop() +- +- // Start a server without VerifyIncomingHTTPS +- _, srvNoVerify := makeClientWithConfig(t, nil, func(conf *testutil.TestServerConfig) { +- conf.CAFile = "../test/client_certs/rootca.crt" +- conf.CertFile = "../test/client_certs/server.crt" +- conf.KeyFile = "../test/client_certs/server.key" +- conf.VerifyIncomingHTTPS = false +- }) +- defer srvNoVerify.Stop() +- +- // Client without a cert +- t.Run("client without cert, validation", func(t *testing.T) { +- client, err := NewClient(&Config{ +- Address: srvVerify.HTTPSAddr, +- Scheme: "https", +- TLSConfig: TLSConfig{ +- Address: "consul.test", +- CAFile: "../test/client_certs/rootca.crt", +- }, +- }) +- if err != nil { +- t.Fatal(err) +- } +- +- // Should fail +- _, err = client.Agent().Self() +- if err == nil || !strings.Contains(err.Error(), "bad certificate") { +- t.Fatal(err) +- } +- }) +- +- // Client with a valid cert +- t.Run("client with cert, validation", func(t *testing.T) { +- client, err := NewClient(&Config{ +- Address: srvVerify.HTTPSAddr, +- Scheme: "https", +- TLSConfig: TLSConfig{ +- Address: "consul.test", +- CAFile: "../test/client_certs/rootca.crt", +- CertFile: "../test/client_certs/client.crt", +- KeyFile: "../test/client_certs/client.key", +- }, +- }) +- if err != nil { +- t.Fatal(err) +- } +- +- // Should succeed +- _, err = client.Agent().Self() +- if err != nil { +- t.Fatal(err) +- } +- }) +- +- // Client without a cert +- t.Run("client without cert, no validation", func(t *testing.T) { +- client, err := NewClient(&Config{ +- Address: srvNoVerify.HTTPSAddr, +- Scheme: "https", +- TLSConfig: TLSConfig{ +- Address: "consul.test", +- CAFile: "../test/client_certs/rootca.crt", +- }, +- }) +- if err != nil { +- t.Fatal(err) +- } +- +- // Should succeed +- _, err = client.Agent().Self() +- if err != nil { +- t.Fatal(err) +- } +- }) +- +- // Client with a valid cert +- t.Run("client with cert, no validation", func(t *testing.T) { +- client, err := NewClient(&Config{ +- Address: srvNoVerify.HTTPSAddr, +- Scheme: "https", +- TLSConfig: TLSConfig{ +- Address: "consul.test", +- CAFile: "../test/client_certs/rootca.crt", +- CertFile: "../test/client_certs/client.crt", +- KeyFile: "../test/client_certs/client.key", +- }, +- }) +- if err != nil { +- t.Fatal(err) +- } +- +- // Should succeed +- _, err = client.Agent().Self() +- if err != nil { +- t.Fatal(err) +- } +- }) +-} +- + func TestAPI_SetQueryOptions(t *testing.T) { + t.Parallel() + c, s := makeClient(t) Copied: consul/repos/community-x86_64/example.json (from rev 257442, consul/trunk/example.json) =================================================================== --- community-x86_64/example.json (rev 0) +++ community-x86_64/example.json 2017-09-13 15:57:55 UTC (rev 257443) @@ -0,0 +1,7 @@ +{ + "data_dir": "/var/lib/consul", + "disable_update_check": true, + "log_level": "INFO", + "node_name": "example.localdomain", + "server": true +}