diff --git a/.github/workflows/sync-code.yaml b/.github/workflows/sync-code.yaml deleted file mode 100644 index 63cbd4e..0000000 --- a/.github/workflows/sync-code.yaml +++ /dev/null @@ -1,31 +0,0 @@ -name: sync-code - -on: - push: - branches: - - main - - 'coding-test/**' - - 'pipeline/**' - tags: v* - -jobs: - sync: - runs-on: ubuntu-latest - - steps: - - name: clone - run: | - if [ -d packer-plugin-tencentcloud ]; then - rm -rf packer-plugin-tencentcloud - fi - git clone https://github.com/tencentcloudstack/packer-plugin-tencentcloud.git - - name: sync - run: | - cd packer-plugin-tencentcloud - git fetch --all - git branch -r --list "origin/coding-test/*" | grep -v HEAD | grep -v master | xargs -I {} git checkout -t {} - git branch -r --list "origin/pipeline/*" | grep -v HEAD | grep -v master | xargs -I {} git checkout -t {} - git remote add tgit_origin https://${{ secrets.USERNAME }}:${{ secrets.PASSWORD }}@git.code.tencent.com/tencentcloudstack/packer-plugin-tencentcloud.git - git push -u tgit_origin -f --all - git push -u tgit_origin main:main - git push -u tgit_origin --tags diff --git a/builder/tencentcloud/cvm/run_config.go b/builder/tencentcloud/cvm/run_config.go index d7cc171..82df220 100644 --- a/builder/tencentcloud/cvm/run_config.go +++ b/builder/tencentcloud/cvm/run_config.go @@ -116,7 +116,8 @@ var ValidCBSType = []string{ } func (cf *TencentCloudRunConfig) Prepare(ctx *interpolate.Context) []error { - packerId := fmt.Sprintf("packer_%s", uuid.TimeOrderedUUID()[:8]) + timeOrderedUUID := uuid.TimeOrderedUUID() + packerId := fmt.Sprintf("packer_%s_%s", timeOrderedUUID[:8], timeOrderedUUID[9:13]) if cf.Comm.SSHKeyPairName == "" && cf.Comm.SSHTemporaryKeyPairName == "" && cf.Comm.SSHPrivateKeyFile == "" && cf.Comm.SSHPassword == "" && cf.Comm.WinRMPassword == "" { //tencentcloud support key pair name length max to 25
Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.
Alternative Proxies: