Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Version 2.1 #41

Merged
merged 123 commits into from
Mar 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
123 commits
Select commit Hold shift + click to select a range
5b27ea5
Add canonical domain support (#37)
danieljsummers Jul 9, 2023
5f5927c
First cut of Docker files (#38)
danieljsummers Jul 9, 2023
9dd6ab7
Add Sqlite Docker file
danieljsummers Jul 19, 2023
ab9f2f5
Use PG lib data source singleton
danieljsummers Jul 28, 2023
42d3280
Add redirect rule to data stores (#39)
danieljsummers Jul 29, 2023
3ef4499
Add redirect index page (#39)
danieljsummers Jul 29, 2023
dc6b066
Rule add/edit/move/delete works (#39)
danieljsummers Jul 31, 2023
693a1df
Redirect plain-text rules (#39)
danieljsummers Jul 31, 2023
f43c431
Verify regex rules work correctly (#39)
danieljsummers Aug 1, 2023
79c3044
Add doc link to redirect page (#39)
danieljsummers Aug 1, 2023
b84a0f7
Add chapter data type (#6)
danieljsummers Aug 1, 2023
715e545
Update deps
danieljsummers Dec 13, 2023
ec2d43a
WIP on SQLite/JSON data
danieljsummers Dec 13, 2023
7071d60
WIP on module/member conversion
danieljsummers Dec 15, 2023
5fe2077
WIP on module/member conversion
danieljsummers Dec 16, 2023
d8ce59a
WIP on module/member conversion
danieljsummers Dec 16, 2023
c3d615d
WIP on module/member conversion
danieljsummers Dec 16, 2023
8ec84e8
WIP on module/member conversion
danieljsummers Dec 16, 2023
cb02055
WIP on formatting
danieljsummers Dec 17, 2023
a439430
Update Postgres data implementation
danieljsummers Dec 17, 2023
58b83b8
WIP on SQLite JSON documents
danieljsummers Dec 17, 2023
2062840
WIP on SQLite JSON documents
danieljsummers Dec 18, 2023
e04c8b5
First cut of SQLite JSON doc complete
danieljsummers Dec 18, 2023
d330c97
WIP on SQLite doc library
danieljsummers Dec 19, 2023
bb4252f
WIP on SQLite doc library
danieljsummers Dec 19, 2023
f461b10
First cut of SQLite doc library
danieljsummers Dec 20, 2023
7fb68d5
Rename SQLite helper file
danieljsummers Dec 20, 2023
e8d6379
Migrate Postgres data to new library
danieljsummers Dec 31, 2023
1a50c68
Migrate SQLite data to new library
danieljsummers Dec 31, 2023
dee2222
Register serliazer for SQLite
danieljsummers Dec 31, 2023
b69b6c3
WIP on testing SQLite data store
danieljsummers Jan 4, 2024
5a3d9f0
Rework migration; add PG 2.1 changes
danieljsummers Jan 4, 2024
3226f88
Implement /data and /themes directories (#38)
danieljsummers Jan 5, 2024
75e13a5
Add chapters waypoint flag (#6)
danieljsummers Jan 5, 2024
2c052c1
Add test project
danieljsummers Jan 6, 2024
cac1174
Add CommentStatus and ExplicitRating tests
danieljsummers Jan 6, 2024
5c08049
Finish SupportTypes tests
danieljsummers Jan 7, 2024
5126e20
Add tests for DataTypes
danieljsummers Jan 7, 2024
6622529
Add some view model tests
danieljsummers Jan 8, 2024
dc80388
Add more view model tests
danieljsummers Jan 9, 2024
8ec7610
Tweak domain tests
danieljsummers Jan 9, 2024
ba42f84
Add DisplayUser tests
danieljsummers Jan 10, 2024
10affa2
Add EditCategoryModel tests
danieljsummers Jan 11, 2024
29cbf48
Split tests into separate files
danieljsummers Jan 11, 2024
29167ec
Add podcast/user edit model tests
danieljsummers Jan 11, 2024
12c46c8
Add edit page model tests
danieljsummers Jan 13, 2024
888f56e
WIP on edit post model tests
danieljsummers Jan 14, 2024
cb94222
Finish edit post model tests
danieljsummers Jan 15, 2024
cbe391f
Add edit redirect tests
danieljsummers Jan 16, 2024
9da9a94
Add tests through mng rev
danieljsummers Jan 19, 2024
da5918b
Update admin/default templates
danieljsummers Jan 20, 2024
d50056c
Finish view model tests
danieljsummers Jan 20, 2024
a0ab99f
Add unquoted relative URL support
danieljsummers Jan 20, 2024
5ce84e1
Fix SQLite page list query
danieljsummers Jan 20, 2024
d1a9606
Tweak admin theme changes
danieljsummers Jan 20, 2024
cfb3c3a
Add JSON converter tests
danieljsummers Jan 21, 2024
ffe6713
Add converter / utils tests
danieljsummers Jan 21, 2024
1345074
Add framework for SQLite data tests
danieljsummers Jan 21, 2024
3835ed9
Rearrange test files
danieljsummers Jan 21, 2024
182b33a
Add Category tests, implement for SQLite
danieljsummers Jan 22, 2024
13994a2
Convert to rc2 of doc lib
danieljsummers Jan 24, 2024
19777c7
Add Postgres Category tests
danieljsummers Jan 25, 2024
d09a5e1
Add data test for Page.Add
danieljsummers Jan 26, 2024
f701fc9
Add data test for Page.All
danieljsummers Jan 26, 2024
0e8044b
Add RethinkDB tests
danieljsummers Jan 27, 2024
3f269ed
Add Page Find[Full]ById tests
danieljsummers Jan 28, 2024
c319ff1
Add tests for pages via permalinks
danieljsummers Jan 28, 2024
f60139d
Add more page tests
danieljsummers Jan 29, 2024
0a53e27
Add page-of-page and update tests
danieljsummers Jan 29, 2024
990b72b
Finish page data tests
danieljsummers Jan 30, 2024
78c1c5e
Add framework for post tests
danieljsummers Jan 31, 2024
24d49e2
Add tests through post curr permalink
danieljsummers Jan 31, 2024
84460b4
Add post FindFull* tests
danieljsummers Feb 2, 2024
05d49e6
Finish post data tests
danieljsummers Feb 3, 2024
8183da7
Add tag mapping tests
danieljsummers Feb 3, 2024
b1a0c20
Add theme tests
danieljsummers Feb 3, 2024
ff05bc8
Add theme asset tests
danieljsummers Feb 3, 2024
34315a1
Add upload tests
danieljsummers Feb 3, 2024
ac9df44
Add user add/find-by-[email|id] tests
danieljsummers Feb 3, 2024
16f7396
Finish user tests
danieljsummers Feb 4, 2024
f25426d
Add web log tests
danieljsummers Feb 4, 2024
d378f69
Add chapter source fields (#6)
danieljsummers Feb 6, 2024
90bca34
WIP on chapter list page (#6)
danieljsummers Feb 8, 2024
12b23ea
WIP on chapter edit page (#6)
danieljsummers Feb 9, 2024
1463247
WIP on chapter edit form (#6)
danieljsummers Feb 11, 2024
d3c89da
WIP on chapter edit form (#6)
danieljsummers Feb 11, 2024
6a5285c
WIP on saving chapters (#6)
danieljsummers Mar 4, 2024
43a700e
WIP on chapter flow (#6)
danieljsummers Mar 10, 2024
641a749
Complete chapter edit page (#6)
danieljsummers Mar 10, 2024
8103957
WIP on ?chapters handler for posts (#6)
danieljsummers Mar 11, 2024
5b8a632
Complete main chapter functionality (#6)
danieljsummers Mar 11, 2024
90e6f78
Migrate post list template
danieljsummers Mar 11, 2024
5f114c7
Move redirect/tag map templates to GVE
danieljsummers Mar 12, 2024
b99cd5b
Migrate more templates to GVE
danieljsummers Mar 13, 2024
e9bd3b2
Migrate web log settings page to GVE
danieljsummers Mar 13, 2024
cac7b1d
Migrate page list template to GVE
danieljsummers Mar 14, 2024
b85cae2
Tweak to chapter edit template
danieljsummers Mar 15, 2024
91046c6
Migrate custom feed page to GVE
danieljsummers Mar 15, 2024
3998399
Migrate several templates to GVE
danieljsummers Mar 15, 2024
ddab491
First cut of common edit model
danieljsummers Mar 15, 2024
ec04fea
Migrate page edit to GVE
danieljsummers Mar 16, 2024
a448339
Migrate post edit to GVE
danieljsummers Mar 16, 2024
6459931
Eliminate final admin theme Liquid resources
danieljsummers Mar 16, 2024
54e46fd
Remove unneeded types
danieljsummers Mar 16, 2024
4301788
Bug fixes with new admin forms
danieljsummers Mar 16, 2024
31d49d4
Fix "add category" button (#40)
danieljsummers Mar 17, 2024
f181f83
Misc admin theme tweaks
danieljsummers Mar 17, 2024
ac332a6
Fix Docker builds (#38)
danieljsummers Mar 20, 2024
dce80fd
Fix theme zipping in Docker (#38)
danieljsummers Mar 23, 2024
c20628b
Update deps before release
danieljsummers Mar 23, 2024
895b2a7
Update build files
danieljsummers Mar 23, 2024
2fe104f
Add GitHub Actions YAML
danieljsummers Mar 23, 2024
add6a80
Add Rethink URI, run tests after cd
danieljsummers Mar 23, 2024
5c7e897
Enable .NET 7
danieljsummers Mar 23, 2024
eaa1824
Enable .NET 8
danieljsummers Mar 23, 2024
ad49c95
Add release packaging
danieljsummers Mar 23, 2024
5ba05bd
Add CI flag to build
danieljsummers Mar 23, 2024
aa2707d
Use matrix for publish job
danieljsummers Mar 24, 2024
c9a097a
Fix indentation
danieljsummers Mar 24, 2024
d28b18a
Remove name from artifact upload
danieljsummers Mar 24, 2024
5fc3d11
Include matrix vars in artifact name
danieljsummers Mar 24, 2024
2439d01
Fix indents in CI YAML
danieljsummers Mar 24, 2024
d8024ac
Add chapter ref to feed (#6)
danieljsummers Mar 26, 2024
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
99 changes: 99 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,99 @@
name: Continuous Integration
on:
push:
branches:
- main
pull_request:
branches:
- main
workflow_dispatch:
env:
MWL_TEST_RETHINK_URI: rethinkdb://localhost/mwl_test
jobs:
build_and_test:
name: Build / Test
runs-on: ubuntu-latest

strategy:
matrix:
dotnet-version:
- "6.0"
- "7.0"
- "8.0"

services:
postgres:
image: postgres:latest
env:
POSTGRES_PASSWORD: postgres
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 5432:5432
rethink:
image: rethinkdb:latest
ports:
- 28015:28015

steps:
- name: Check Out Code
uses: actions/checkout@v4
- name: Setup .NET Core SDK
uses: actions/[email protected]
with:
dotnet-version: 8.x
- name: Restore dependencies
run: dotnet restore src/MyWebLog.sln
- name: Build (${{ matrix.dotnet-version }})
run: dotnet build src/MyWebLog.sln -f net${{ matrix.dotnet-version }}
- name: Test (${{ matrix.dotnet-version }})
run: cd src/MyWebLog.Tests; dotnet run -f net${{ matrix.dotnet-version }}

publish:
name: Publish Packages
runs-on: ubuntu-latest
needs: build_and_test

strategy:
matrix:
ver:
- "net6.0"
- "net7.0"
- "net8.0"
os:
- "linux-x64"
- "win-x64"
include:
- os: "linux-x64"
bz2: true
- os: "win-x64"
zip: true
steps:
- name: Check Out Code
uses: actions/checkout@v4
- name: Setup .NET Core SDK
uses: actions/[email protected]
with:
dotnet-version: 8.x
- name: Publish (Release)
run: dotnet publish -c Release -f ${{ matrix.ver }} -r ${{ matrix.os }} src/MyWebLog/MyWebLog.fsproj
- name: Zip Admin Theme
run: cd src/admin-theme; zip -r ../MyWebLog/bin/Release/${{ matrix.ver }}/${{ matrix.os }}/publish/admin-theme.zip *; cd ../..
- name: Zip Default Theme
run: cd src/default-theme; zip -r ../MyWebLog/bin/Release/${{ matrix.ver }}/${{ matrix.os }}/publish/default-theme.zip *; cd ../..
- if: ${{ matrix.bz2 }}
name: Create .tar.bz2 Archive
run: tar cfj myWebLog-${{ matrix.ver }}-${{ matrix.os }}.tar.bz2 -C src/MyWebLog/bin/Release/${{ matrix.ver }}/${{ matrix.os }}/publish .
- if: ${{ matrix.zip }}
name: Create .zip Archive
run: cd src/MyWebLog/bin/Release/${{ matrix.ver }}/${{ matrix.os }}/publish; zip -r myWebLog-${{ matrix.ver }}-${{ matrix.os }}.zip *; cp myWeb*.zip ../../../../../../..; cd ../../../../../../..
- name: Upload Artifacts
uses: actions/upload-artifact@v4
with:
name: package-${{ matrix.ver }}-${{ matrix.os }}
path: |
*x64.zip
*.bz2
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,8 @@ src/MyWebLog/wwwroot/img/daniel-j-summers
src/MyWebLog/wwwroot/img/bit-badger

.ionide
.vscode
src/MyWebLog/appsettings.Production.json

# SQLite database files
src/MyWebLog/*.db*
src/MyWebLog/data/*.db*
2 changes: 1 addition & 1 deletion build.fs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ let zipTheme (name : string) (_ : TargetParameter) =
|> Zip.zipSpec $"{releasePath}/{name}-theme.zip"

/// Frameworks supported by this build
let frameworks = [ "net6.0"; "net7.0" ]
let frameworks = [ "net6.0"; "net7.0"; "net8.0" ]

/// Publish the project for the given runtime ID
let publishFor rid (_ : TargetParameter) =
Expand Down
12 changes: 6 additions & 6 deletions build.fsproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,19 @@

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net7.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>
</PropertyGroup>

<ItemGroup>
<Compile Include="build.fs" />
</ItemGroup>

<ItemGroup>
<PackageReference Include="Fake.Core.Target" Version="5.23.1" />
<PackageReference Include="Fake.DotNet.Cli" Version="5.23.1" />
<PackageReference Include="Fake.IO.FileSystem" Version="5.23.1" />
<PackageReference Include="Fake.IO.Zip" Version="5.23.1" />
<PackageReference Include="MSBuild.StructuredLogger" Version="2.1.768" />
<PackageReference Include="Fake.Core.Target" Version="6.0.0" />
<PackageReference Include="Fake.DotNet.Cli" Version="6.0.0" />
<PackageReference Include="Fake.IO.FileSystem" Version="6.0.0" />
<PackageReference Include="Fake.IO.Zip" Version="6.0.0" />
<PackageReference Include="MSBuild.StructuredLogger" Version="2.2.206" />
</ItemGroup>

</Project>
4 changes: 4 additions & 0 deletions src/.dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
**/bin
**/obj
**/*.db
**/appsettings.*.json
8 changes: 4 additions & 4 deletions src/Directory.Build.props
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<Project>
<PropertyGroup>
<TargetFrameworks>net6.0;net7.0</TargetFrameworks>
<TargetFrameworks>net6.0;net7.0;net8.0</TargetFrameworks>
<DebugType>embedded</DebugType>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<FileVersion>2.0.0.0</FileVersion>
<Version>2.0.0</Version>
<AssemblyVersion>2.1.0.0</AssemblyVersion>
<FileVersion>2.1.0.0</FileVersion>
<Version>2.1.0</Version>
</PropertyGroup>
</Project>
33 changes: 33 additions & 0 deletions src/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
FROM mcr.microsoft.com/dotnet/sdk:8.0-alpine AS build
WORKDIR /mwl
COPY ./MyWebLog.sln ./
COPY ./Directory.Build.props ./
COPY ./MyWebLog/MyWebLog.fsproj ./MyWebLog/
COPY ./MyWebLog.Data/MyWebLog.Data.fsproj ./MyWebLog.Data/
COPY ./MyWebLog.Domain/MyWebLog.Domain.fsproj ./MyWebLog.Domain/
COPY ./MyWebLog.Tests/MyWebLog.Tests.fsproj ./MyWebLog.Tests/
RUN dotnet restore

COPY . ./
WORKDIR /mwl/MyWebLog
RUN dotnet publish -f net8.0 -c Release -r linux-x64 --no-self-contained -p:PublishSingleFile=false

FROM alpine AS theme
RUN apk add --no-cache zip
WORKDIR /themes/default-theme
COPY ./default-theme ./
RUN zip -r ../default-theme.zip ./*
WORKDIR /themes/admin-theme
COPY ./admin-theme ./
RUN zip -r ../admin-theme.zip ./*

FROM mcr.microsoft.com/dotnet/aspnet:8.0-alpine as final
WORKDIR /app
RUN apk add --no-cache icu-libs
ENV DOTNET_SYSTEM_GLOBALIZATION_INVARIANT=false
COPY --from=build /mwl/MyWebLog/bin/Release/net8.0/linux-x64/publish/ ./
COPY --from=theme /themes/*.zip /app/
RUN mkdir themes

EXPOSE 80
CMD [ "dotnet", "/app/MyWebLog.dll" ]
Loading