Skip to content

Commit

Permalink
fix(stage-deploy): build main with local bob (#2370)
Browse files Browse the repository at this point in the history
* style: format stage-deploy.yml with prettier

`npx prettier -w .github/workflows/stage-deploy.yml`

* fix(stage-deploy): build with local bob

* chore(stage-deploy): build on pushes to main
  • Loading branch information
caugner committed Dec 24, 2022
1 parent 4226369 commit a418610
Showing 1 changed file with 10 additions and 21 deletions.
31 changes: 10 additions & 21 deletions .github/workflows/stage-deploy.yml
Original file line number Diff line number Diff line change
@@ -1,27 +1,23 @@
name: Stage Deployment

on:
push:
branches:
- main

workflow_dispatch:
inputs:
notes:
description: "Notes"
required: false
default: ""
description: 'Notes'
required: false
default: ''

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
with:
path: examples

- uses: actions/checkout@v3
with:
repository: mdn/bob
ref: stage
path: bob

- name: Setup Node.js environment
uses: actions/setup-node@v3
Expand All @@ -30,15 +26,10 @@ jobs:
cache: yarn

- name: Install all yarn packages
run: yarn --production --frozen-lockfile
working-directory: bob
run: yarn --frozen-lockfile

- name: Build all
# TODO: bob uses relative paths in bundles. For now we just symlink.
run: |
ln -s ../bob/node_modules .
node ../bob/lib/mdn-bob.js
working-directory: examples
run: yarn build

- name: Configure AWS credentials for stage
uses: aws-actions/configure-aws-credentials@v1
Expand All @@ -48,6 +39,4 @@ jobs:
aws-region: us-east-1

- name: Deploy pages
run: |
aws s3 sync docs/ s3://interactive-examples-stage-ce3e7ea385c68f44/
working-directory: examples
run: aws s3 sync docs/ s3://interactive-examples-stage-ce3e7ea385c68f44/

0 comments on commit a418610

Please sign in to comment.