global:
  env: optimism-goerli
# enable Blockscout deploy
blockscout:
  app: blockscout
  enabled: true
  image:
    _default: &image blockscout/blockscout-optimism-l2-advanced:5.1.2-prerelease-465ba09e
  replicas:
    app: 1
  # init container
  init:
    enabled: true
    image:
      _default: *image
  # enable ingress
  ingress:
    enabled: true
    annotations:
      - 'nginx.ingress.kubernetes.io/cors-allow-origin: "https://*.blockscout-main.test.aws-k8s.blockscout.com, https://*.test.aws-k8s.blockscout.com, http://localhost:3000"'
      - 'nginx.ingress.kubernetes.io/cors-allow-credentials: "true"'
      - 'nginx.ingress.kubernetes.io/cors-allow-methods: PUT, GET, POST, OPTIONS, DELETE, PATCH'
      - 'nginx.ingress.kubernetes.io/enable-cors: "true"'
      - 'nginx.ingress.kubernetes.io/cors-allow-headers: "DNT,Keep-Alive,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Range,Authorization,x-csrf-token"'
      # - 'nginx.ingress.kubernetes.io/rewrite-target: /$2'
    host:
      _default: blockscout-optimism-goerli.test.aws-k8s.blockscout.com
    # enable https
    #
    tls:
      enabled: true
    path:
      prefix:
        - "/"
  # probes
  livenessProbe:
    enabled: true
    path: /
    params:
      initialDelaySeconds: 100
      periodSeconds: 100
  readinessProbe:
    enabled: true
    path: /
    params:
      initialDelaySeconds: 60
      periodSeconds: 10
      timeoutSeconds: 60
  resources:
    limits:
      memory:
        _default: "2Gi"
      cpu:
        _default: "1"
    requests:
      memory:
        _default: "2Gi"
      cpu:
        _default: "1"
  # Blockscout environment variables
  environment:
    ENV:
      _default: test
    RESOURCE_MODE:
      _default: account
    PUBLIC:
      _default: 'false'
    PORT:
      _default: 4000
    PORT_PG:
      _default: 5432
    PORT_NETWORK_HTTP:
      _default: 8545
    PORT_NETWORK_WS:
      _default: 8546
    ETHEREUM_JSONRPC_VARIANT:
      _default: geth
    COIN:
      _default: ETH
    COIN_NAME:
      _default: ETH
    MIX_ENV:
      _default: prod
    ECTO_USE_SSL:
      _default: 'false'
    MICROSERVICE_SC_VERIFIER_ENABLED:
      _default: 'true'
    MICROSERVICE_SC_VERIFIER_URL:
      _default: http://sc-verifier-svc:8043
    ACCOUNT_ENABLED:
      _default: 'true'
    DISABLE_EXCHANGE_RATES:
      _default: 'true'
    BLOCKSCOUT_HOST:
      _default: 'blockscout-optimism-goerli.test.aws-k8s.blockscout.com'
    NETWORK_PATH:
      _default: "/"
    APPS_MENU:
      _default: 'true'
    EXTERNAL_APPS:
      _default: '[{"title": "Marketplace", "url": "/apps"}]'
    JSON_RPC:
      _default: https://goerli.optimism.io
    API_V2_ENABLED:
      _default: 'true'
    FIRST_BLOCK:
      _default: '4667000'
    TRACE_FIRST_BLOCK:
      _default: '4667000'
    LAST_BLOCK:
      _default: '4677000'
    TRACE_LAST_BLOCK:
      _default: '4677000'
    DISABLE_REALTIME_INDEXER:
      _default: 'false'
    INDEXER_OPTIMISM_L1_PORTAL_CONTRACT:
      _default: 0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383
    INDEXER_OPTIMISM_L1_WITHDRAWALS_START_BLOCK:
      _default: '8299683'
    INDEXER_OPTIMISM_L2_WITHDRAWALS_START_BLOCK:
      _default: '4066066'
    INDEXER_OPTIMISM_L2_MESSAGE_PASSER_CONTRACT:
      _default: 0x4200000000000000000000000000000000000016
    INDEXER_OPTIMISM_L1_OUTPUT_ROOTS_START_BLOCK:
      _default: '8299683'
    INDEXER_OPTIMISM_L1_OUTPUT_ORACLE_CONTRACT:
      _default: 0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0
    INDEXER_OPTIMISM_L1_BATCH_START_BLOCK:
      _default: '8381594'
    INDEXER_OPTIMISM_L1_BATCH_INBOX:
      _default: 0xff00000000000000000000000000000000000420
    INDEXER_OPTIMISM_L1_BATCH_SUBMITTER:
      _default: 0x7431310e026b69bfc676c0013e12a1a11411eec9
    INDEXER_OPTIMISM_L1_DEPOSITS_START_BLOCK:
      _default: '8381594'

