Skip to content

Bump axios from 1.6.7 to 1.6.8 #1026

Bump axios from 1.6.7 to 1.6.8

Bump axios from 1.6.7 to 1.6.8 #1026

Workflow file for this run

name: Build
on:
pull_request:
types: [opened, reopened, synchronize]
branches: [master]
release:
types: [published]
env:
NODE_VERSION: 18.x # Should match version in Dockerfile
SONAR_DIRECTORY: /github/workspace
DOCKERHUB_USER: thilas
IMAGE_NAME: plex-betaseries-webhook
jobs:
build:
name: Build
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
- name: Docker meta
id: meta
uses: docker/metadata-action@v5
with:
images: |
ghcr.io/${{ github.repository }}
${{ github.event_name != 'pull_request' && format('{0}/{1}', env.DOCKERHUB_USER, env.IMAGE_NAME) || '' }}
tags: |
type=ref,event=pr
type=semver,pattern={{version}}
- name: Bump version
if: github.event_name != 'pull_request'
env:
VERSION: ${{ steps.meta.outputs.version }}
run: npm --no-git-tag-version version "$VERSION"
- name: Create SonarCloud scanner default working directory
run: |
sudo mkdir --parents "$SONAR_DIRECTORY"
sudo mount --bind "$GITHUB_WORKSPACE" "$SONAR_DIRECTORY"
- name: Use Node.js ${{ env.NODE_VERSION }}
uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
- run: npm ci
- run: npm run build
- run: npm test
working-directory: ${{ env.SONAR_DIRECTORY }} # Align on SonarCloud scanner default working directory
- name: SonarCloud scan
continue-on-error: ${{ github.event_name == 'pull_request' }} # because scanning from forks is not supported for now
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
uses: SonarSource/sonarcloud-github-action@v2.1.1
with:
args: -Dsonar.projectVersion=${{ steps.meta.outputs.version }}
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to GitHub Container Registry
if: github.actor == github.repository_owner
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Log into Docker Hub
if: github.event_name != 'pull_request'
uses: docker/login-action@v3
with:
username: ${{ env.DOCKERHUB_USER }}
password: ${{ secrets.DH_PAT }}
- name: Build and push docker image
uses: docker/build-push-action@v5
with:
context: .
platforms: linux/amd64,linux/arm/v7
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
push: ${{ github.actor == github.repository_owner }}