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
7 changes: 6 additions & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@
**/.vs
**/.vscode
**/.idea
**/.angular
**/dist
**/coverage
**/*.*proj.user
**/*.dbmdl
**/*.jfm
Expand All @@ -22,4 +25,6 @@
**/secrets.dev.yaml
**/values.dev.yaml
LICENSE
README.md
README.md
.github
scripts
5 changes: 5 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Use double underscores for nested ASP.NET Core configuration keys.
ConnectionStrings__DefaultConnection=Host=localhost;Port=5432;Database=notekeeper;Username=notekeeper;Password=change-me
Jwt__Key=replace-with-a-random-secret-of-at-least-32-characters
Jwt__Issuer=NoteKeeper
Jwt__Audience=NoteKeeper
37 changes: 37 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: CI

on:
push:
branches: [main]
pull_request:

permissions:
contents: read

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: 22
cache: npm
cache-dependency-path: ClientApp/package-lock.json

- name: Build Angular client
working-directory: ClientApp
run: |
npm ci
npm run build

- uses: actions/setup-dotnet@v4
with:
dotnet-version: 10.0.x

- name: Build ASP.NET Core API
run: dotnet build NoteBookKeeper.sln --configuration Release

- name: Build production image
run: docker build --tag notekeeper:ci .
29 changes: 24 additions & 5 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,25 @@
################################################################################
# This .gitignore file was automatically created by Microsoft(R) Visual Studio.
################################################################################
# .NET
**/bin/
**/obj/
.vs/
*.user
*.suo

/.vs/NoteBookKeeper/FileContentIndex
/.vs
# Angular / Node
**/node_modules/
**/dist/
**/.angular/
**/coverage/
npm-debug.log*

# Editors and OS
.idea/
.vscode/
.DS_Store
Thumbs.db

# Local configuration and secrets
.env
.env.*
!.env.example
appsettings.Local.json
17 changes: 17 additions & 0 deletions ClientApp/.editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Editor configuration, see https://editorconfig.org
root = true

[*]
charset = utf-8
indent_style = space
indent_size = 2
insert_final_newline = true
trim_trailing_whitespace = true

[*.ts]
quote_type = single
ij_typescript_use_double_quotes = false

[*.md]
max_line_length = off
trim_trailing_whitespace = false
42 changes: 42 additions & 0 deletions ClientApp/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# See https://docs.github.com/get-started/getting-started-with-git/ignoring-files for more about ignoring files.

# Compiled output
/dist
/tmp
/out-tsc
/bazel-out

# Node
/node_modules
npm-debug.log
yarn-error.log

# IDEs and editors
.idea/
.project
.classpath
.c9/
*.launch
.settings/
*.sublime-workspace

# Visual Studio Code
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json
.history/*

# Miscellaneous
/.angular/cache
.sass-cache/
/connect.lock
/coverage
/libpeerconnection.log
testem.log
/typings

# System files
.DS_Store
Thumbs.db
93 changes: 93 additions & 0 deletions ClientApp/angular.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
{
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
"version": 1,
"newProjectRoot": "projects",
"projects": {
"NoteKeeper": {
"projectType": "application",
"schematics": {
"@schematics/angular:component": {
"style": "scss"
}
},
"root": "",
"sourceRoot": "src",
"prefix": "app",
"architect": {
"build": {
"builder": "@angular/build:application",
"options": {
"outputPath": {
"base": "dist/NoteKeeper",
"browser": ""
},
"index": "src/index.html",
"browser": "src/main.ts",
"polyfills": [
"src/polyfills.ts"
],
"tsConfig": "tsconfig.app.json",
"assets": [
{
"glob": "**/*",
"input": "public"
},
{
"glob": "**/*",
"input": "src/assets",
"output": "assets"
}
],
"styles": [
"src/styles.scss"
],
"scripts": [],
"outputHashing": "all",
"budgets": [
{
"type": "initial",
"maximumWarning": "1mb",
"maximumError": "2mb"
}
]
}
},
"serve": {
"builder": "@angular/build:dev-server",
"options": {
"buildTarget": "NoteKeeper:build",
"proxyConfig": "proxy.conf.json"
}
},
"test": {
"builder": "@angular/build:karma",
"options": {
"polyfills": [
"zone.js",
"zone.js/testing"
],
"tsConfig": "tsconfig.spec.json",
"assets": [
{
"glob": "**/*",
"input": "public"
},
{
"glob": "**/*",
"input": "src/assets",
"output": "assets"
}
],
"styles": [
"src/styles.scss"
],
"scripts": []
}
}
}
}
},
"cli": {
"analytics": false
}
}
Loading
Loading