postgres:
  enabled: true
  image: postgres:13.8
  port: 5432

  command: '["docker-entrypoint.sh", "-c"]'
  args: '["max_connections=300"]'

  customShm:
    enabled: false

  files:
    enabled: true
    mountPath: /docker-entrypoint-initdb.d
    list:
      init.sql: |
        CREATE DATABASE stats;
        GRANT ALL PRIVILEGES ON DATABASE stats TO postgres;

  resources:
    limits:
      memory:
        _default: "1Gi"
      cpu:
        _default: "1"
    requests:
      memory:
        _default: "1Gi"
      cpu:
        _default: "1"

  environment:
    POSTGRES_USER:
      _default: 'postgres'
    POSTGRES_HOST_AUTH_METHOD:
      _default: 'trust'
# enable Smart-contract-verifier deploy
scVerifier:
  enabled: true
  image:
    _default: ghcr.io/blockscout/smart-contract-verifier:main
  # enable ingress
  ingress:
    enabled: true
    host:
      _default: verifier-optimism-goerli.test.aws-k8s.blockscout.com
    # enable https
    tls:
      enabled: true
  resources:
    limits:
      memory:
        _default: "0.5Gi"
      cpu:
        _default: "0.25"
    requests:
      memory:
        _default: "0.5Gi"
      cpu:
        _default: "0.25"
  environment:
    SMART_CONTRACT_VERIFIER__SERVER__HTTP__ADDR:
      _default: 0.0.0.0:8050
    SMART_CONTRACT_VERIFIER__SERVER__GRPC__ADDR:
      _default: 0.0.0.0:8051
    # SMART_CONTRACT_VERIFIER__SOLIDITY__ENABLED:
    #   _default: 'true'
    SMART_CONTRACT_VERIFIER__SOLIDITY__COMPILERS_DIR:
      _default: /tmp/solidity-compilers
    SMART_CONTRACT_VERIFIER__SOLIDITY__REFRESH_VERSIONS_SCHEDULE:
      _default: 0 0 * * * * *
    # It depends on the OS you are running the service on
    # SMART_CONTRACT_VERIFIER__SOLIDITY__FETCHER__LIST__LIST_URL:
    #   _default: https://solc-bin.ethereum.org/linux-amd64/list.json
    #SMART_CONTRACT_VERIFIER__SOLIDITY__FETCHER__LIST__LIST_URL=https://solc-bin.ethereum.org/macosx-amd64/list.json
    #SMART_CONTRACT_VERIFIER__SOLIDITY__FETCHER__LIST__LIST_URL=https://solc-bin.ethereum.org/windows-amd64/list.json
    SMART_CONTRACT_VERIFIER__SOLIDITY__FETCHER__S3__REGION:
      _default: ""
    SMART_CONTRACT_VERIFIER__SOLIDITY__FETCHER__S3__ENDPOINT:
      _default: https://storage.googleapis.com
    SMART_CONTRACT_VERIFIER__SOURCIFY__ENABLED:
      _default: 'true'
    SMART_CONTRACT_VERIFIER__SOURCIFY__API_URL:
      _default: https://sourcify.dev/server/
    SMART_CONTRACT_VERIFIER__SOURCIFY__VERIFICATION_ATTEMPTS:
      _default: 3
    SMART_CONTRACT_VERIFIER__SOURCIFY__REQUEST_TIMEOUT:
      _default: 10
    SMART_CONTRACT_VERIFIER__METRICS__ENABLED:
      _default: 'true'
    SMART_CONTRACT_VERIFIER__METRICS__ADDR:
      _default: 0.0.0.0:6060
    SMART_CONTRACT_VERIFIER__METRICS__ROUTE:
      _default: /metrics
    SMART_CONTRACT_VERIFIER__JAEGER__ENABLED:
      _default: 'false'

