Skip to content

Commit

Permalink
Added github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
souravtecken committed Feb 6, 2021
1 parent 17e70fd commit df036e7
Show file tree
Hide file tree
Showing 5 changed files with 56 additions and 10,144 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Deployment
on:
push:
branches:
- master
jobs:
deploy:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [12.x]
steps:
- uses: actions/checkout@v1
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Install Client Packages
run: cd client && npm install
- name: Build client
run: cd client && npm run build
- name: Deploy to gh-pages
uses: peaceiris/actions-gh-pages@v3
with:
deploy_key: ${{ secrets.ACTIONS_DEPLOY_KEY }}
publish_dir: ./client/out
4 changes: 3 additions & 1 deletion client/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,6 @@ node_modules/
# Logs
npm-debug.log*
yarn-debug.log*
yarn-error.log*
yarn-error.log*

/out
9 changes: 9 additions & 0 deletions client/next.config.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,13 @@
const isProduction = (process.env.NODE_ENV || 'production') === 'production';

const assetPrefix = isProduction ? '/website' : '';

module.exports = {
trailingSlash: true,
assetPrefix: assetPrefix,
images: {
loader: "imgix"
},
webpack(config) {
config.module.rules.push({
test: /\.svg$/,
Expand Down
Loading

1 comment on commit df036e7

@vercel
Copy link

@vercel vercel bot commented on df036e7 Feb 6, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.