-
-
Notifications
You must be signed in to change notification settings - Fork 787
91 lines (84 loc) · 3.38 KB
/
smoke_test_cross_silo_lightsecagg_win.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
# This is a basic workflow to help you get started with Actions
name: LightSecAgg-Windows
# Controls when the workflow will run
on:
# Triggers the workflow on push or pull request events but only for the master branch
schedule:
# Nightly build at 12:12 A.M.
- cron: "12 12 */1 * *"
pull_request:
branches: [ master2, test/v0.7.0 ]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
cross-silo-horizontal-test:
defaults:
run:
shell: powershell
working-directory: fedml-devops\python
strategy:
fail-fast: false
matrix:
os: [ windows-2019 ]
arch: [X64]
python-version: ['3.8']
client-index: ['0', '1', '2']
# exclude:
# - os: macos-latest
# python-version: '3.8'
# - os: windows-latest
# python-version: '3.6'
runs-on: [self-hosted, runner-windows, devops]
timeout-minutes: 15
steps:
- name: cleanup running processes
continue-on-error: true
run: |
wmic.exe /interactive:off process where "name='python.exe'" call terminate
- name: Extract branch name
shell: bash
run: echo "branch=$(echo ${GITHUB_REF#refs/heads/})" >>$GITHUB_OUTPUT
id: extract_branch
- id: fedml_source_code_home
name: cd to master or dev branch and git pull
shell: bash
run: |
ls
echo ${{ steps.extract_branch.outputs.branch }}
if [[ ${{ steps.extract_branch.outputs.branch }} == "master" ]]; then
echo "running on master"
path=/home/actions-runner/fedml-master
cd $path
echo "dir=$path" >> $GITHUB_OUTPUT
else
echo "running on dev"
path=/home/actions-runner/fedml-dev
cd $path
echo "dir=$path" >> $GITHUB_OUTPUT
fi
- name: sync git repo to local pip
working-directory: ${{ steps.fedml_source_code_home.outputs.dir }}
run: |
homepath=${{ format('{0}', steps.fedml_source_code_home.outputs.dir) }}
echo $Homepath
cd $homepath
bash ./devops/scripts/sync-fedml-pip.sh
- name: server - cross-silo - ho
working-directory: ${{ steps.fedml_source_code_home.outputs.dir }}
run: |
cd examples/cross_silo/light_sec_agg_example
.\run_server.bat cross-silo-lightsecagg-${{ format('{0}{1}{2}{3}', github.run_id, matrix.os, matrix.arch, matrix.python-version) }}
if: ${{ matrix.client-index == '0' }}
- name: client 1 - cross-silo - ho
working-directory: ${{ steps.fedml_source_code_home.outputs.dir }}
run: |
cd examples/cross_silo/light_sec_agg_example
.\run_client.bat 1 cross-silo-lightsecagg-${{ format('{0}{1}{2}{3}', github.run_id, matrix.os, matrix.arch, matrix.python-version) }}
if: ${{ matrix.client-index == '1' }}
- name: client 2 - cross-silo - lightsecagg
working-directory: ${{ steps.fedml_source_code_home.outputs.dir }}
run: |
cd examples/cross_silo/light_sec_agg_example
.\run_client.bat 2 cross-silo-lightsecagg-${{ format('{0}{1}{2}{3}', github.run_id, matrix.os, matrix.arch, matrix.python-version) }}
if: ${{ matrix.client-index == '2' }}