# enable stats deploy
stats:
  enabled: true
  image:
    _default: ghcr.io/blockscout/stats:main

  # enable ingress
  ingress:
    enabled: true
    annotations:
      - 'nginx.ingress.kubernetes.io/cors-allow-origin: "https://*.blockscout-main.test.aws-k8s.blockscout.com, https://*.test.aws-k8s.blockscout.com, https://*.blockscout.com, http://localhost:3000"'
      - 'nginx.ingress.kubernetes.io/cors-allow-credentials: "true"'
      - 'nginx.ingress.kubernetes.io/cors-allow-methods: PUT, GET, POST, OPTIONS, DELETE, PATCH'
      - 'nginx.ingress.kubernetes.io/enable-cors: "true"'
    host:
      _default: stats-optimism-goerli.test.aws-k8s.blockscout.com
    # enable https
    tls:
      enabled: true

  resources:
    limits:
      memory:
        _default: "0.5Gi"
      cpu:
        _default: "0.25"
    requests:
      memory:
        _default: "0.5Gi"
      cpu:
        _default: "0.25"

  environment:
    RUST_LOG:
      _default: info
    STATS__RUN_MIGRATIONS:
      _default: true
    STATS__TRACING__FORMAT:
      _default: json
    STATS__METRICS__ENABLED:
      _default: true

frontend:
  app: blockscout
  enabled: true
  image:
    _default: ghcr.io/blockscout/frontend:v1.0.8
  ingress:
    enabled: true
    # annotations:
    #   - 'nginx.ingress.kubernetes.io/use-regex: "true"'
    host:
      _default: blockscout-optimism-goerli.test.aws-k8s.blockscout.com
    # enable https
    tls:
      enabled: true
    path:
      exact:
        # - "/(apps|auth/profile|account)"
        - "/"
      prefix:
        # - "/(apps|auth/profile|account)"
        - "/_next"
        - "/node-api"
        - "/account"
        - "/apps"
        - "/static"
        - "/auth/profile"
        - "/txs"
        - "/tx"
        - "/blocks"
        - "/block"
        - "/login"
        - "/address"
        - "/stats"
        - "/search-results"
        - "/token"
        - "/tokens"
        - "/csv-export"
        - "/verified-contracts"
        - "/graphiql"
        - "/accounts"
        - "/visualize"
        - "/api-docs"
        - "/l2-output-roots"
        - "/l2-txn-batches"
        - "/l2-withdrawals"
        - "/l2-deposits"
  resources:
    limits:
      memory:
        _default: "0.3Gi"
      cpu:
        _default: "0.2"
    requests:
      memory:
        _default: "0.3Gi"
      cpu:
        _default: "0.2"
  environment:
    NEXT_PUBLIC_BLOCKSCOUT_VERSION:
      _default: v5.1.2-beta
    NEXT_PUBLIC_FOOTER_GITHUB_LINK:
      _default: https://github.com/blockscout/blockscout
    NEXT_PUBLIC_FOOTER_TWITTER_LINK:
      _default: https://www.twitter.com/blockscoutcom
    NEXT_PUBLIC_APP_ENV:
      _default: stable
    NEXT_PUBLIC_APP_INSTANCE:
      _default: base_goerli
    NEXT_PUBLIC_NETWORK_NAME:
      _default: "Base Göerli"
    NEXT_PUBLIC_NETWORK_SHORT_NAME:
      _default: Base
    NEXT_PUBLIC_NETWORK_ASSETS_PATHNAME:
      _default: optimism
    NEXT_PUBLIC_NETWORK_ID:
      _default: 420
    NEXT_PUBLIC_NETWORK_CURRENCY_NAME:
      _default: Ether
    NEXT_PUBLIC_NETWORK_CURRENCY_SYMBOL:
      _default: ETH
    NEXT_PUBLIC_NETWORK_CURRENCY_DECIMALS:
      _default: 18
    NEXT_PUBLIC_NETWORK_VERIFICATION_TYPE:
      _default: validation
    NEXT_PUBLIC_IS_ACCOUNT_SUPPORTED:
      _default: 'true'
    NEXT_PUBLIC_NETWORK_LOGO:
      _default: https://raw.githubusercontent.com/blockscout/frontend-configs/main/configs/network-logos/base.svg
    NEXT_PUBLIC_NETWORK_ICON:
      _default: https://raw.githubusercontent.com/blockscout/frontend-configs/main/configs/network-icons/base.svg
    NEXT_PUBLIC_FEATURED_NETWORKS:
      _default: https://raw.githubusercontent.com/blockscout/frontend-configs/main/configs/featured-networks/base-goerli.json
    NEXT_PUBLIC_API_HOST:
      _default: blockscout-optimism-goerli.test.aws-k8s.blockscout.com
    NEXT_PUBLIC_APP_HOST:
      _default: blockscout-optimism-goerli.test.aws-k8s.blockscout.com
    NEXT_PUBLIC_API_BASE_PATH:
      _default: /
    NEXT_PUBLIC_MARKETPLACE_SUBMIT_FORM:
      _default: https://airtable.com/shrqUAcjgGJ4jU88C
    NEXT_PUBLIC_LOGOUT_URL:
      _default: https://blockscoutcom.us.auth0.com/v2/logout
    NEXT_PUBLIC_LOGOUT_RETURN_URL:
      _default: http://blockscout-optimism-goerli.test.aws-k8s.blockscout.com/auth/logout
    NEXT_PUBLIC_STATS_API_HOST:
      _default: https://stats-optimism-goerli.test.aws-k8s.blockscout.com
    NEXT_PUBLIC_API_SPEC_URL:
      _default: https://raw.githubusercontent.com/blockscout/blockscout-api-v2-swagger/main/swagger.yaml
    NEXT_PUBLIC_MARKETPLACE_CONFIG_URL:
      _default: https://raw.githubusercontent.com/blockscout/frontend-configs/dev/configs/marketplace/base-goerli.json
    NEXT_PUBLIC_NETWORK_EXPLORERS:
      _default: ''
    NEXT_PUBLIC_HOMEPAGE_PLATE_GRADIENT:
      _default: "linear-gradient(136.9deg,rgb(107 94 236) 1.5%,rgb(0 82 255) 56.84%,rgb(82 62 231) 98.54%)"
    NEXT_PUBLIC_NETWORK_TOKEN_ADDRESS:
      _default: ''
    NEXT_PUBLIC_NETWORK_RPC_URL:
      _default: https://goerli.optimism.io
    NEXT_PUBLIC_WEB3_DEFAULT_WALLET:
      _default: coinbase
    NEXT_PUBLIC_WEB3_DISABLE_ADD_TOKEN_TO_WALLET:
      _default: true
    NEXT_PUBLIC_HOMEPAGE_CHARTS:
      _default: "['daily_txs']"
    NEXT_PUBLIC_IS_TESTNET:
      _default: true
    NEXT_PUBLIC_VISUALIZE_API_HOST:
      _default: https://visualizer-optimism-goerli.test.aws-k8s.blockscout.com
    NEXT_PUBLIC_IS_L2_NETWORK:
      _default: "true"
    NEXT_PUBLIC_L1_BASE_URL:
      _default: https://eth-goerli.blockscout.com/
    NEXT_PUBLIC_L2_WITHDRAWAL_URL:
      _default: https://app.optimism.io/bridge/withdraw
    NEXT_PUBLIC_GRAPHIQL_TRANSACTION:
      _default: 0x4a0ed8ddf751a7cb5297f827699117b0f6d21a0b2907594d300dc9fed75c7e62
