How to launch Swarm for dapp testing

  • a decentralized virtual machine that runs “smart contracts” for the global base blockchain
  • a peer to peer, multi-protocol IDE developer tools to build dapps that administer custom tokens, manage accounts and transactions, and execute immutable contracts that take banking, commerce, fundraising, and democracy to a whole new level

A growing ecosystem for web 3.0 projects

+ Source: Fast Company

So, what is Swarm exactly, and how does it work?

Launching the Swarm TestNet for the First Time

  • create a Go workspace directory, preferably in the HOME directory
  • define the $GOPATH env var to point to this directory
  • and echo this path to your startup script
  • create workspace directories (nest, top down: src, github.com, ethereum)
  • cd into ethereum and clone go-ethereum from GitHub
  • cd into go-ethereum and grab all the project dependencies
  • run “go install -v ./cmd/geth”
  • then, run “go install -v ./cmd/swarm”
(packages compiling)
(everything’s good, like it oughta be)
  • set up a geth account with two options: (1) testnet (indicating this is a TestNet account); (2) datadir (pointing to the data directory you just created)
  • add account new at the end
  • choose a password when prompted
(new geth account)
(geth node running, blockchain downloading)
(TestNet key)
(IPC endpoint opening)
(peer connections for swarm instance)
(http interface running on port 8500)
(swarm landing page)
(photoalbum dapp on web 3.0)
(dapp delete, post, put, get controls)
(hash hex value — starting with 7, excluding that “/#1” at the end)

Sharing your applications with the public

  • copy the hash
  • open up a new browser window
  • preface with swarms public gateway + the bzz protocol
  • paste hash to top it off
(sample dapp via Swarm’s public gateway)

--

--

--

Research Software Engineer (ML, DL, Blockchain, Android), budding cryptologist, writer and aspiring polymath.

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

♠️ Blockchain Capital crypto portfolio breakdown

Zaddex is fast news…

Analysis : Libra’s White Paper

Trittium - Weekly Report #7

What’s behind Larry David and LeBron James Super Bowl ads

Photo byLos Angeles Times

Trittium — Weekly Report #38

Trittium — Weekly Report #56

MenaPay ICO Review

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
AnnMargaret Tutu

AnnMargaret Tutu

Research Software Engineer (ML, DL, Blockchain, Android), budding cryptologist, writer and aspiring polymath.

More from Medium

BlockVision Live on Optimism to Improve Efficiency Building on Web 3.0

How Lightshift helped ICHI go Cross-Chain

What is Web3.0 —  A Deep dive, beginner level explanation of Web3.0 and Dapps

DeFi: A guide for guppies, part deux