Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow supplying MONGO_SERVER_URL via chains-config #1113

Merged
merged 2 commits into from
Jul 13, 2024

Commits on Jun 25, 2024

  1. Allow supplying MONGO_SERVER_URL via chains-config

    Currently, when using the Mongo docstore for docdb storage backend, the
    only way to supply MONGO_SERVER_URL environment variable (which contains
    the credentials to connect to MongoDB) is by adding an environment
    variable to the Chains controller pod. It's a farily common practice to
    update the MONGO_SERVER_URL at regular intervals when the credentials
    are rotated.
    
    To facilitate this, this commit adds 2 fields to Chains' configuration:
    1. storage.docdb.mongo-server-url
    2. storage.docdb.mongo-server-url-dir
    
    `storage.docdb.mongo-server-url` simply allows supplying the value of
    MONGO_SERVER_URL as a field. When this field is updated, the chains
    controller pod does not restart, unlike when the MONGO_SERVER_URL
    environment variable is updated.
    
    `storage.docdb.mongo-server-url-dir` allows reading MONGO_SERVER_URL
    from a file in the specified directory. This allows mounting the value
    of MONGO_SERVER_URL from a secret or other mechanisms. When the value of
    MONGO_SERVER_URL is updated in the path, the new value is automatically
    picked up and applied.
    concaf authored and PuneetPunamiya committed Jun 25, 2024
    Configuration menu
    Copy the full SHA
    fc85b11 View commit details
    Browse the repository at this point in the history
  2. Bump gocloud.dev/docstore/mongodocstore

    This commit bumps gocloud.dev/docstore/mongodocstore to the commit at
    google/go-cloud#3429 that allows MONGO_SERVER_URL rotation.
    concaf authored and PuneetPunamiya committed Jun 25, 2024
    Configuration menu
    Copy the full SHA
    ffd65fd View commit details
    Browse the repository at this point in the history