referrerpolicy=no-referrer-when-downgrade

polkadot_parachain/chain_spec/
collectives.rs

1// Copyright (C) Parity Technologies (UK) Ltd.
2// This file is part of Cumulus.
3// SPDX-License-Identifier: Apache-2.0
4
5// Licensed under the Apache License, Version 2.0 (the "License");
6// you may not use this file except in compliance with the License.
7// You may obtain a copy of the License at
8//
9// 	http://www.apache.org/licenses/LICENSE-2.0
10//
11// Unless required by applicable law or agreed to in writing, software
12// distributed under the License is distributed on an "AS IS" BASIS,
13// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14// See the License for the specific language governing permissions and
15// limitations under the License.
16
17use polkadot_omni_node_lib::chain_spec::{Extensions, GenericChainSpec};
18use sc_service::ChainType;
19
20/// Collectives Westend Development Config.
21pub fn collectives_westend_development_config() -> GenericChainSpec {
22	let mut properties = sc_chain_spec::Properties::new();
23	properties.insert("ss58Format".into(), 42.into());
24	properties.insert("tokenSymbol".into(), "WND".into());
25	properties.insert("tokenDecimals".into(), 12.into());
26
27	GenericChainSpec::builder(
28		collectives_westend_runtime::WASM_BINARY
29			.expect("WASM binary was not built, please build it!"),
30		Extensions::new_with_relay_chain("westend-dev".into()),
31	)
32	.with_name("Westend Collectives Development")
33	.with_id("collectives_westend_dev")
34	.with_chain_type(ChainType::Development)
35	.with_genesis_config_preset_name(sp_genesis_builder::DEV_RUNTIME_PRESET)
36	.with_boot_nodes(Vec::new())
37	.with_properties(properties)
38	.build()
39}
40
41/// Collectives Westend Local Config.
42pub fn collectives_westend_local_config() -> GenericChainSpec {
43	let mut properties = sc_chain_spec::Properties::new();
44	properties.insert("ss58Format".into(), 42.into());
45	properties.insert("tokenSymbol".into(), "WND".into());
46	properties.insert("tokenDecimals".into(), 12.into());
47
48	GenericChainSpec::builder(
49		collectives_westend_runtime::WASM_BINARY
50			.expect("WASM binary was not built, please build it!"),
51		Extensions::new_with_relay_chain("westend-local".into()),
52	)
53	.with_name("Westend Collectives Local")
54	.with_id("collectives_westend_local")
55	.with_chain_type(ChainType::Local)
56	.with_genesis_config_preset_name(sp_genesis_builder::LOCAL_TESTNET_RUNTIME_PRESET)
57	.with_boot_nodes(Vec::new())
58	.with_properties(properties)
59	.build()
60}