Skip to content

Commit

Permalink
Show world explore url
Browse files Browse the repository at this point in the history
  • Loading branch information
JunichiSugiura committed Feb 19, 2024
1 parent 504b83e commit 151d1c7
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions bin/torii/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ use std::net::SocketAddr;
use std::str::FromStr;
use std::sync::Arc;

use base64::engine::general_purpose;
use base64::Engine as _;
use clap::Parser;
use common::parse::{parse_socket_address, parse_url};
use dojo_world::contracts::world::WorldContractReader;
Expand Down Expand Up @@ -188,8 +190,11 @@ async fn main() -> anyhow::Result<()> {
)
.expect("Failed to start libp2p relay server");

info!(target: "torii::cli", "Starting torii endpoint: {}", format!("http://{}", args.addr));
info!(target: "torii::cli", "Serving Graphql playground: {}\n", format!("http://{}/graphql", args.addr));
let endpoint = format!("http://{}", args.addr);
let encoded = general_purpose::STANDARD.encode(&endpoint).to_string();
info!(target: "torii::cli", "Starting torii endpoint: {}", endpoint);
info!(target: "torii::cli", "Serving Graphql playground: {}", format!("http://{}/graphql", args.addr));
info!(target: "torii::cli", "World explorer is available on: {}\n", format!("https://worlds.dev/torii/{}", encoded));

Check warning on line 197 in bin/torii/src/main.rs

View check run for this annotation

Codecov / codecov/patch

bin/torii/src/main.rs#L193-L197

Added lines #L193 - L197 were not covered by tests

if let Some(listen_addr) = args.metrics {
let prometheus_handle = prometheus_exporter::install_recorder("torii")?;
Expand Down

0 comments on commit 151d1c7

Please sign in to comment.