Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions .github/ISSUE_TEMPLATE/patch_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,10 @@ assignees: petruki
A clear and concise description of why the patch is needed.

**Current dependency**
- **Name**:
- **Version**:
- **name@version**:

**Optional - Remediation**
- **Name**:
- **Version**:
- **name@version**:

**Additional context**
Links or documentation to the vulnerability or dependency update.
44 changes: 23 additions & 21 deletions .github/workflows/master.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:

steps:
- name: Git checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0

Expand All @@ -25,7 +25,7 @@ jobs:
node-version: 20.x

- name: Start MongoDB
uses: supercharge/mongodb-github-action@1.9.0
uses: supercharge/mongodb-github-action@1.10.0
with:
mongodb-version: 6.0

Expand Down Expand Up @@ -73,20 +73,20 @@ jobs:

steps:
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
uses: docker/setup-buildx-action@v3

- name: Login to DockerHub
uses: docker/login-action@v2
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build and push
id: docker_build
uses: docker/build-push-action@v3
uses: docker/build-push-action@v5
with:
push: true
platforms: linux/amd64,linux/arm64
Expand All @@ -99,28 +99,30 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
ref: 'master'

- name: Checkout Kustomize
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
token: ${{ secrets.ARGOCD_PAT }}
repository: switcherapi/switcher-deployment
ref: master

- name: Set Image
uses: stefanprodan/kube-tools@v1
- name: Set up arkade-get
uses: alexellis/arkade-get@master
with:
kubectl: 1.24.0
kustomize: 4.5.4
command: |
cd switcher-api/base
echo RELEASE_TIME=`date` > environment-properties.env
kustomize edit set image trackerforce/switcher-api:latest=trackerforce/switcher-api@${{ needs.docker.outputs.digest }}
git config --global user.email "${{ github.actor }}@users.noreply.github.com"
git config --global user.name "${{ github.actor }}"
git add .
git commit -m "[argocd] switcher-api: ${{ needs.docker.outputs.digest }}"
git push
kubectl: latest
kustomize: latest

- name: Update GitOps repository
run: |
cd switcher-api/base
echo RELEASE_TIME=`date` > environment-properties.env
kustomize edit set image trackerforce/switcher-api:latest=trackerforce/switcher-api@${{ needs.docker.outputs.digest }}
git config --global user.email "${{ github.actor }}@users.noreply.github.com"
git config --global user.name "${{ github.actor }}"
git add .
git commit -m "[argocd] switcher-api: ${{ needs.docker.outputs.digest }}"
git push
20 changes: 11 additions & 9 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Release CI

on:
release:
types: [ created ]
types: [ created, edited ]

jobs:
build-test:
Expand All @@ -11,15 +11,17 @@ jobs:

steps:
- name: Git checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Use Node.js 20.x
uses: actions/setup-node@v3
with:
node-version: 20.x

- name: Start MongoDB
uses: supercharge/mongodb-github-action@1.9.0
uses: supercharge/mongodb-github-action@1.10.0
with:
mongodb-version: 6.0

Expand Down Expand Up @@ -57,28 +59,28 @@ jobs:

steps:
- name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Docker meta
id: meta
uses: docker/metadata-action@v4
uses: docker/metadata-action@v5
with:
images: trackerforce/switcher-api

- name: Set up QEMU
uses: docker/setup-qemu-action@v2
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
uses: docker/setup-buildx-action@v3

- name: Login to DockerHub
uses: docker/login-action@v2
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build and push
uses: docker/build-push-action@v3
uses: docker/build-push-action@v5
with:
context: .
push: true
Expand Down
12 changes: 6 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,23 +41,23 @@
"jsonwebtoken": "^9.0.2",
"moment": "^2.29.4",
"mongodb": "^6.3.0",
"mongoose": "^8.0.2",
"pino": "^8.16.2",
"pino-pretty": "^10.2.3",
"mongoose": "^8.0.3",
"pino": "^8.17.1",
"pino-pretty": "^10.3.0",
"swagger-ui-express": "^5.0.0",
"switcher-client": "^3.2.0",
"validator": "^13.11.0"
},
"devDependencies": {
"@babel/cli": "^7.23.4",
"@babel/core": "^7.23.5",
"@babel/core": "^7.23.6",
"@babel/node": "^7.22.19",
"@babel/preset-env": "^7.23.5",
"@babel/preset-env": "^7.23.6",
"@babel/register": "^7.22.15",
"babel-jest": "^29.7.0",
"babel-polyfill": "^6.26.0",
"env-cmd": "^10.1.0",
"eslint": "^8.55.0",
"eslint": "^8.56.0",
"jest": "^29.7.0",
"jest-sonar-reporter": "^2.0.0",
"node-notifier": "^10.0.1",
Expand Down