Skip to content

Sync build is testing out GitHub Action #15

Sync build is testing out GitHub Action

Sync build is testing out GitHub Action #15

name: Public Sycl build
run-name: Sync build is testing out GitHub Action
on:
push:
branches:
- wenjun/build_check
schedule:
# Set to "0 0 * * *" to run it at midnight every day.
- cron: '50 6 * * *'
jobs:
Sync-Build-CI:
runs-on: Intel_openxla
steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Prepare Conda Environment
run: |
set +e
CONDA_ENV=Sync_build_nightly_${{ runner.name }}
source /opt/conda/bin/activate ${CONDA_ENV}
if [ $? -ne 0 ]; then
echo 'conda env does not exist'
conda create -n ${CONDA_ENV} python=3.10 -y
conda activate ${CONDA_ENV}
fi
pip install numpy
- name: Sync Build
run: |
set +e
CONDA_ENV=Sync_build_nightly_${{ runner.name }}
source /opt/conda/bin/activate ${CONDA_ENV}
#build
export SYCL_TOOLKIT_PATH=/home/sdp/intel/oneapi/compiler/2024.1
export workspace=$PWD/build_workspace
mkdir -p $workspace
export xla_path=$workspace/stock_xla
cd $workspace
git clone -b guizili/build https://github.com/Intel-tensorflow/xla stock_xla
#bash $xla_path/tools/ci_build/sycl_build/build_sycl.sh $workspace |& tee $workspace/build.log
build_result=${PIPESTATUS[0]}
echo $build_result
if [ "$build_result" = "0" ];then
echo "Build successful"
else
echo "Build Failed"
exit 1
fi
- name: Send mail
uses: dawidd6/action-send-mail@v3
with:
# Specify connection via URL (replaces server_address, server_port, secure,
# username and password)
#
# Format:
#
# * smtp://user:password@server:port
# * smtp+starttls://user:password@server:port
connection_url:
# Required mail server address if not connection_url:
server_address: [email protected]
# Server port, default 25:
server_port: 465
# Optional whether this connection use TLS (default is true if server_port is 465)
secure: true
# Optional (recommended) mail server username:
username: dgpu_validation_faceless
# Optional (recommended) mail server password:
password: qazwsxedcrfvtgb123@intel01
# Required mail subject:
subject: Github Actions job result
# Required recipients' addresses:
to: [email protected]
# Required sender full name (address can be skipped):
from: [email protected] # <[email protected]>
# Optional plain body:
body: Build job of ${{github.repository}} completed successfully!
# Optional HTML body read from file:
html_body: file://README.html
# Optional carbon copy recipients:
cc:
# Optional blind carbon copy recipients:
bcc:
# Optional recipient of the email response:
reply_to:
# Optional Message ID this message is replying to:
in_reply_to:
# Optional unsigned/invalid certificates allowance:
ignore_cert: true
# Optional converting Markdown to HTML (set content_type to text/html too):
convert_markdown: true
# Optional attachments:
attachments: attachments.zip,git.diff,./dist/static/*.js
# Optional priority: 'high', 'normal' (default) or 'low'
priority: high
# Optional nodemailerlog: true/false
nodemailerlog: true
# Optional nodemailerdebug: true/false if true lognodem will also be set true
nodemailerdebug: true