# enable blockscout-allowance
allowance:
  enabled: false

  image:
    _default: ghcr.io/blockscout/blockscout-allowance:main

  replicas:
    app: 1
  docker:
    port: 80
    targetPort: 3000

  service:
    # ClusterIP, NodePort or LoadBalancer
    type: ClusterIP

  ingress:
    enabled: true
    annotations: {}
    host:
      _default: blockscout-allowance.apps.aws-k8s.blockscout.com
    # enable https
    tls:
      enabled: true
      createSecret: false
    path:
      prefix:
        - "/"
      exact: {}

  resources:
    limits:
      memory:
        _default: 768Mi
      cpu:
        _default: 500m
    requests:
      memory:
        _default: 384Mi
      cpu:
        _default: 250m

  # node label
  nodeSelector:
    enabled: true
    labels:
      _default:
        app: blockscout

  environment: {}

# enable visualizer deploy
visualizer:
  enabled: true
  image:
    _default: ghcr.io/blockscout/visualizer:latest

  # enable ingress
  ingress:
    enabled: true
    host:
      _default: visualizer-optimism-goerli.test.aws-k8s.blockscout.com
    # enable https
    tls:
      enabled: true
      createSecret: false

  resources:
    limits:
      memory:
        _default: "0.05Gi"
      cpu:
        _default: "0.05"
    requests:
      memory:
        _default: "0.05Gi"
      cpu:
        _default: "0.05"

  # probes
  livenessProbe:
    enabled: true
    path: /health
  readinessProbe:
    enabled: true
    path: /health

  environment:
    VISUALIZER__SERVER__HTTP__ENABLED:
      _default: 'true'
    VISUALIZER__SERVER__HTTP__ADDR:
      _default: 0.0.0.0:8050
    VISUALIZER__SERVER__GRPC__ENABLED:
      _default: 'false'
