Run this once to generate or update your Cargo.lock using Docker:
docker build -f Dockerfile.lockgen -t lockgen . && docker run -d --name lockgen-container lockgen tail -f /dev/null && docker cp lockgen-container:/app/Cargo.lock ./Cargo.lock && docker rm -f lockgen-container && docker rmi lockgenTo build and run the project interactively using Docker (with live code volume):
docker build -f Dockerfile.dev -t main . && docker run --rm -it -v "$(pwd):/app" mainThis allows you to iterate quickly during development.
docker build -f Dockerfile.binaryextract -t binarygen . && docker run -d --name binary-container binarygen tail -f /dev/null && docker cp binary-container:/app/target/x86_64-unknown-linux-musl/release/main ./main && docker rm -f binary-container && docker rmi binarygenMake the file executable and run it in the background, saving output to a log file:
sudo chmod +x main && ./main > logs.txt 2>&1 & disownThen, monitor the log file in real time:
tail -f logs.txtMake sure
.envis in the same directory.dotenv()loads.envfrom the working directory.
docker build -t main . && docker run --rm --env-file .env mainThis ensures environment variables are passed to the container even if
.envisn't loaded natively by the executable.
Microsoft Azure - Standard B2ats v2 (2 vCPUs, 1 GiB memory)
Best Regions:
- (Asia Pacific) East Asia: 48 ms <== (possibly Hong Kong)
- (Asia Pacific) Japan East: 50 ms
- (Asia Pacific) Korea Central: 51 ms
- (Asia Pacific) Southeast Asia: 76 ms
💰 $9.56/month
- Securely copies main and .env to the remote server's home directory via SSH:
scp "C:\WORKSPACES\TriangularArbitrage\main" "C:\WORKSPACES\TriangularArbitrage\.env" azureuser@20.205.131.172:~- Then connect to the VM via SSH:
ssh azureuser@20.205.131.172