From ff976fc83e56eadb464411386929f92bd287f1f0 Mon Sep 17 00:00:00 2001 From: Frank Breedijk Date: Wed, 1 Nov 2023 20:05:53 +0100 Subject: [PATCH 01/10] Trying out DecapCMS --- .github/workflows/build_pages_native.yml | 5 +++++ admin/config.yml | 9 +++++++++ admin/index.html | 12 ++++++++++++ 3 files changed, 26 insertions(+) create mode 100644 admin/config.yml create mode 100644 admin/index.html diff --git a/.github/workflows/build_pages_native.yml b/.github/workflows/build_pages_native.yml index f77e8c5..6c10f3a 100644 --- a/.github/workflows/build_pages_native.yml +++ b/.github/workflows/build_pages_native.yml @@ -67,4 +67,9 @@ jobs: channel: communications status: FAILED color: danger + - name: Deploy GiutHub pages + uses: JamesIves/github-pages-deploy-action@v4 +# if: ${{ github.ref == 'refs/heads/main' }} # && ( success() || failure() ) # Remove the && clause when a HTML check is flawless + with: + folder: admin # The folder the action should deploy. diff --git a/admin/config.yml b/admin/config.yml new file mode 100644 index 0000000..b7915a7 --- /dev/null +++ b/admin/config.yml @@ -0,0 +1,9 @@ +publish_mode: editorial_workflow +site_url: https://www.divd.nl +backend: + name: github + repo: DIVD-NL/web-www + branch: main + +media_folder: /images +public_folder: /uploads diff --git a/admin/index.html b/admin/index.html new file mode 100644 index 0000000..298014a --- /dev/null +++ b/admin/index.html @@ -0,0 +1,12 @@ + + + + + + Content Manager + + + + + + From 57837619665c9968a4e22e18b571de78e32a0880 Mon Sep 17 00:00:00 2001 From: Frank Breedijk Date: Wed, 1 Nov 2023 20:36:42 +0100 Subject: [PATCH 02/10] Exclude admin --- _config.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/_config.yml b/_config.yml index 1514b23..f4b88f0 100644 --- a/_config.yml +++ b/_config.yml @@ -76,3 +76,4 @@ exclude: - "_config_livereload.yml" - "csirt.divd.nl" - "vendor" + - "admin" From 36fe0e89e3676c003c20d222c6ba019fbb15ca3b Mon Sep 17 00:00:00 2001 From: Frank Breedijk Date: Wed, 1 Nov 2023 21:22:00 +0100 Subject: [PATCH 03/10] updated config --- admin/config.yml | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/admin/config.yml b/admin/config.yml index b7915a7..9c535a8 100644 --- a/admin/config.yml +++ b/admin/config.yml @@ -7,3 +7,18 @@ backend: media_folder: /images public_folder: /uploads + +collections: # A list of collections the CMS should be able to edit + - name: "post" # Used in routes, ie.: /admin/collections/:slug/edit + label: "Post" # Used in the UI, ie.: "New Post" + folder: "_posts" # The path to the folder where the documents are stored + sort: "date:desc" # Default is title:asc + create: true # Allow users to create new documents in this collection +# slug: "{{year}}-{{month}}-{{day}}-{{slug}}" + fields: # The fields each document in this collection have + - {label: "Layout", name: "layout", widget: "hidden", default: "post"} + - {label: "Title", name: "title", widget: "string", tagname: "h1"} + - {label: "Body", name: "body", widget: "markdown"} + - {label: "Categories", name: "categories", widget: "string", required: false} + meta: # Meta data fields. Just like fields, but without any preview element + - {label: "Publish Date", name: "date", widget: "datetime", format: "YYYY-MM-DD hh:mm:ss"} From 1773075d2c37027aa55f6d403b681a8c1ae45e93 Mon Sep 17 00:00:00 2001 From: Frank Breedijk Date: Wed, 1 Nov 2023 21:31:51 +0100 Subject: [PATCH 04/10] updated config --- admin/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/admin/config.yml b/admin/config.yml index 9c535a8..6a791bc 100644 --- a/admin/config.yml +++ b/admin/config.yml @@ -20,5 +20,5 @@ collections: # A list of collections the CMS should be able to edit - {label: "Title", name: "title", widget: "string", tagname: "h1"} - {label: "Body", name: "body", widget: "markdown"} - {label: "Categories", name: "categories", widget: "string", required: false} - meta: # Meta data fields. Just like fields, but without any preview element - - {label: "Publish Date", name: "date", widget: "datetime", format: "YYYY-MM-DD hh:mm:ss"} +# meta: # Meta data fields. Just like fields, but without any preview element +# - {label: "Publish Date", name: "date", widget: "datetime", format: "YYYY-MM-DD hh:mm:ss"} From a43e3adb67ab39579a17b31c79e4124043dfb7d7 Mon Sep 17 00:00:00 2001 From: Frank Breedijk Date: Wed, 1 Nov 2023 21:35:13 +0100 Subject: [PATCH 05/10] updated config --- admin/config.yml | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/admin/config.yml b/admin/config.yml index 6a791bc..ec37784 100644 --- a/admin/config.yml +++ b/admin/config.yml @@ -9,16 +9,3 @@ media_folder: /images public_folder: /uploads collections: # A list of collections the CMS should be able to edit - - name: "post" # Used in routes, ie.: /admin/collections/:slug/edit - label: "Post" # Used in the UI, ie.: "New Post" - folder: "_posts" # The path to the folder where the documents are stored - sort: "date:desc" # Default is title:asc - create: true # Allow users to create new documents in this collection -# slug: "{{year}}-{{month}}-{{day}}-{{slug}}" - fields: # The fields each document in this collection have - - {label: "Layout", name: "layout", widget: "hidden", default: "post"} - - {label: "Title", name: "title", widget: "string", tagname: "h1"} - - {label: "Body", name: "body", widget: "markdown"} - - {label: "Categories", name: "categories", widget: "string", required: false} -# meta: # Meta data fields. Just like fields, but without any preview element -# - {label: "Publish Date", name: "date", widget: "datetime", format: "YYYY-MM-DD hh:mm:ss"} From 0a94d29afa28f5de2e826a67b0ec627b698547cb Mon Sep 17 00:00:00 2001 From: Frank Breedijk Date: Wed, 1 Nov 2023 21:51:55 +0100 Subject: [PATCH 06/10] updated config --- admin/config.yml | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/admin/config.yml b/admin/config.yml index ec37784..8bac1e3 100644 --- a/admin/config.yml +++ b/admin/config.yml @@ -9,3 +9,32 @@ media_folder: /images public_folder: /uploads collections: # A list of collections the CMS should be able to edit + - name: "post" # Used in routes, ie.: /admin/collections/:slug/edit + label: "Post" # Used in the UI, ie.: "New Post" + folder: "_posts" # The path to the folder where the documents are stored + sort: "date:desc" # Default is title:asc + create: true # Allow users to create new documents in this collection + slug: "{{year}}-{{month}}-{{day}}-{{slug}}" + fields: # The fields each document in this collection have + - {label: "Layout", name: "layout", widget: "hidden", default: "post"} + - {label: "Title", name: "title", widget: "string", tagname: "h1"} + - {label: "Body", name: "body", widget: "markdown"} + - {label: "Categories", name: "categories", widget: "string", required: false} + #meta: # Meta data fields. Just like fields, but without any preview element + # - {label: "Publish Date", name: "date", widget: "datetime", format: "YYYY-MM-DD hh:mm:ss"} + # PAGE: Home ##################################################### + - name: "_donate" + label: "Donate Page" + slug: "_donate" + i18n: true + folder: "donate" + create: false + fields: + - { + label: "Title", + name: "title", + widget: "string", + default: "home", + i18n: true, + } + - {label: "Body", name: "body", widget: "html"} From 0eda5f6dd63af058d05eed53980a67f0601a79e1 Mon Sep 17 00:00:00 2001 From: Frank Breedijk Date: Thu, 2 Nov 2023 08:45:51 +0100 Subject: [PATCH 07/10] updated config --- admin/config.yml | 40 ++++++++++++++++++++++++---------------- 1 file changed, 24 insertions(+), 16 deletions(-) diff --git a/admin/config.yml b/admin/config.yml index 8bac1e3..f160ca7 100644 --- a/admin/config.yml +++ b/admin/config.yml @@ -9,6 +9,30 @@ media_folder: /images public_folder: /uploads collections: # A list of collections the CMS should be able to edit + - label: "Pages" + name: "pages" + files: + - label: "Home" + name: "home" + file: "index.md" + fields: + - {label: Title, name: title, widget: string } + - {label: Description, name: description, widget: string } + - {label: Body, name: body, widget: markdown } + - label: "Join" + name: "join" + file: "join.md" + fields: + - {label: Title, name: title, widget: string } + - {label: Description, name: description, widget: string } + - {label: Body, name: body, widget: markdown } + - label: "Partners" + name: "partners" + file: "partners.md" + fields: + - {label: Title, name: title, widget: string } + - {label: Description, name: description, widget: string } + - {label: Body, name: body, widget: markdown } - name: "post" # Used in routes, ie.: /admin/collections/:slug/edit label: "Post" # Used in the UI, ie.: "New Post" folder: "_posts" # The path to the folder where the documents are stored @@ -22,19 +46,3 @@ collections: # A list of collections the CMS should be able to edit - {label: "Categories", name: "categories", widget: "string", required: false} #meta: # Meta data fields. Just like fields, but without any preview element # - {label: "Publish Date", name: "date", widget: "datetime", format: "YYYY-MM-DD hh:mm:ss"} - # PAGE: Home ##################################################### - - name: "_donate" - label: "Donate Page" - slug: "_donate" - i18n: true - folder: "donate" - create: false - fields: - - { - label: "Title", - name: "title", - widget: "string", - default: "home", - i18n: true, - } - - {label: "Body", name: "body", widget: "html"} From 67b1a1830a1bc3f0c70e8110c2f9c45efb99534b Mon Sep 17 00:00:00 2001 From: Frank Breedijk Date: Thu, 2 Nov 2023 09:24:40 +0100 Subject: [PATCH 08/10] Cleaned up forrestry config, updated decap config, clean up old team page and ignored SECURITY.md (because it is a GitHub specific file) --- .forestry/front_matter/templates/post.yml | 23 ------ .forestry/front_matter/templates/report.yml | 68 ------------------ .../front_matter/templates/team-member.yml | 66 ----------------- .forestry/settings.yml | 43 ----------- _config.yml | 1 + admin/config.yml | 63 ++++++++++++++-- team_old.md | 71 ------------------- 7 files changed, 60 insertions(+), 275 deletions(-) delete mode 100644 .forestry/front_matter/templates/post.yml delete mode 100644 .forestry/front_matter/templates/report.yml delete mode 100644 .forestry/front_matter/templates/team-member.yml delete mode 100644 .forestry/settings.yml delete mode 100644 team_old.md diff --git a/.forestry/front_matter/templates/post.yml b/.forestry/front_matter/templates/post.yml deleted file mode 100644 index acc08a6..0000000 --- a/.forestry/front_matter/templates/post.yml +++ /dev/null @@ -1,23 +0,0 @@ ---- -label: Post -hide_body: false -fields: -- type: text - name: layout - label: layout - default: news - hidden: true -- type: text - name: title - label: title -- type: text - name: author - label: author -- type: textarea - name: excerpt - label: excerpt -pages: -- Privacy/privacy-policy.md -- _posts/2022-12-26-dissecting-fortigate-images-for-fun-and-no-profit.md -- _posts/2023-02-24-reactie-divd-op-betrokkenheid-van-divd-vrijwilliger-bij-grote-datadiefstal-zaak.md -- _posts/2023-04-20-extern-onderzoek-naar-mogelijk-misbruik-middelen-divd.md diff --git a/.forestry/front_matter/templates/report.yml b/.forestry/front_matter/templates/report.yml deleted file mode 100644 index 4f6b2c5..0000000 --- a/.forestry/front_matter/templates/report.yml +++ /dev/null @@ -1,68 +0,0 @@ ---- -label: Report -hide_body: false -fields: -- type: text - name: layout - label: layout - default: report -- type: text - name: title - label: Title - description: Just a short tile, the words 'Report DIVD-xxxx-xxxxx -' will be added - autoatically - config: - required: true - min: 1 -- type: text - name: case - label: Case - config: - required: true - min: 15 - max: 15 -- name: has_casefile - type: boolean - label: Has casefile - description: Toggle this to off if the case doesn't have a casefile. - default: true -- name: date - type: datetime - label: Date - description: '' - config: - required: true - date_format: DD-MM-YYYY - time_format: - display_utc: false - export_format: YYYY-MM-DD - default: now -- type: text - name: author - label: Author - config: - required: true -- type: text - name: lead - label: Case lead - config: - required: true -- type: list - name: csirt - label: Csirt -- type: list - name: researchers - label: Researchers -- type: text - name: excerpt - label: Excerpt -pages: -- _reports/confluence.md -- _reports/gitlab-graphql-api-user-enumeration.md -- _reports/grafana.md -- _reports/greynoise-s-ukraine-only-list.md -- _reports/n-able.md -- _reports/odd-microsoft-certificate.md -- _reports/smartermail.md -- _reports/solarman.md -- _reports/winrs-and-exchange-backdoor.md diff --git a/.forestry/front_matter/templates/team-member.yml b/.forestry/front_matter/templates/team-member.yml deleted file mode 100644 index 9b0ef4e..0000000 --- a/.forestry/front_matter/templates/team-member.yml +++ /dev/null @@ -1,66 +0,0 @@ ---- -label: Team member -hide_body: true -fields: -- type: text - name: name - label: name -- type: text - name: role - label: role - config: - required: true - min: 5 -- name: dept - type: select - default: '' - config: - required: false - options: - - Academy - - CSIRT - - Institute - - IT services - - Research - source: - type: simple - section: - file: - path: - label: Department -- type: text - name: layout - label: layout - default: team - config: - required: true - hidden: true -- type: number - name: appearance - label: Order of appearance - config: - required: true -- type: boolean - name: board - label: board member? - description: Is this member a board member? -- name: supervision - type: boolean - label: Supervisory board? - description: Is this a member of the supervisory board? -- type: boolean - name: active - label: Is active - default: true -- type: text - name: twitter - label: Twitter handle - description: Only the handle is needed e.g.
https://twitter.com/seccubus → seccubus -- type: text - name: linkedin - label: LinkedIn profile name - description: E.g. https://www.linkedin.com/in/seccubus/ → seccubus -- type: text - name: wikipedia - label: Wikipedia url - description: Full wikipedia url diff --git a/.forestry/settings.yml b/.forestry/settings.yml deleted file mode 100644 index e6ad404..0000000 --- a/.forestry/settings.yml +++ /dev/null @@ -1,43 +0,0 @@ ---- -new_page_extension: md -auto_deploy: false -admin_path: '' -webhook_url: -sections: -- type: directory - path: _reports - label: Reports - create: documents - match: "**/*.md" - templates: - - report -- type: jekyll-pages - label: Pages - create: all -- type: jekyll-posts - label: Posts - create: all - templates: - - post -- type: directory - path: _team - label: Team - create: all - match: "**/*" - templates: - - team-member -upload_dir: uploads -public_path: "/uploads" -front_matter_path: '' -use_front_matter_path: false -file_template: ":filename:" -build: - preview_env: - - JEKYLL_ENV=staging - preview_output_directory: _site - install_dependencies_command: bundle install --path vendor/bundle - preview_docker_image: forestryio/ruby:2.6 - mount_path: "/srv" - working_dir: "/srv" - instant_preview_command: "./update.sh && bundle exec jekyll serve --drafts --unpublished - --future --port 8080 --host 0.0.0.0 -d _site" diff --git a/_config.yml b/_config.yml index f4b88f0..98dd963 100644 --- a/_config.yml +++ b/_config.yml @@ -77,3 +77,4 @@ exclude: - "csirt.divd.nl" - "vendor" - "admin" + - "SECURITY.md" diff --git a/admin/config.yml b/admin/config.yml index f160ca7..70b2d05 100644 --- a/admin/config.yml +++ b/admin/config.yml @@ -18,6 +18,7 @@ collections: # A list of collections the CMS should be able to edit fields: - {label: Title, name: title, widget: string } - {label: Description, name: description, widget: string } + - {label: Layout, name: layout, widget: hidden, default: default } - {label: Body, name: body, widget: markdown } - label: "Join" name: "join" @@ -25,14 +26,51 @@ collections: # A list of collections the CMS should be able to edit fields: - {label: Title, name: title, widget: string } - {label: Description, name: description, widget: string } + - {label: Layout, name: layout, widget: hidden, default: default } - {label: Body, name: body, widget: markdown } + - label: "Donate" + name: "donate" + file: "donate/index.html" + fields: + - {label: Title, name: title, widget: string } + - {label: Layout, name: layout, widget: hidden, default: default } + - {label: Body, name: body, widget: code } + - label: "News" + name: "news" + file: "news/index.html" + fields: + - {label: Title, name: title, widget: string } + - {label: Layout, name: layout, widget: hidden, default: default } + - {label: Body, name: body, widget: code } - label: "Partners" name: "partners" file: "partners.md" fields: - {label: Title, name: title, widget: string } - {label: Description, name: description, widget: string } + - {label: Layout, name: layout, widget: hidden, default: default } + - {label: Body, name: body, widget: markdown } + - label: "Reports" + name: "reports" + file: "reports.md" + fields: + - {label: Title, name: title, widget: string } + - {label: Description, name: description, widget: string } + - {label: Layout, name: layout, widget: hidden, default: default } - {label: Body, name: body, widget: markdown } + - label: "security.txt" + name: "security.txt" + file: "security.txt" + fields: + - {label: Body, name: body, widget: text } + - label: "Team" + name: "team" + file: "team.html" + fields: + - {label: Title, name: title, widget: string } + - {label: Header, name: header, widget: string } + - {label: Layout, name: layout, widget: hidden, default: default } + - {label: Body, name: body, widget: code } - name: "post" # Used in routes, ie.: /admin/collections/:slug/edit label: "Post" # Used in the UI, ie.: "New Post" folder: "_posts" # The path to the folder where the documents are stored @@ -40,9 +78,26 @@ collections: # A list of collections the CMS should be able to edit create: true # Allow users to create new documents in this collection slug: "{{year}}-{{month}}-{{day}}-{{slug}}" fields: # The fields each document in this collection have - - {label: "Layout", name: "layout", widget: "hidden", default: "post"} + - {label: "Layout", name: "layout", widget: "hidden", default: "news"} - {label: "Title", name: "title", widget: "string", tagname: "h1"} - {label: "Body", name: "body", widget: "markdown"} - - {label: "Categories", name: "categories", widget: "string", required: false} - #meta: # Meta data fields. Just like fields, but without any preview element - # - {label: "Publish Date", name: "date", widget: "datetime", format: "YYYY-MM-DD hh:mm:ss"} + - name: "reports" + label: "Reports" + folder: "_reports" + sort: "title:desc" # Default is title:asc + create: true # Allow users to create new documents in this collection + slug: "{{case}} - {{slug}}" + fields: # The fields each document in this collection have + - {label: "Layout", name: "layout", widget: "hidden", default: "report"} + - {label: "Has case file?", name: "has_casefile", widget: "boolean", default: "false"} + - {label: "Date", name: "date", widget: "date", date_format: "YYYY-MM-DD" } + - {label: "Title", name: "title", widget: "string", tagname: "h1"} + - {label: "Case", name: "case", widget: "string" } + - {label: "Author", name: "author", widget: "string" } + - {label: "Lead", name: "lead", widget: "string" } + - {label: "Researchers", name: "researchers", widget: "list"} + - {label: "CSIRT", name: "csirt", widget: "list"} + - {label: "Excerpt", name: "excerpt", widget: "text"} + - {label: "Start date", name: "start", widget: "date", date_format: "YYYY-MM-DD" } + - {label: "End date", name: "end", widget: "date", date_format: "YYYY-MM-DD" } + - {label: "Body", name: "body", widget: "markdown"} \ No newline at end of file diff --git a/team_old.md b/team_old.md deleted file mode 100644 index a23b749..0000000 --- a/team_old.md +++ /dev/null @@ -1,71 +0,0 @@ ---- -layout: default -title: team -header: our team ---- -
-

Researchers

-
- -We represent a team of highly skilled security researchers who seek and report vulnerabilities as a voluntary service next to their jobs. DIVD sees to it they follow our [Code of Conduct](https://divd.nl/divd-nl/code/) while we provide them a firewall for journalists, lawyers and recruiters. Meanwhile, their research also serves as an empirical base to discover trends in security, stimulate security awareness and develop new methodologies in vulnerability research and disclosure. So, although you will probably never meet our researchers, you may hope they are checking your systems right now, before the bad guys do... - -
- -## Department - -### Research -{% assign sorted = site.team | where: "dept", "Research" | sort: "appearance" %} - -{%- for member in sorted -%} -[{{ member.name }}]({{ member.url }}) ({{ member.role }}){% if forloop.last == false %}, {% endif %} -{% endfor %} - -### CSIRT -{% assign sorted = site.team | where: "dept", "CSIRT" | sort: "appearance" %} -{%- for member in sorted -%} -[{{ member.name }}]({{ member.url }}) ({{ member.role }}){% if forloop.last == false %}, {% endif %} -{% endfor %} - -### Operations -{% assign sorted = site.team | where: "dept", "Operations" | sort: "appearance" %} -{%- for member in sorted -%} -[{{ member.name }}]({{ member.url }}) ({{ member.role }}){% if forloop.last == false %}, {% endif %} -{% endfor %} - -### Institute -{% assign sorted = site.team | where: "dept", "Institute" | sort: "appearance" %} -{%- for member in sorted -%} -[{{ member.name }}]({{ member.url }}) ({{ member.role }}){% if forloop.last == false %}, {% endif %} -{% endfor %} - -### Academy -{% assign sorted = site.team | where: "dept", "Academy" | sort: "appearance" %} -{%- for member in sorted -%} -[{{ member.name }}]({{ member.url }}) ({{ member.role }}){% if forloop.last == false %}, {% endif %} -{% endfor %} - -
- -## Board -{% assign board = site.team | where_exp: "x", "x.board == true" | sort: "appearance" %} -{%- for member in board -%} - {% if member.active == true %} -- [{{ member.name }}]({{ member.url }}): {{ member.content|strip }} - {%- endif -%} -{% endfor %} - -## Advisors -{% assign sorted = site.team | where: "dept", "Advisors" | sort: "appearance" %} -{%- for member in sorted -%} -- [{{ member.name }}]({{ member.url }}) -{% endfor %} - -
-## Supervisory Board -Hacker initiatives like these, tend to have their own dynamics: sparks lead to flames, which die out or lead to wildfires, wasting energy along the way. To keep our minds focused on our goal to make the digital world a safer place and provide helpful hackers a solid platform, we installed a Supervisory Board of cyber security heavyweights. Each board member also represents a sector we try to get along in reaching our goals, i.e.: law enforcement, intelligence services, cyber security companies and academia. - -{% assign supers = site.team | where_exp: "x", "x.supervision == true" | sort: "appearance" %} -{%- for member in supers -%} -- [{{ member.name }}]({{ member.url }}): {{ member.content|strip }} -{% endfor %} - From 2e2b3ca1b786b63a57c16e9441531776881d86f4 Mon Sep 17 00:00:00 2001 From: Frank Breedijk Date: Thu, 2 Nov 2023 09:32:19 +0100 Subject: [PATCH 09/10] Body needs to be a markdown field --- admin/config.yml | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/admin/config.yml b/admin/config.yml index 70b2d05..4aee4a4 100644 --- a/admin/config.yml +++ b/admin/config.yml @@ -34,14 +34,14 @@ collections: # A list of collections the CMS should be able to edit fields: - {label: Title, name: title, widget: string } - {label: Layout, name: layout, widget: hidden, default: default } - - {label: Body, name: body, widget: code } + - {label: Body, name: body, widget: markdown } - label: "News" name: "news" file: "news/index.html" fields: - {label: Title, name: title, widget: string } - {label: Layout, name: layout, widget: hidden, default: default } - - {label: Body, name: body, widget: code } + - {label: Body, name: body, widget: markdown } - label: "Partners" name: "partners" file: "partners.md" @@ -58,11 +58,6 @@ collections: # A list of collections the CMS should be able to edit - {label: Description, name: description, widget: string } - {label: Layout, name: layout, widget: hidden, default: default } - {label: Body, name: body, widget: markdown } - - label: "security.txt" - name: "security.txt" - file: "security.txt" - fields: - - {label: Body, name: body, widget: text } - label: "Team" name: "team" file: "team.html" @@ -70,7 +65,7 @@ collections: # A list of collections the CMS should be able to edit - {label: Title, name: title, widget: string } - {label: Header, name: header, widget: string } - {label: Layout, name: layout, widget: hidden, default: default } - - {label: Body, name: body, widget: code } + - {label: Body, name: body, widget: markdown } - name: "post" # Used in routes, ie.: /admin/collections/:slug/edit label: "Post" # Used in the UI, ie.: "New Post" folder: "_posts" # The path to the folder where the documents are stored From 3ff27862b6e3a22bc34d063b62b5e6fc192a961f Mon Sep 17 00:00:00 2001 From: Frank Breedijk Date: Thu, 2 Nov 2023 15:52:07 +0100 Subject: [PATCH 10/10] Final tweaks. --- .github/workflows/build_pages_native.yml | 14 +++++++------- admin/config.yml | 4 +--- 2 files changed, 8 insertions(+), 10 deletions(-) diff --git a/.github/workflows/build_pages_native.yml b/.github/workflows/build_pages_native.yml index 6c10f3a..d7794ff 100644 --- a/.github/workflows/build_pages_native.yml +++ b/.github/workflows/build_pages_native.yml @@ -7,8 +7,8 @@ on: pull_request: branches: - main -# schedule: -# - cron: "15 3 * * *" + schedule: + - cron: "15 3 * * *" jobs: build_and_test: @@ -49,6 +49,11 @@ jobs: remote_host: ${{ secrets.DEPLOY_HOST }} remote_user: ${{ secrets.DEPLOY_USER }} remote_key: ${{ secrets.DEPLOY_KEY_WWW }} + - name: Deploy Admin inteface to GitHub pages + uses: JamesIves/github-pages-deploy-action@v4 + if: ${{ github.ref == 'refs/heads/main' }} + with: + folder: admin # The folder the action should deploy. - name: Slack notify failure (website) if: failure() uses: voxmedia/github-action-slack-notify-build@v1 @@ -67,9 +72,4 @@ jobs: channel: communications status: FAILED color: danger - - name: Deploy GiutHub pages - uses: JamesIves/github-pages-deploy-action@v4 -# if: ${{ github.ref == 'refs/heads/main' }} # && ( success() || failure() ) # Remove the && clause when a HTML check is flawless - with: - folder: admin # The folder the action should deploy. diff --git a/admin/config.yml b/admin/config.yml index 4aee4a4..a7fe367 100644 --- a/admin/config.yml +++ b/admin/config.yml @@ -25,7 +25,6 @@ collections: # A list of collections the CMS should be able to edit file: "join.md" fields: - {label: Title, name: title, widget: string } - - {label: Description, name: description, widget: string } - {label: Layout, name: layout, widget: hidden, default: default } - {label: Body, name: body, widget: markdown } - label: "Donate" @@ -34,6 +33,7 @@ collections: # A list of collections the CMS should be able to edit fields: - {label: Title, name: title, widget: string } - {label: Layout, name: layout, widget: hidden, default: default } + - {label: Scripts, name: scripts, widget: list, default: ["supp.js]"} - {label: Body, name: body, widget: markdown } - label: "News" name: "news" @@ -47,7 +47,6 @@ collections: # A list of collections the CMS should be able to edit file: "partners.md" fields: - {label: Title, name: title, widget: string } - - {label: Description, name: description, widget: string } - {label: Layout, name: layout, widget: hidden, default: default } - {label: Body, name: body, widget: markdown } - label: "Reports" @@ -55,7 +54,6 @@ collections: # A list of collections the CMS should be able to edit file: "reports.md" fields: - {label: Title, name: title, widget: string } - - {label: Description, name: description, widget: string } - {label: Layout, name: layout, widget: hidden, default: default } - {label: Body, name: body, widget: markdown } - label: "Team"