Skip to content

Commit

Permalink
fix: namespaces references
Browse files Browse the repository at this point in the history
  • Loading branch information
Filipe Forattini committed May 10, 2022
1 parent 4c53bd7 commit 871218c
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 33 deletions.
9 changes: 6 additions & 3 deletions .github/workflows/self.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,14 @@ jobs:
# pre-job
- name: Setup | Cloning repository
uses: actions/checkout@v3
with:
fetch-depth: '0'
persist-credentials: false

#job
- name: Run GitLeaks
uses: zricethezav/gitleaks-action@master

- name: Initialize CodeQL
uses: github/codeql-action/init@v2

Expand All @@ -27,9 +33,6 @@ jobs:
# with:
# category: ${{ env.GITHUB_SHA }}

- name: Run GitLeaks
uses: zricethezav/gitleaks-action@master


Release:
runs-on: ubuntu-latest
Expand Down
31 changes: 12 additions & 19 deletions .github/workflows/service-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -100,24 +100,6 @@ jobs:
run: echo $PIPELINE_SETUP


#--------------------------------------------------#
# Base Analysis #
#--------------------------------------------------#
Base-Analysis:
runs-on: ubuntu-latest
needs: Setup

steps:

# pre-job
- name: Setup | Cloning repository
uses: actions/checkout@v3

#job
- name: Run GitLeaks
uses: zricethezav/gitleaks-action@master


#--------------------------------------------------#
# Analysis: Node #
#--------------------------------------------------#
Expand All @@ -134,8 +116,14 @@ jobs:
# pre-job
- name: Setup | Cloning repository
uses: actions/checkout@v3
with:
fetch-depth: '0'
persist-credentials: false

#job
- name: Run GitLeaks
uses: zricethezav/gitleaks-action@master

- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
Expand Down Expand Up @@ -164,8 +152,14 @@ jobs:
# pre-job
- name: Setup | Cloning repository
uses: actions/checkout@v3
with:
fetch-depth: '0'
persist-credentials: false

#job
- name: Run GitLeaks
uses: zricethezav/gitleaks-action@master

- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
Expand Down Expand Up @@ -282,7 +276,6 @@ jobs:
needs:
- Setup
- Tests-Node
- Base-Analysis
- Node-Analysis

outputs:
Expand Down
17 changes: 6 additions & 11 deletions src/scrappers/deploy.class.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,6 @@ module.exports = class Deploy extends Scrapper {
setup () {
const repository = this.context.payload.repository.name
const containerRegistry = this.inputs.containerRegistry

const namespace = [true, 'true'].includes(this.inputs.environmentsAsNamespaces)
? repository
: `${repository}-${this.inputs.environment}`

const podName = repository.includes('-svc-')
? 'svc'
: repository.includes('-app-')
Expand Down Expand Up @@ -44,13 +39,13 @@ module.exports = class Deploy extends Scrapper {
.add('deploy', {
podName,
ecosystem,
namespace,
namespace: repository,
namespaces: {
dev: `${namespace}-dev`,
stg: `${namespace}-stg`,
prd: `${namespace}-prd`,
sbx: `${namespace}-sbx`,
dry: `${namespace}-dry`,
dev: `${repository}-dev`,
stg: `${repository}-stg`,
prd: `${repository}-prd`,
sbx: `${repository}-sbx`,
dry: `${repository}-dry`,
},
deployAsK8s,
hasDevSecrets,
Expand Down

0 comments on commit 871218c

Please sign in to comment.