Docker-install of boulder server's /test/setup.sh hangs at "Can't connect to local MySQL server through socket"?


#1

I’m working on automating my EC cert management, since it’s not currently available via certbot.

While testing scripts, I’ve been using the STAGING server.

Now, I keep hitting STAGING server’s RateLimits.

So I’m trying to installing a local boulder instance.

Since I’m doing this on a working server, I need to build/install with docker, hoping to isolate & avoid conflicts

Staring with current source

    git clone https://github.com/letsencrypt/boulder.git
    cd ./boulder
    git log | head
        commit 243832822a28e04e46dc26ab3554ac2062731cc6
        Author: Jacob Hoffman-Andrews <github@hoffman-andrews.com>
        Date:   Tue Aug 9 06:44:02 2016 -0700

            Remove transaction in updateCertStatus. (#2096)

            Formerly in expiration-mailer, when we wanted to set `lastNagSent` to `Now()`, we started a transaction, read the object, updated one field, wrote it back, and closed the transaction.

            This commit replaces the transaction and instead does a much simpler and more efficient `UPDATE certificateStatus SET lastNagSent = ? where serial = ?;`.

current go

    export GOPATH=$(which go)
    go --version
        go version go1.6.3 linux/amd64

hosts modified

    grep boulder /etc/hosts
        127.0.0.1 boulder boulder-rabbitmq boulder-mysql

on exec of setup

./test/setup.sh

it eventually fails

    ...
     /bin/mkdir -p '/root/include/google/protobuf/compiler'
     /usr/bin/install -c -m 644  google/protobuf/compiler/code_generator.h google/protobuf/compiler/command_line_interface.h google/protobuf/compiler/importer.h google/protobuf/compiler/parser.h google/protobuf/compiler/plugin.h google/protobuf/compiler/plugin.pb.h '/root/include/google/protobuf/compiler'
     /bin/mkdir -p '/root/include/google/protobuf/io'
     /usr/bin/install -c -m 644  google/protobuf/io/coded_stream.h google/protobuf/io/gzip_stream.h google/protobuf/io/printer.h google/protobuf/io/strtod.h google/protobuf/io/tokenizer.h google/protobuf/io/zero_copy_stream.h google/protobuf/io/zero_copy_stream_impl.h google/protobuf/io/zero_copy_stream_impl_lite.h '/root/include/google/protobuf/io'
    make[3]: Leaving directory '/usr/local/src/boulder/protobuf-2.6.1/src'
    make[2]: Leaving directory '/usr/local/src/boulder/protobuf-2.6.1/src'
    make[1]: Leaving directory '/usr/local/src/boulder/protobuf-2.6.1/src'

    # Create the database and roles
    ./test/create_db.sh
    ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/cache/mariadb/mariadb.sock' (2 "No such file or directory")
    ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/cache/mariadb/mariadb.sock' (2 "No such file or directory")

which appears to be referencing my local, !docker, sql config, “/etc/my.cnf”

    grep sock /etc/my.cnf
        socket = /var/cache/mariadb/mariadb.sock

How do I isolate the docker+boulder installer from my locally running environment ?


#2

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.