This application was generated with sonic
To bring up all the dependencies, run docker-compose up -Vd
Afterwards, enable the Transit engine for Vault with vault secrets enable transit
Also, you may want to run source .env
to load Peatio, Barong and Sonic public keys for development use
[Optional] To load the Vault policy and create a token, follow these steps:
- Open
config/sonic.hcl
and substitutedeployment_id
with your actual deployment ID - Run
export VAULT_ADDR=http://localhost:8200
export VAULT_TOKEN=*changeme*
vault policy write *deployment_id*_sonic config/sonic.hcl
vault token create -policy *deployment_id*_sonic -period=768h
read_engines:
mandatory_signers:
- sonic
permitted_signers:
- sonic
write_engines:
mandatory_signers:
- sonic
permitted_signers:
- sonic
read_markets:
mandatory_signers:
- sonic
permitted_signers:
- sonic
write_markets:
mandatory_signers:
- sonic
permitted_signers:
- sonic
- Use the resulting Vault token when running the application
-
Copy your frontend application source files to the
client/
folder -
Use the Makefile:
make asset
This will run the build command in client/
and move the build output to public/assets/
.
Warning: Make sure to build your client (frontend) into the build/
folder, if it's a different folder, you must update your client (frontend) or Makefile
- Start the go server
go run app.go serve
If it doesn't work and you see the white screen, check the order of import files in index.html