This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
import 'package:tonedetector/Screens/Login/login_screen.dart'; | |
import 'package:tonedetector/Screens/Welcome/welcome_screen.dart'; | |
import 'package:tonedetector/constants.dart'; | |
void main() { | |
runApp(MyApp()); | |
} | |
class MyApp extends StatelessWidget { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh | |
source $HOME/.cargo/env | |
curl https://getsubstrate.io -sSf | bash -s -- --fast | |
# Update Rust | |
rustup update nightly | |
rustup update stable | |
# Add Wasm target | |
rustup target add wasm32-unknown-unknown --toolchain nightly |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Install from git | |
git clone https://github.com/hskang9/did-project.git # or your substrate git repository | |
cd did-project | |
cargo build --release | |
cd ~/ | |
# Kill all storage | |
rm -rf /tmp/validator | |
rm -rf nohup.validator.out | |
/root/did-project/target/release/node-template build-spec --chain=local > customSpec.json | |
/root/did-project/target/release/node-template build-spec --chain customSpec.json --raw > customSpecRaw.json |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
user www-data; | |
worker_processes 4; | |
events { | |
worker_connections 768; | |
# multi_accept on; | |
} | |
http { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# How to setup | |
# 1. Prepare thunder.json with allocated coinbase address generated from /home/ubuntu/thundercore-localchain/build/bin/puppeth | |
# | |
# 2. Initialize thunder token with init command | |
# | |
# 3. Specify etherbase (thundertoken address as an ethereum address) and add it as option --etherbase on ExecStart command. | |
# | |
# 3. sudo vi /lib/systemd/system/{service name}.service and copy/paste this code as a starter | |
# | |
# 4. Configure log folders and user to execute the command and give access with following commands |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
useradd -m -s /bin/bash prometheus | |
# (or adduser --disabled-password --gecos "" prometheus) | |
# Download node_exporter release from original repo | |
curl -L -O https://github.com/prometheus/node_exporter/releases/download/v0.17.0/node_exporter-0.17.0.linux-amd64.tar.gz | |
tar -xzvf node_exporter-0.17.0.linux-amd64.tar.gz | |
mv node_exporter-0.17.0.linux-amd64 /home/prometheus/node_exporter | |
rm node_exporter-0.17.0.linux-amd64.tar.gz | |
chown -R prometheus:prometheus /home/prometheus/node_exporter |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# How to setup | |
# 1. sudo vi /lib/systemd/system/{service name}.service and copy/paste this code as a starter | |
# | |
# 2. Configure log folders and user to execute the command and give access with following commands | |
# sudo chmod 755 /lib/systemd/system/{service name}.service | |
# | |
# 3. Configure systemctl to register the service in the system as start script with `enable` | |
# sudo systemctl enable {service name}.service | |
# | |
# 4. `start` service to test registered service scripts |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const HoverContainer = styled.div` | |
background: url(${props => props.image}); | |
background-size: cover; | |
background-position: center; | |
height: 100%; | |
color: white; | |
padding: 20px; | |
font-size: 18px; | |
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif; | |
font-weight: bold; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export class Hover extends React.Component<Props> { | |
// Set default properties | |
static defaultProps = { | |
text: "Hello World!", | |
color: "black", | |
} | |
// Items shown in property panel | |
static propertyControls: PropertyControls = { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Define type of property | |
interface Props { | |
text: string; | |
color: string; | |
} |