-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* update service ip as host ip * update service ip as host ip * update service ip as host ip * update service ip as host ip * update service ip as host ip * patch to fanglei's main --------- Co-authored-by: Wilson Wang <[email protected]>
- Loading branch information
1 parent
6d5ab81
commit 157327b
Showing
12 changed files
with
233 additions
and
53 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
name: SPEAR-TEST | ||
|
||
on: push | ||
|
||
jobs: | ||
Spear-build: | ||
name: make and run Spear DEMO | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Read warehouse contents | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Go | ||
uses: actions/setup-go@v4 | ||
with: | ||
go-version: '1.23' # 请根据需要选择合适的 Go 版本 | ||
|
||
- name: Verify Go version | ||
run: go version | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: '3.13' | ||
|
||
- name: Verify Python version | ||
run: python --version | ||
|
||
- name: Install Python dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install build | ||
- name: Install dependencies and compile files | ||
run: | | ||
sudo apt install portaudio19-dev libx11-dev libxtst-dev | ||
curl -fsSL https://get.docker.com -o get-docker.sh | ||
sudo sh get-docker.sh | ||
make | ||
- name: Set environment variables and run test program | ||
run: | | ||
ip_address=$(ip addr show eth0 | grep -oP 'inet \K[\d.]+') | ||
echo "IP Address: $ip_address" | ||
export SPEAR_RPC_ADDR=$ip_address | ||
echo "SPEAR_RPC_ADDR=$ip_address" >> $GITHUB_ENV | ||
OPENAI_API_KEY=${{ secrets.OPENAI_API_KEY }} | ||
HUGGINGFACEHUB_API_TOKEN=${{ secrets.HUGGINGFACEHUB_API_TOKEN }} | ||
export OPENAI_API_KEY=${{ secrets.OPENAI_API_KEY }} | ||
export HUGGINGFACEHUB_API_TOKEN=${{ secrets.HUGGINGFACEHUB_API_TOKEN }} | ||
echo "SPEAR_RPC_ADDR=$ip_address" >> $GITHUB_ENV | ||
echo "OPENAI_API_KEY=${{ secrets.OPENAI_API_KEY }}" >> $GITHUB_ENV | ||
echo "HUGGINGFACEHUB_API_TOKEN=${{ secrets.HUGGINGFACEHUB_API_TOKEN }}" >> $GITHUB_ENV | ||
go test -v ./test/simple_req_test.go |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
package common | ||
|
||
const MaxDataResponseSize = 4096 * 1024 | ||
const SpearPlatformAddress = "172.17.0.1" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.