
set HTTP_PROXY=http://127.0.0.1:7899
set HTTPS_PROXY=http://127.0.0.1:7899

# 设置
# mc.exe alias set oracle-osaka-1  https://axzsapxffbbn.compat.objectstorage.ap-osaka-1.oraclecloud.com b0696c316f87b644b4a13bcb020f095cd147be0b GAIaM/064epLzQcXsRbj2gwlFOrVepjCR23wj2tfJ+A= 

# mc.exe ls oracle-osaka-1/osaka 

# 设置 韩国oss
#mc.exe alias set oracle-seoul-2  https://cncvl8ro2rbf.compat.objectstorage.ap-seoul-1.oraclecloud.com 9e413c6e66269bc65d7ec951d93ba9c6a9781f6e dkXD7PysjrhsTKfNIbKupUmtxdfOvYCyLXf0MXa4hnU=
#mc.exe ls oracle-seoul-2/seoul-2

# 重新build项目
Set-Location "C:\\Users\\wddsh\\Documents\\IdeaProjects\\WddSuperAgent\\agent-wdd\"
& "C:\Users\wddsh\go\bin\gox.exe" -osarch="linux/amd64" -output "./build/agent-wdd_{{.OS}}_{{.Arch}}"

& "C:\Users\wddsh\go\bin\gox.exe" -osarch="linux/arm64" -output "./build/agent-wdd_{{.OS}}_{{.Arch}}"

Set-Location "C:\Users\wddsh\Documents\IdeaProjects\WddSuperAgent\agent-wdd\a_run"
Write-Host "build项目成功"
Write-Host ""

# 删除上面存在的旧的内容
mc.exe rm oracle-seoul-2/seoul-2/agent-wdd_linux_amd64
mc.exe rm oracle-seoul-2/seoul-2/agent-wdd_linux_arm64
Write-Host "删除旧的内容成功"
Write-Host ""

# 上传文件
mc.exe cp C:\Users\wddsh\Documents\IdeaProjects\WddSuperAgent\agent-wdd\build\agent-wdd_linux_amd64 oracle-seoul-2/seoul-2/
mc.exe cp C:\Users\wddsh\Documents\IdeaProjects\WddSuperAgent\agent-wdd\build\agent-wdd_linux_arm64 oracle-seoul-2/seoul-2/
Write-Host "上传文件成功"
Write-Host ""









