-
-
Notifications
You must be signed in to change notification settings - Fork 242
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use docker/build-push-action@ in CI instead of upload-docker.sh (#2342)
* Use docker/build-push-action@ * Deprecate upload-docker.sh * pipeline * Remove upload-docker.sh * pwd * Push: true * Use build-push-action for build deploy dev * Update dev & beta CI jobs * More * Update release jobs * changelog * cspell * auto-update fix
- Loading branch information
Showing
12 changed files
with
295 additions
and
947 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -62,7 +62,7 @@ jobs: | |
######################################################## | ||
- uses: actions/[email protected] | ||
with: | ||
node-version: "12.x" | ||
node-version: "16.x" | ||
registry-url: "https://registry.npmjs.org" | ||
- run: cd mega-linter-runner && yarn install --frozen-lockfile | ||
- run: cd mega-linter-runner && BETAID=$(date '+%Y%m%d%H%M') && npm version prerelease --preid="beta$BETAID" | ||
|
@@ -71,37 +71,42 @@ jobs: | |
env: | ||
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} | ||
|
||
##################### | ||
# Run Deploy script # | ||
##################### | ||
- name: Deploy beta image to DockerHub | ||
env: | ||
# Set the Env Vars | ||
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }} | ||
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }} | ||
IMAGE_REPO: oxsecurity/megalinter | ||
IMAGE_VERSION: beta | ||
DOCKERFILE_PATH: Dockerfile | ||
DOCKER_BUILD_PLATFORMS: linux/amd64 | ||
REGISTRY: Docker | ||
shell: bash | ||
run: .automation/upload-docker.sh | ||
- name: Set up QEMU | ||
uses: docker/setup-qemu-action@v2 | ||
|
||
############################# | ||
# Run Deploy script for GPR # | ||
############################# | ||
- name: Deploy beta image to GitHub Container Registry | ||
env: | ||
# Set the Env Vars | ||
GCR_USERNAME: ${{ secrets.GCR_USERNAME }} | ||
GCR_TOKEN: ${{ secrets.GCR_PASSWORD }} | ||
IMAGE_REPO: oxsecurity/megalinter | ||
IMAGE_VERSION: beta | ||
DOCKERFILE_PATH: Dockerfile | ||
DOCKER_BUILD_PLATFORMS: linux/amd64 | ||
REGISTRY: GCR | ||
shell: bash | ||
run: .automation/upload-docker.sh | ||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v2 | ||
|
||
- name: Login to Docker Hub | ||
uses: docker/login-action@v2 | ||
with: | ||
username: ${{ secrets.DOCKER_USERNAME }} | ||
password: ${{ secrets.DOCKER_PASSWORD }} | ||
|
||
- name: Login to GitHub Container Registry | ||
uses: docker/login-action@v2 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.repository_owner }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Build & Push Docker Image | ||
uses: docker/build-push-action@v3 | ||
with: | ||
context: . | ||
file: Dockerfile | ||
platforms: linux/amd64 | ||
build-args: | | ||
BUILD_DATE=${{ env.BUILD_DATE }} | ||
BUILD_REVISION=${{ github.sha }} | ||
BUILD_VERSION=${{ github.sha }} | ||
load: false | ||
push: true | ||
secrets: | | ||
GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }} | ||
tags: | | ||
oxsecurity/megalinter:beta | ||
ghcr.io/oxsecurity/megalinter:beta | ||
############################### | ||
# Run tests for code coverage # | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.