[ github-action ] 新增Agent版本控制 - 2
This commit is contained in:
5
.github/workflows/build-push-docker.yml
vendored
5
.github/workflows/build-push-docker.yml
vendored
@@ -129,13 +129,12 @@ jobs:
|
||||
cd ./agent/target
|
||||
ls
|
||||
echo "start to change timezone to Asia/Shanghai"
|
||||
timedatectl set-timezone Asia/Shanghai && timedatectl set-ntp true
|
||||
# timedatectl set-timezone Asia/Shanghai && timedatectl set-ntp true
|
||||
echo "current time is $(date --rfc-3339=seconds | cut -d"+" -f1 | sed "s/ /-/g" | sed "s/:/-/g")"
|
||||
echo "current time is $(date)"
|
||||
echo "start to copy target jar"
|
||||
|
||||
echo "AGENT_VERSION=$(date --rfc-3339=seconds | cut -d"+" -f1 | sed "s/ /-/g" | sed "s/:/-/g")" >>
|
||||
$GITHUB_ENV
|
||||
echo "AGENT_VERSION=$(date --rfc-3339=seconds | cut -d"+" -f1 | sed "s/ /-/g" | sed "s/:/-/g")" >> $GITHUB_ENV
|
||||
|
||||
cp ./agent-*.jar ./octopus-agent-${{ env.AGENT_VERSION }}.jar
|
||||
|
||||
|
||||
Reference in New Issue
Block a user