-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
local k8s working - as in the services starts without error
- Loading branch information
0 parents
commit 3002694
Showing
240 changed files
with
26,747 additions
and
0 deletions.
There are no files selected for viewing
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 |
---|---|---|
@@ -0,0 +1,29 @@ | ||
* | ||
|
||
!.yarn/cache | ||
!.yarn/patches | ||
!.yarn/plugins | ||
!.yarn/releases | ||
!.yarn/sdks | ||
!.yarn/versions | ||
!.pnp.* | ||
!.yarnrc.yml | ||
!yarn.lock | ||
!k8s | ||
|
||
!package.json | ||
|
||
# workaround for wildcards not working in exclusions (requires docker engine >23 https://docs.docker.com/engine/release-notes/23.0/#bug-fixes-and-enhancements-1) | ||
# find . -name 'package.json' -not -path './.yarn/*' -not -path './packages/*' -maxdepth 3 | sed -e 's/^.\//!/' | ||
!services/auth/package.json | ||
!services/dummy-node/package.json | ||
!services/aztec-listener/package.json | ||
!services/explorer-api/package.json | ||
!services/explorer-ui/package.json | ||
# find . -name 'package.json' -not -path './.yarn/*' -not -path './services/*' -maxdepth 3 | sed -e 's/^.\//!/' | ||
!packages/logger-server | ||
!packages/message-bus | ||
!packages/message-registry | ||
!packages/types | ||
!packages/error-middleware | ||
!packages/auth0-middleware |
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 |
---|---|---|
@@ -0,0 +1,19 @@ | ||
# dependencies | ||
node_modules/ | ||
|
||
# production | ||
build/ | ||
|
||
# scripts | ||
scripts/ | ||
|
||
# test coverage | ||
coverage/ | ||
|
||
# lint config *.js | ||
!.*.js | ||
!.*.mjs | ||
!.*.cjs | ||
|
||
# except for pnp | ||
.pnp.* |
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 |
---|---|---|
@@ -0,0 +1,98 @@ | ||
name: CI/CD Obscura Dev | ||
# TODO | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- develop | ||
types: | ||
- closed | ||
|
||
jobs: | ||
build_and_deploy: | ||
runs-on: | ||
labels: large-runner-gh | ||
|
||
steps: | ||
- name: Retrieve cache | ||
uses: actions/cache@v3 | ||
with: | ||
path: | | ||
~/.skaffold | ||
key: cicd-dev-${{ github.sha }} | ||
restore-keys: | | ||
cicd-dev-${{ github.sha }} | ||
cicd-dev- | ||
- name: Checkout Repository | ||
uses: actions/checkout@v2 | ||
|
||
- name: Create LFS file list | ||
run: git lfs ls-files -l | cut -d' ' -f1 | sort > .lfs-assets-id | ||
|
||
- name: Restore LFS cache | ||
uses: actions/cache@v3 | ||
id: lfs-cache | ||
with: | ||
path: .git/lfs | ||
key: ${{ runner.os }}-lfs-${{ hashFiles('.lfs-assets-id') }}-v1-${{ github.sha }} | ||
restore-keys: | | ||
${{ runner.os }}-lfs-${{ hashFiles('.lfs-assets-id') }}-v1-${{ github.sha }} | ||
${{ runner.os }}-lfs-${{ hashFiles('.lfs-assets-id') }}-v1- | ||
- name: Git LFS Pull | ||
run: git lfs pull | ||
|
||
- name: Install Skaffold | ||
run: | | ||
curl -Lo skaffold https://storage.googleapis.com/skaffold/releases/latest/skaffold-linux-amd64 | ||
sudo install skaffold /usr/local/bin/ | ||
shell: bash | ||
|
||
- name: Configure AWS CLI | ||
run: | | ||
echo $AWS_ACCESS_KEY_ID | ||
echo $AWS_SECRET_ACCESS_KEY | ||
echo $AWS_DEFAULT_REGION | ||
aws eks --region $AWS_DEFAULT_REGION update-kubeconfig --name obscura-dev | ||
env: | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_DEV_ACCESS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_DEV_SECRET_ACCESS_KEY }} | ||
AWS_DEFAULT_REGION: eu-west-3 | ||
|
||
- name: Login to Amazon ECR | ||
run: | | ||
aws ecr get-login-password --region eu-west-3 | docker login --username AWS --password-stdin 097733725684.dkr.ecr.eu-west-3.amazonaws.com | ||
env: | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_DEV_ACCESS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_DEV_SECRET_ACCESS_KEY }} | ||
|
||
- name: Build and push Docker images | ||
run: | | ||
echo $AWS_ACCESS_KEY_ID | ||
echo $AWS_SECRET_ACCESS_KEY | ||
echo $AWS_DEFAULT_REGION | ||
envsubst < k8s/development/kafka-ui/configmap-env.template.yaml > k8s/development/kafka-ui/configmap-env.yaml | ||
skaffold run --filename k8s/development/skaffold.dev.yaml | ||
env: | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_DEV_ACCESS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_DEV_SECRET_ACCESS_KEY }} | ||
AWS_MSK_ALL_SECRET_ACCESS_KEY: ${{ secrets.AWS_MSK_ALL_SECRET_ACCESS_KEY }} | ||
KAFKA_UI_PASSWORD: ${{ secrets.KAFKA_UI_PASSWORD }} | ||
AWS_DEFAULT_REGION: eu-west-3 | ||
shell: bash | ||
|
||
- name: Store cache | ||
uses: actions/cache/save@v3 | ||
if: always() | ||
with: | ||
path: | | ||
~/.skaffold | ||
key: cicd-dev-${{ github.sha }} | ||
|
||
- name: Store LFS cache | ||
uses: actions/cache/save@v3 | ||
if: always() | ||
with: | ||
path: .git/lfs | ||
key: ${{ runner.os }}-lfs-${{ hashFiles('.lfs-assets-id') }}-v1-${{ github.sha }} |
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 |
---|---|---|
@@ -0,0 +1,52 @@ | ||
name: Obscura Merge Check | ||
# TODO | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- master | ||
- develop | ||
merge_group: | ||
types: [checks_requested] | ||
|
||
jobs: | ||
attempt_build: | ||
if: github.event.pull_request.draft == false | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Create LFS file list | ||
run: git lfs ls-files -l | cut -d' ' -f1 | sort > .lfs-assets-id | ||
|
||
- name: Restore LFS cache | ||
uses: actions/cache@v3 | ||
id: lfs-cache | ||
with: | ||
path: .git/lfs | ||
|
||
key: ${{ runner.os }}-lfs-${{ hashFiles('.lfs-assets-id') }}-v1-${{ github.sha }} | ||
restore-keys: | | ||
${{ runner.os }}-lfs-${{ hashFiles('.lfs-assets-id') }}-v1-${{ github.sha }} | ||
${{ runner.os }}-lfs-${{ hashFiles('.lfs-assets-id') }}-v1- | ||
- name: Git LFS Pull | ||
run: git lfs pull | ||
|
||
- name: Use Node.js | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: "20.x" | ||
|
||
- run: yarn install | ||
- run: yarn build | ||
- run: yarn lint | ||
|
||
- name: Store LFS cache | ||
uses: actions/cache/save@v3 | ||
if: always() | ||
with: | ||
path: .git/lfs | ||
key: ${{ runner.os }}-lfs-${{ hashFiles('.lfs-assets-id') }}-v1-${{ github.sha }} |
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 |
---|---|---|
@@ -0,0 +1,53 @@ | ||
name: CI/CD Obscura pre-Dev | ||
# TODO | ||
|
||
on: | ||
pull_request: | ||
types: [labeled] | ||
|
||
jobs: | ||
build_and_deploy: | ||
if: ${{ github.event.label.name == 'dev-frontend' }} | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v2 | ||
with: | ||
lfs: "true" | ||
|
||
- name: Install Skaffold | ||
run: | | ||
curl -Lo skaffold https://storage.googleapis.com/skaffold/releases/latest/skaffold-linux-amd64 | ||
sudo install skaffold /usr/local/bin/ | ||
shell: bash | ||
|
||
- name: Configure AWS CLI | ||
run: | | ||
echo $AWS_ACCESS_KEY_ID | ||
echo $AWS_SECRET_ACCESS_KEY | ||
echo $AWS_DEFAULT_REGION | ||
aws eks --region $AWS_DEFAULT_REGION update-kubeconfig --name obscura-dev | ||
env: | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_DEV_ACCESS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_DEV_SECRET_ACCESS_KEY }} | ||
AWS_DEFAULT_REGION: eu-west-3 | ||
|
||
- name: Login to Amazon ECR | ||
run: | | ||
aws ecr get-login-password --region eu-west-3 | docker login --username AWS --password-stdin 097733725684.dkr.ecr.eu-west-3.amazonaws.com | ||
env: | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_DEV_ACCESS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_DEV_SECRET_ACCESS_KEY }} | ||
|
||
- name: Build and push Docker images | ||
run: | | ||
echo $AWS_ACCESS_KEY_ID | ||
echo $AWS_SECRET_ACCESS_KEY | ||
echo $AWS_DEFAULT_REGION | ||
skaffold run --filename k8s/pre-development/skaffold.pre-dev.yaml | ||
env: | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_DEV_ACCESS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_DEV_SECRET_ACCESS_KEY }} | ||
AWS_DEFAULT_REGION: eu-west-3 | ||
shell: bash |
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 |
---|---|---|
@@ -0,0 +1,56 @@ | ||
name: CI/CD Obscura Prod | ||
# TODO | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- master | ||
types: | ||
- closed | ||
|
||
jobs: | ||
build_and_deploy: | ||
runs-on: | ||
labels: large-runner-gh | ||
|
||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v2 | ||
with: | ||
lfs: "true" | ||
|
||
- name: Install Skaffold | ||
run: | | ||
curl -Lo skaffold https://storage.googleapis.com/skaffold/releases/latest/skaffold-linux-amd64 | ||
sudo install skaffold /usr/local/bin/ | ||
shell: bash | ||
|
||
- name: Configure AWS CLI | ||
run: | | ||
echo $AWS_ACCESS_KEY_ID | ||
echo $AWS_SECRET_ACCESS_KEY | ||
echo $AWS_DEFAULT_REGION | ||
aws eks --region $AWS_DEFAULT_REGION update-kubeconfig --name obscura-prod | ||
env: | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | ||
AWS_DEFAULT_REGION: eu-west-3 | ||
|
||
- name: Login to Amazon ECR | ||
run: | | ||
aws ecr get-login-password --region eu-west-3 | docker login --username AWS --password-stdin 097733725684.dkr.ecr.eu-west-3.amazonaws.com | ||
env: | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | ||
|
||
- name: Build and push Docker images | ||
run: | | ||
echo $AWS_ACCESS_KEY_ID | ||
echo $AWS_SECRET_ACCESS_KEY | ||
echo $AWS_DEFAULT_REGION | ||
skaffold run --filename k8s/production/skaffold.prod.yaml | ||
env: | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | ||
AWS_DEFAULT_REGION: eu-west-3 | ||
shell: bash |
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 |
---|---|---|
@@ -0,0 +1,11 @@ | ||
.idea | ||
build* | ||
node_modules* | ||
.DS_Store | ||
|
||
# file used to set env vars to local cluster | ||
set_local_env.sh | ||
|
||
decodeKeys.js | ||
|
||
ignore/ |
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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/bin/sh | ||
command -v git-lfs >/dev/null 2>&1 || { echo >&2 "\nThis repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting the 'post-checkout' file in the hooks directory (set by 'core.hookspath'; usually '.git/hooks').\n"; exit 2; } | ||
git lfs post-checkout "$@" |
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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/bin/sh | ||
command -v git-lfs >/dev/null 2>&1 || { echo >&2 "\nThis repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting the 'post-commit' file in the hooks directory (set by 'core.hookspath'; usually '.git/hooks').\n"; exit 2; } | ||
git lfs post-commit "$@" |
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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/bin/sh | ||
command -v git-lfs >/dev/null 2>&1 || { echo >&2 "\nThis repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting the 'post-merge' file in the hooks directory (set by 'core.hookspath'; usually '.git/hooks').\n"; exit 2; } | ||
git lfs post-merge "$@" |
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 |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#!/usr/bin/env sh | ||
. "$(dirname -- "$0")/_/husky.sh" | ||
|
||
yarn lint-staged |
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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/bin/sh | ||
command -v git-lfs >/dev/null 2>&1 || { echo >&2 "\nThis repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting the 'pre-push' file in the hooks directory (set by 'core.hookspath'; usually '.git/hooks').\n"; exit 2; } | ||
git lfs pre-push "$@" |
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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
/* eslint-disable import/no-default-export */ | ||
|
||
const config = { | ||
"*.{json,md,yml,yaml,html,css}": ["prettier --write"], | ||
}; | ||
|
||
export default config; |
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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"eslint.nodePath": ".yarn/sdks", | ||
"eslint.packageManager": "yarn", | ||
"tsserver.tsdk": ".yarn/sdks/typescript/lib", | ||
"tsserver.useLocalTsdk": true, | ||
"workspace.workspaceFolderCheckCwd": false | ||
} |
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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"recommendations": [ | ||
"arcanis.vscode-zipfs", | ||
"dbaeumer.vscode-eslint", | ||
"esbenp.prettier-vscode" | ||
] | ||
} |
Oops, something went wrong.