-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat: add monitor and update * docs: update readme * feat: add image build and tag
- Loading branch information
Showing
42 changed files
with
2,923 additions
and
1,975 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,19 @@ | ||
# git things | ||
.git | ||
.github | ||
|
||
# Configs | ||
.editorconfig | ||
|
||
# No docs | ||
*.md | ||
|
||
/coverage | ||
/e2e | ||
/dist | ||
/node_modules | ||
/setenv* | ||
/setenv/* | ||
/config* | ||
/config/* | ||
/env.hcl |
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,7 @@ on: | |
- cron: "0 23 * * *" | ||
push: | ||
branches: | ||
-main | ||
- main | ||
workflow_dispatch: | ||
|
||
jobs: | ||
|
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 |
---|---|---|
|
@@ -5,7 +5,7 @@ on: | |
- cron: "0 23 * * *" | ||
push: | ||
branches: | ||
-main | ||
- main | ||
workflow_dispatch: | ||
|
||
jobs: | ||
|
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 |
---|---|---|
|
@@ -5,7 +5,7 @@ on: | |
- cron: "0 23 * * *" | ||
push: | ||
branches: | ||
-main | ||
- main | ||
workflow_dispatch: | ||
|
||
jobs: | ||
|
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,71 @@ | ||
name: Tag Main | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
tags: | ||
- 'v*' | ||
paths-ignore: | ||
- ".**" | ||
- "**.md" | ||
- "**.yml" | ||
- "**.yaml" | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
env: | ||
REGISTRY: ghcr.io | ||
|
||
jobs: | ||
# # Uncomment to view GitHub context object | ||
# view-context: | ||
# # https://docs.github.com/en/actions/learn-github-actions/contexts | ||
# name: View GitHub Context | ||
# runs-on: ubuntu-latest | ||
# steps: | ||
# - name: Echo GitHub context | ||
# uses: satackey/[email protected] | ||
# with: | ||
# script: | | ||
# const github = require('@actions/github'); | ||
# console.log(JSON.stringify(github, null, 2)); | ||
|
||
build-image: | ||
name: Build Image | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: read | ||
packages: write | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Docker meta | ||
id: meta | ||
uses: docker/metadata-action@v5 | ||
with: | ||
images: ${{ env.REGISTRY }}/${{ github.repository }} | ||
|
||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
|
||
- name: Log in to the Container registry | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ${{ env.REGISTRY }} | ||
username: ${{ github.actor }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Build and push Backend Docker image | ||
uses: docker/build-push-action@v5 | ||
with: | ||
context: . | ||
push: true | ||
tags: ${{ steps.meta.outputs.tags }} | ||
labels: ${{ steps.meta.outputs.labels }} | ||
cache-from: type=gha | ||
build-args: | | ||
REPO_LOCATION= |
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 |
---|---|---|
|
@@ -9,6 +9,6 @@ npm-debug.log | |
VAULT_ROOT_TOKEN | ||
VAULT_UNSEAL_KEY | ||
/setenv* | ||
!/setenv.sh.tmp | ||
!/setenv-local.sh | ||
.DS_STORE | ||
/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,21 @@ | ||
FROM node:20-alpine | ||
ARG ENVCONSUL_VERSION=0.13.2 | ||
|
||
ADD https://releases.hashicorp.com/envconsul/${ENVCONSUL_VERSION}/envconsul_${ENVCONSUL_VERSION}_linux_amd64.zip /tmp/envconsul.zip | ||
RUN unzip /tmp/envconsul.zip && \ | ||
rm /tmp/envconsul.zip && \ | ||
mv envconsul /usr/local/bin/ | ||
|
||
# Create app directory | ||
WORKDIR /app | ||
COPY . ./ | ||
|
||
RUN npm ci && \ | ||
npm run build | ||
|
||
VOLUME /app/config | ||
|
||
ENV NODE_ENV production | ||
ENV AUTH_SYNC_CONFIG_PATH /app/config | ||
|
||
ENTRYPOINT ["envconsul", "-config", "/app/config/env.hcl", "./bin/run", "monitor"] |
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,27 @@ | ||
# Auth Sync Tool - Development | ||
|
||
Back: [README.md](README.md) | ||
|
||
This document is aimed at developers looking to setup the Auth Sync Tool to run or make modifications to it. | ||
|
||
See: [Oclif CLI](https://oclif.io) | ||
|
||
## Requirements | ||
|
||
* Podman | ||
* Node.js | ||
|
||
## Supported NPM commands | ||
|
||
* npm run lint - lint source code | ||
* npm run test - Run unit tests | ||
* npm run prepack - Build and update CLI README | ||
|
||
## Build with Podman | ||
|
||
``` | ||
podman build . -t auth-sync-app | ||
``` | ||
|
||
The built container can be substituted for the released container. | ||
|
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.