github.com/letsencrypt/boulder@v0.20251208.0/docker-compose.yml (about)

     1  services:
     2    boulder:
     3      # The `letsencrypt/boulder-tools:latest` tag is automatically built in local
     4      # dev environments. In CI a specific BOULDER_TOOLS_TAG is passed, and it is
     5      # pulled with `docker compose pull`.
     6      image: &boulder_tools_image letsencrypt/boulder-tools:${BOULDER_TOOLS_TAG:-latest}
     7      build:
     8        context: test/boulder-tools/
     9        # Should match one of the GO_CI_VERSIONS in test/boulder-tools/tag_and_upload.sh.
    10        args:
    11          GO_VERSION: 1.25.5
    12      environment:
    13        # To solve HTTP-01 and TLS-ALPN-01 challenges, change the IP in FAKE_DNS
    14        # to the IP address where your ACME client's solver is listening. This is
    15        # pointing at the boulder service's "public" IP, where challtestsrv is.
    16        FAKE_DNS: 64.112.117.122
    17        BOULDER_CONFIG_DIR: test/config
    18        GOCACHE: /boulder/.gocache/go-build
    19      volumes:
    20        - .:/boulder:cached
    21        - ./.gocache:/root/.cache/go-build:cached
    22        - ./test/certs/.softhsm-tokens/:/var/lib/softhsm/tokens/:cached
    23      networks:
    24        bouldernet:
    25          ipv4_address: 10.77.77.77
    26        publicnet:
    27          ipv4_address: 64.112.117.122
    28        publicnet2:
    29          ipv4_address: 64.112.117.134
    30      # Use consul as a backup to Docker's embedded DNS server. If there's a name
    31      # Docker's DNS server doesn't know about, it will forward the query to this
    32      # IP (running consul).
    33      # (https://docs.docker.com/config/containers/container-networking/#dns-services).
    34      # This is used to look up service names via A records (like ra.service.consul) that
    35      # are configured via the ServerAddress field of cmd.GRPCClientConfig.
    36      # TODO: Remove this when ServerAddress is deprecated in favor of SRV records
    37      # and DNSAuthority.
    38      dns: 10.77.77.10
    39      extra_hosts:
    40        # Allow the boulder container to be reached as "ca.example.org", so we
    41        # can put that name inside our integration test certs (e.g. as a crl
    42        # url) and have it look like a publicly-accessible name.
    43        # TODO(#8215): Move s3-test-srv to a separate service.
    44        - "ca.example.org:64.112.117.122"
    45        # Allow the boulder container to be reached as "integration.trust", for
    46        # similar reasons, but intended for use as a SAN rather than a CRLDP.
    47        # TODO(#8215): Move observer's probe target to a separate service.
    48        - "integration.trust:64.112.117.122"
    49      ports:
    50        - 4001:4001 # ACMEv2
    51        - 4003:4003 # SFE
    52      depends_on:
    53        - bmariadb
    54        - bproxysql
    55        - bvitess
    56        - bredis_1
    57        - bredis_2
    58        - bconsul
    59        - bjaeger
    60        - bpkimetal
    61      entrypoint: test/entrypoint.sh
    62      working_dir: &boulder_working_dir /boulder
    63  
    64    bsetup:
    65      image: *boulder_tools_image
    66      volumes:
    67        - .:/boulder:cached
    68        - ./.gocache:/root/.cache/go-build:cached
    69        - ./test/certs/.softhsm-tokens/:/var/lib/softhsm/tokens/:cached
    70      entrypoint: test/certs/generate.sh
    71      working_dir: *boulder_working_dir
    72      profiles:
    73        # Adding a profile to this container means that it won't be started by a
    74        # normal "docker compose up/run boulder", only when specifically invoked
    75        # with a "docker compose up bsetup".
    76        - setup
    77  
    78    bmariadb:
    79      image: mariadb:10.11.13
    80      networks:
    81        bouldernet:
    82          aliases:
    83            - boulder-mariadb
    84      environment:
    85        MYSQL_ALLOW_EMPTY_PASSWORD: "yes"
    86      # Send slow queries to a table so we can check for them in the
    87      # integration tests. For now we ignore queries not using indexes,
    88      # because that seems to trigger based on the optimizer's choice to not
    89      # use an index for certain queries, particularly when tables are still
    90      # small.
    91      command: mysqld --bind-address=0.0.0.0 --slow-query-log --log-output=TABLE --log-queries-not-using-indexes=ON
    92      logging:
    93        driver: none
    94  
    95    bproxysql:
    96      image: proxysql/proxysql:2.7.2
    97      # The --initial flag force resets the ProxySQL database on startup. By
    98      # default, ProxySQL ignores new configuration if the database already
    99      # exists. Without this flag, new configuration wouldn't be applied until you
   100      # ran `docker compose down`.
   101      entrypoint: proxysql -f --idle-threads -c /test/proxysql/proxysql.cnf --initial
   102      volumes:
   103        - ./test/:/test/:cached
   104      depends_on:
   105        - bmariadb
   106      networks:
   107        bouldernet:
   108          aliases:
   109            - boulder-proxysql
   110  
   111    bredis_1:
   112      image: redis:7.0.15
   113      volumes:
   114        - ./test/:/test/:cached
   115      command: redis-server /test/redis-ratelimits.config
   116      networks:
   117        bouldernet:
   118          ipv4_address: 10.77.77.4
   119  
   120    bredis_2:
   121      image: redis:7.0.15
   122      volumes:
   123        - ./test/:/test/:cached
   124      command: redis-server /test/redis-ratelimits.config
   125      networks:
   126        bouldernet:
   127          ipv4_address: 10.77.77.5
   128  
   129    bconsul:
   130      image: hashicorp/consul:1.19.1
   131      volumes:
   132       - ./test/:/test/:cached
   133      networks:
   134        bouldernet:
   135          ipv4_address: 10.77.77.10
   136      command: "consul agent -dev -config-format=hcl -config-file=/test/consul/config.hcl"
   137  
   138    bjaeger:
   139      image: jaegertracing/all-in-one:1.50
   140      networks:
   141        - bouldernet
   142  
   143    bpkimetal:
   144      image: ghcr.io/pkimetal/pkimetal:v1.20.0
   145      networks:
   146        - bouldernet
   147  
   148    bvitess:
   149      # The `letsencrypt/boulder-vtcomboserver:latest` tag is automatically built
   150      # in local dev environments. In CI a specific BOULDER_VTCOMBOSERVER_TAG is
   151      # passed, and it is pulled with `docker compose pull`.
   152      image: letsencrypt/boulder-vtcomboserver:${BOULDER_VTCOMBOSERVER_TAG:-latest}
   153      environment:
   154        # By specifying KEYSPACES vttestserver will create the corresponding
   155        # databases on startup.
   156        KEYSPACES: boulder_sa_test,boulder_sa_integration,incidents_sa_test,incidents_sa_integration
   157        NUM_SHARDS: 1,1,1,1
   158      networks:
   159        bouldernet:
   160          aliases:
   161            - boulder-vitess
   162  
   163  networks:
   164    # This network represents the data-center internal network. It is used for
   165    # boulder services and their infrastructure, such as consul, mariadb, and
   166    # redis.
   167    bouldernet:
   168      driver: bridge
   169      ipam:
   170        driver: default
   171        config:
   172          - subnet: 10.77.77.0/24
   173            # Only issue DHCP addresses in the top half of the range, to avoid
   174            # conflict with static addresses.
   175            ip_range: 10.77.77.128/25
   176  
   177    # This network represents the public internet. It uses a real public IP space
   178    # (that Let's Encrypt controls) so that our integration tests are happy to
   179    # validate and issue for it. It is used by challtestsrv, which binds to
   180    # 64.112.117.122:80 and :443 for its HTTP-01 challenge responder.
   181    #
   182    # TODO(#8215): Put s3-test-srv on this network.
   183    publicnet:
   184      driver: bridge
   185      ipam:
   186        driver: default
   187        config:
   188          - subnet: 64.112.117.0/25
   189  
   190    # This network is used for two things in the integration tests:
   191    #  - challtestsrv binds to 64.112.117.134:443 for its tls-alpn-01 challenge
   192    #    responder, to avoid interfering with the HTTPS port used for testing
   193    #    HTTP->HTTPS redirects during http-01 challenges. Note: this could
   194    #    probably be updated in the future so that challtestsrv can handle
   195    #    both tls-alpn-01 and HTTPS on the same port.
   196    #  - test/v2_integration.py has some test cases that start their own HTTP
   197    #    server instead of relying on challtestsrv, because they want very
   198    #    specific behavior. For these cases, v2_integration.py creates a Python
   199    #    HTTP server and binds it to 64.112.117.134:80.
   200    #
   201    # TODO(#8215): Deprecate this network, replacing it with individual IPs within
   202    # the existing publicnet.
   203    publicnet2:
   204      driver: bridge
   205      ipam:
   206        driver: default
   207        config:
   208          - subnet: 64.112.117.128/25