Avoid ACTIONS_ALLOW_UNSECURE_COMMANDS
@@ -237,14 +237,12 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: Get release version
- id: get_version
+ id: versions
run: |
checkov_version=${{ needs.publish-package.outputs.version }}
checkov_major_version=$(echo "${checkov_version}" | head -c1)
- echo ::set-env name=RELEASE_VERSION::$(echo $checkov_version)
- echo ::set-env name=RELEASE_MAJOR_VERSION::$(echo $checkov_major_version)
- env:
- ACTIONS_ALLOW_UNSECURE_COMMANDS: 'true'
+ echo "::set-output name=version::$checkov_version"
+ echo "::set-output name=major_version::$checkov_major_version"
- name: Publish to Registry
uses: elgohr/Publish-Docker-Github-Action@master
with:
@@ -252,7 +250,7 @@ jobs:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
buildoptions: "--no-cache"
- tags: "latest,${{ env.RELEASE_VERSION }},${{ env.RELEASE_MAJOR_VERSION }}"
+ tags: "latest,${{ steps.versions.outputs.version }},${{ steps.versions.outputs.major_version }}"
publish-checkov-k8s-dockerhub:
runs-on: [self-hosted, public, linux, x64]
needs: publish-package
@@ -262,18 +260,16 @@ jobs:
run: |
checkov_version=${{ needs.publish-package.outputs.version }}
checkov_major_version=$(echo "${checkov_version}" | head -c1)
- echo ::set-env name=RELEASE_VERSION::$(echo $checkov_version)
- echo ::set-env name=RELEASE_MAJOR_VERSION::$(echo $checkov_major_version)
- echo $RELEASE_VERSION
- env:
- ACTIONS_ALLOW_UNSECURE_COMMANDS: 'true'
+ echo "::set-output name=version::$checkov_version"
+ echo "::set-output name=major_version::$checkov_major_version"
+ id: versions
- name: Publish to Registry
uses: elgohr/Publish-Docker-Github-Action@master
with:
name: bridgecrew/checkov-k8s
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- tags: "latest,${{ env.RELEASE_VERSION }},${{ env.RELEASE_MAJOR_VERSION }}"
+ tags: "latest,${{ steps.versions.outputs.version }},${{ steps.versions.outputs.major_version }}"
dockerfile: kubernetes/Dockerfile
buildoptions: "--no-cache"
publish-checkov-admissioncontroller-dockerhub:
