Update woo-page-deploy.yml #2
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
name: Deploy the WOO Page to GitHub Pages | |
env: # Change these to your preferences any image url can also be a base encoded image | |
GITHUB_PAGES_BRANCH: gh-pages | |
# options: "true" | "false" | |
USE_GITHUB_REPOSITORY_NAME_AS_PATH_PREFIX: "false" | |
GITHUB_REPOSITORY_NAME: ${{ github.event.repository.name }} | |
API_BASE_URL: "https://api.gateway.commonground.nu/api" | |
NL_DESIGN_THEME_CLASSNAME: "conduction-theme" | |
DEV_ENVIRONMENT: "true" | |
SHOW_CATEGORY: "true" | |
SHOW_ORGANIZATION: "false" | |
FAVICON_URL: "data:image/svg+xml,%3Csvg id='Laag_1' data-name='Laag 1' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 259.81 300'%3E%3Cpath d='M129.9,0,0,75V225l129.9,75,129.91-75V75Zm96.8,205.89-96.8,55.88L33.1,205.89V94.11l96.8-55.89,96.8,55.89Z' style='fill:%234376fc'/%3E%3Cpolygon points='129.59 112.23 160.01 129.79 195.41 109.35 129.59 71.35 61.47 110.67 61.47 189.33 129.59 228.65 195.41 190.65 160.01 170.21 129.59 187.77 96.88 168.88 96.88 131.12 129.59 112.23' style='fill:%234376fc'/%3E%3C/svg%3E" | |
HEADER_LOGO_URL: "https://www.conduction.nl/" | |
ORGANISATION_NAME: "Conduction" | |
JUMBOTRON_IMAGE_URL: "https://www.conduction.nl/wp-content/uploads/2021/07/cropped-Conduction_HOME_0000_afb1-1.png" | |
FOOTER_LOGO_URL: "true" | |
FOOTER_LOGO_HREF: "https://conduction.nl/" | |
FOOTER_CONTENT: "https://raw.githubusercontent.com/ConductionNL/woo-website-template/main/pwa/src/templates/templateParts/footer/FooterContent.json" | |
FOOTER_CONTENT_HEADER: "heading-3" | |
OIDN_NUMBER: "conduction" | |
ENV_VARS_SET: "true" | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Get the WOO Website Template Code | |
uses: actions/checkout@v2 | |
with: | |
repository: ConductionNL/woo-website-template | |
ref: development | |
# With special thanxs to https://github.com/SpicyPizza/create-envfile | |
- name: Make envfile | |
uses: SpicyPizza/[email protected] | |
with: | |
envkey_GITHUB_REPOSITORY_NAME: ${{ env.GITHUB_REPOSITORY_NAME }} | |
envkey_USE_GITHUB_REPOSITORY_NAME_AS_PATH_PREFIX: ${{ env.USE_GITHUB_REPOSITORY_NAME_AS_PATH_PREFIX }} | |
envkey_GATSBY_API_BASE_URL: ${{ env.API_BASE_URL }} | |
envkey_GATSBY_NL_DESIGN_THEME_CLASSNAME: ${{ env.NL_DESIGN_THEME_CLASSNAME }} | |
envkey_GATSBY_DEV_ENVIRONMENT: ${{ env.DEV_ENVIRONMENT }} | |
envkey_GATSBY_SHOW_CATEGORY: ${{ env.SHOW_CATEGORY }} | |
envkey_GATSBY_SHOW_ORGANIZATION: ${{ env.SHOW_ORGANIZATION }} | |
envkey_GATSBY_FAVICON_URL: ${{ env.FAVICON_URL }} | |
envkey_GATSBY_HEADER_LOGO_URL: ${{ env.HEADER_LOGO_URL }} | |
envkey_GATSBY_ORGANISATION_NAME: ${{ env.ORGANISATION_NAME }} | |
envkey_GATSBY_JUMBOTRON_IMAGE_URL: ${{ env.JUMBOTRON_IMAGE_URL }} | |
envkey_GATSBY_FOOTER_LOGO_URL: ${{ env.FOOTER_LOGO_URL }} | |
envkey_GATSBY_FOOTER_LOGO_HREF: ${{ env.FOOTER_LOGO_HREF }} | |
envkey_GATSBY_FOOTER_CONTENT: ${{ env.FOOTER_CONTENT }} | |
envkey_GATSBY_FOOTER_CONTENT_HEADER: ${{ env.FOOTER_CONTENT_HEADER }} | |
envkey_GATSBY_OIDN_NUMBER: ${{ env.OIDN_NUMBER }} | |
envkey_GATSBY_ENV_VARS_SET: ${{ env.ENV_VARS_SET }} | |
directory: pwa/static | |
file_name: .env.production | |
fail_on_empty: true | |
sort_keys: false | |
- name: Set up Node.js | |
uses: actions/setup-node@v2 | |
with: | |
node-version: 18 | |
- name: Install dependencies | |
run: cd pwa && npm install | |
- name: Install parcel/watcher | |
run: cd pwa && npm install @parcel/watcher | |
- name: Remove old Gatsby cache | |
run: rm -rf pwa/.cache | |
- name: Build application | |
run: cd pwa && npm run build | |
- name: Deploy to GitHub Pages | |
uses: JamesIves/[email protected] | |
with: | |
branch: ${{ env.GITHUB_PAGES_BRANCH }} | |
folder: pwa/public |