Skip to content

feat: sync system time with ntp #392

feat: sync system time with ntp

feat: sync system time with ntp #392

Workflow file for this run

name: Master
on:
push:
branches: [master]
jobs:
cancel-previous:
runs-on: ubuntu-latest
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
build-web:
uses: ./.github/workflows/build-web.yml
download-musl-cc:
uses: ./.github/workflows/download-musl-cc.yml
build-musl:
needs:
- build-web
- download-musl-cc
uses: ./.github/workflows/build-musl.yml
build-gnu:
needs:
- build-web
uses: ./.github/workflows/build-gnu.yml
build-other:
needs:
- build-musl
- build-gnu
uses: ./.github/workflows/build-other.yml
dev-release:
runs-on: ubuntu-latest
needs:
- build-other
steps:
# Checkout
- name: Checkout
uses: actions/checkout@v2
- name: Fix cargo config
run: sed -e "s/.*replace-with.*//g" -i .cargo/config.toml
- name: Download all
uses: actions/download-artifact@v3
with:
name: pisugar-all
- name: Create archives
run: |
mkdir -p archives
cp -R target/* archives/
cp scripts/*.sh archives/
cp scripts/aur/*.tar.gz archives/
tar -czf archives.tar.gz archives
# Development Release
- uses: "marvinpinto/action-automatic-releases@latest"
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
automatic_release_tag: "latest"
title: "Development Build"
prerelease: true
draft: false
files: |
archives.tar.gz
target/**/*.deb
target/**/*.rpm
scripts/*.sh
scripts/aur/*.tar.gz
!scripts/update-version.sh
pisugar-module.tar.gz
# Upload QiNiu nightly
- name: "Upload to QiNiu"
env:
QINIU_BUCKET: ${{ secrets.QINIU_BUCKET }}
QINIU_AK: ${{ secrets.QINIU_AK }}
QINIU_SK: ${{ secrets.QINIU_SK }}
run: |
sudo apt-get update
sudo apt-get install -y unzip
if [ $(uname -m) == 'x86_64' ]; then
wget https://github.com/qiniu/qshell/releases/download/v2.9.0/qshell-v2.9.0-linux-amd64.tar.gz
tar -xvf qshell-v2.9.0-linux-amd64.tar.gz
else
wget https://github.com/qiniu/qshell/releases/download/v2.9.0/qshell-v2.9.0-linux-386.tar.gz
tar -xvf qshell-v2.9.0-linux-386.tar.gz
fi
chmod +x qshell
./qshell account -w ${QINIU_AK} ${QINIU_SK} deploy-account
for f in $(find target -type f -name '*.deb') $(find target -type f -name '*.rpm') $(find scripts -name '*.tar.gz'); do
filename=${f##*/}
key=nightly/${filename}
./qshell rput --overwrite ${QINIU_BUCKET} ${key} ${f}
done
for f in $(find scripts -name '*.sh' ); do
filename=${f##*/}
key=nightly/${filename}
./qshell rput --overwrite --mimetype text/plain ${QINIU_BUCKET} ${key} ${f} &
done
wait
echo "All uploaded to qiniu"