Metro is a universal currency designed for Minecraft servers, in a mostly Krist-compatible API format.
Running metro-server isn't hard to do in a development environment. In fact, you can do so in 6 steps.
- Create a .env file:
DBKEY
: The password/key for theroot
MySQL userBACKENDDBKEY
: The password/key for themetroweb
MySQL user
- Create
/backend/badwords.txt
: It's a normal text file, with one blocked phrase per line. An example is:
word1
word2
word3
This is not included in the repo for obvious reasons.
- Spin up Metro in Docker
- Execute
init.sql
inmetro-server-db
- Create the user
metroweb
in MySQL
CREATE USER metroweb IDENTIFIED BY 'yourbackenddbkey1234';
GRANT ALL PRIVILEGES ON *.* TO metroweb;
- Restart
metro-server-backend
- Finish API
- Address creation algorithm
- Reverse proxies (nginx)
- Documentation
- Automated testing
3rd commit
: Added more fields to thenames
table in MySQL. Migrate using:
ALTER TABLE names ADD COLUMN original_owner CHAR(10) NOT NULL;
ALTER TABLE names ADD COLUMN transferred DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP();
8th commit
: Added tablenamehistory
. Migrate using:
CREATE TABLE
namehistory (
id CHAR(36) NOT NULL,
address VARCHAR(24) NOT NULL,
wallet_to CHAR(10) NOT NULL,
wallet_from char(10) DEFAULT NULL,
timestamp DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP(),
type ENUM('transfer', 'purchase'),
PRIMARY KEY (id)
);
13th commit
: Changed columns under tablewallets
. Migrate using:
ALTER TABLE transactions MODIFY COLUMN type ENUM('transfer', 'name_purchase', 'name_transfer', 'tax') NOT NULL;
ALTER TABLE transactions ADD COLUMN state ENUM('completed', 'pending', 'reverted', 'held') NOT NULL DEFAULT 'pending';
-
19th commit
: Addedbadwords.txt
. Read development environment creation step for more details. -
20th commit
: Renamednamehistory
columnid
touuid
. Migrate using:
ALTER TABLE namehistory RENAME COLUMN id TO uuid;
20th commit
: Changed columnpkeyhash
onwallets
toNOT NULL
. Migrate using:
ALTER TABLE wallets MODIFY pkeyhash CHAR(128) NOT NULL;
21st commit
: Changed columntype
ontransactions
. Migrate using:
ALTER TABLE transactions MODIFY COLUMN type ENUM('transfer', 'tax') NOT NULL;