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

added crest link in the header #137

Open
wants to merge 183 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
183 commits
Select commit Hold shift + click to select a range
8bb4ba2
Create nodejs.yml
saikatkumar-official Apr 16, 2020
1acfc79
testing commit
saikatkumar-official Apr 16, 2020
9c04fad
Create nodejs_1.yml
saikatkumar-official Apr 16, 2020
2ce66bb
Update README.md
saikatkumar-official Apr 16, 2020
5db2e0d
Update README.md
saikatkumar-official Apr 16, 2020
0b98b2b
Update utils.test.js
saikatkumar-official Apr 16, 2020
de69f94
Update utils.test.js
saikatkumar-official Apr 16, 2020
0605761
Merge pull request #1 from saikatkumar-official/saikatkumar-official-…
saikatkumar-official Apr 16, 2020
e5700e4
Update README.md
saikatkumar-official Apr 16, 2020
297608b
Merge pull request #4 from saikatkumar-official/bug-fix-saikat
saikatkumar-official Apr 16, 2020
7a58e3a
Create aws.yml
saikatkumar-official Apr 19, 2020
0918583
Merge pull request #5 from saikatkumar-official/saikatkumar-official-…
saikatkumar-official Apr 19, 2020
5f7f25a
Update README.md
saikatkumar-official Apr 19, 2020
29bec8e
Create aws1.yml
saikatkumar-official Apr 19, 2020
6c16a80
Delete aws.yml
saikatkumar-official Apr 19, 2020
b19e0ef
Update aws1.yml
saikatkumar-official Apr 19, 2020
aa05cac
Delete aws1.yml
saikatkumar-official Apr 19, 2020
c900ee8
Create aws.yml
saikatkumar-official Apr 19, 2020
94812f6
Update aws.yml
saikatkumar-official Apr 19, 2020
726d078
Update aws.yml
saikatkumar-official Apr 19, 2020
3b8172d
Create aws-config.yml
saikatkumar-official Apr 19, 2020
3f5ee58
Create sam-template.yml
saikatkumar-official Apr 19, 2020
681f17b
Update aws.yml
saikatkumar-official Apr 19, 2020
1b0aa5c
Update package-lock.json
saikatkumar-official Apr 19, 2020
1388f29
Update aws.yml
saikatkumar-official Apr 19, 2020
edd7980
Create sample.js
saikatkumar-official Apr 19, 2020
2c098e0
Create sample_node.js
saikatkumar-official Apr 19, 2020
aab89d4
Update aws.yml
saikatkumar-official Apr 19, 2020
f691568
Update aws.yml
saikatkumar-official Apr 23, 2020
3f73cfc
Update aws.yml
saikatkumar-official Apr 23, 2020
048c369
Create appspec.yml
saikatkumar-official Apr 23, 2020
e50841b
Create before_start.sh
saikatkumar-official Apr 23, 2020
43562d9
Create after_start.sh
saikatkumar-official Apr 23, 2020
15fadd1
Create before_start.sh
saikatkumar-official Apr 23, 2020
a5ec390
Create after_start.sh
saikatkumar-official Apr 23, 2020
234374d
Create aws1.yml
saikatkumar-official Apr 23, 2020
ad8ba4b
Rename aws.yml to aws.yml.backuo
saikatkumar-official Apr 23, 2020
34eedd3
Update appspec.yml
saikatkumar-official Apr 23, 2020
36b00f2
Update appspec.yml
saikatkumar-official Apr 23, 2020
7dda87d
Update after_start.sh
saikatkumar-official Apr 23, 2020
4dd9c01
Update appspec.yml
saikatkumar-official Apr 23, 2020
3375d0b
Update before_start.sh
saikatkumar-official Apr 23, 2020
2f8eec5
Update after_start.sh
saikatkumar-official Apr 23, 2020
2f4c969
Update after_start.sh
saikatkumar-official Apr 23, 2020
16e7bfa
Update before_start.sh
saikatkumar-official Apr 23, 2020
e6d96b6
Update before_start.sh
saikatkumar-official Apr 23, 2020
77149f8
Update after_start.sh
saikatkumar-official Apr 23, 2020
be2c87e
Update before_start.sh
saikatkumar-official Apr 23, 2020
f3f404b
Update after_start.sh
saikatkumar-official Apr 23, 2020
558b3c7
Update before_start.sh
saikatkumar-official Apr 23, 2020
88dd2ff
Update before_start.sh
saikatkumar-official Apr 23, 2020
6984626
Update after_start.sh
saikatkumar-official Apr 23, 2020
12d1ace
Update after_start.sh
saikatkumar-official Apr 23, 2020
b9fdb43
Update after_start.sh
saikatkumar-official Apr 23, 2020
5e44949
Update after_start.sh
saikatkumar-official Apr 23, 2020
0153b89
Update after_start.sh
saikatkumar-official Apr 23, 2020
a2bb097
Update before_start.sh
saikatkumar-official Apr 23, 2020
e4f93bb
Rename aws1.yml to aws1.yml.backup
saikatkumar-official Apr 23, 2020
8083d86
Rename nodejs.yml to nodejs.yml.backup
saikatkumar-official Apr 23, 2020
14122a7
Rename nodejs_1.yml to nodejs_1.yml,backup
saikatkumar-official Apr 23, 2020
27c86a4
Create copyFileToServer.yml
saikatkumar-official Apr 23, 2020
97a2d57
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
bb01298
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
5e6e292
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
4f64a38
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
1695649
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
cfd74d6
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
ffcf234
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
da75ed5
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
af6d65a
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
2fa5f8f
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
0fc003d
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
3d9f19a
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
4c9e7d9
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
5d99760
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
e5bdc2b
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
a1220bf
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
1d3da5b
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
6f4a2a2
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
d7b155f
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
53cdb79
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
b16080d
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
69e9f28
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
71c2f1a
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
288a8ce
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
a100c6e
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
cf1f7cc
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
e0c050c
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
5de7d09
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
38a2c30
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
6ceb5a0
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
8efb209
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
5ea70ae
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
a1374d6
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
d471ef9
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
350e8ec
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
b633872
Update copyFileToServer.yml
saikatkumar-official Apr 23, 2020
0528731
Update copyFileToServer.yml
saikatkumar-official Apr 24, 2020
f5ded17
Update copyFileToServer.yml
saikatkumar-official Apr 24, 2020
166a539
Update copyFileToServer.yml
saikatkumar-official Apr 24, 2020
23c6e3a
Update copyFileToServer.yml
saikatkumar-official Apr 24, 2020
9ceb461
Update copyFileToServer.yml
saikatkumar-official Apr 24, 2020
f59a20c
Update copyFileToServer.yml
saikatkumar-official Apr 24, 2020
7bf721a
Update copyFileToServer.yml
saikatkumar-official Apr 24, 2020
21b487b
Update copyFileToServer.yml
saikatkumar-official Apr 24, 2020
9342444
Update copyFileToServer.yml
saikatkumar-official Apr 24, 2020
eab8f2d
Update copyFileToServer.yml
saikatkumar-official Apr 24, 2020
bf11af6
Update copyFileToServer.yml
saikatkumar-official Apr 24, 2020
38e4053
Update copyFileToServer.yml
saikatkumar-official Apr 24, 2020
30a4625
Update copyFileToServer.yml
saikatkumar-official Apr 24, 2020
2e4a1c2
Update copyFileToServer.yml
saikatkumar-official Apr 24, 2020
e156798
Update copyFileToServer.yml
saikatkumar-official Apr 24, 2020
354d470
Update index.pug
saikatkumar-official Apr 24, 2020
b6cf7de
Update index.pug
saikatkumar-official Apr 24, 2020
61ed327
Update index.pug
saikatkumar-official Apr 24, 2020
d68290a
Update index.pug
saikatkumar-official Apr 24, 2020
7f2920c
Update index.pug
saikatkumar-official Apr 24, 2020
11d6d5b
Update copyFileToServer.yml
saikatkumar-official Apr 27, 2020
31b36a4
Update and rename aws1.yml.backup to aws_s3.yml
saikatkumar-official Apr 28, 2020
ac974d0
Rename copyFileToServer.yml to copyFileToServer.yml.remove
saikatkumar-official Apr 28, 2020
56c0d84
Update aws_s3.yml
saikatkumar-official Apr 28, 2020
426d4d7
Update aws_s3.yml
saikatkumar-official Apr 28, 2020
6b7de48
Update after_start.sh
saikatkumar-official Apr 28, 2020
3087862
Update before_start.sh
saikatkumar-official Apr 28, 2020
f7a5b2b
Update index.pug
saikatkumar-official Apr 28, 2020
833e340
Update index.pug
saikatkumar-official Apr 28, 2020
518c823
Update index.pug
saikatkumar-official Apr 28, 2020
7463c48
Update aws-config.yml
saikatkumar-official Apr 28, 2020
d993f8d
Update aws-config.yml
saikatkumar-official Apr 28, 2020
bfb27fe
Update aws_s3.yml
saikatkumar-official Apr 28, 2020
7979dc2
Rename aws-config.yml to aws-config.yml.backup
saikatkumar-official Apr 28, 2020
42d2943
Update aws_s3.yml
saikatkumar-official Apr 28, 2020
4f09255
Update aws_s3.yml
saikatkumar-official Apr 28, 2020
1d50135
Update aws_s3.yml
saikatkumar-official Apr 28, 2020
a305f7f
Update and rename aws-config.yml.backup to aws-config.yml
saikatkumar-official Apr 28, 2020
cfa9857
Update index.pug
saikatkumar-official Jul 30, 2020
6817ed8
Update index.pug
saikatkumar-official Aug 3, 2020
2114f91
Rename aws-config.yml to aws-config.yml.remove
saikatkumar-official Aug 25, 2020
1ceb962
Rename aws_s3.yml to aws_s3.yml.remove
saikatkumar-official Aug 25, 2020
66b5b48
Update README.md
nishantkumar2019 Aug 25, 2020
a04d3b8
Update index.pug
nishantkumar2019 Aug 25, 2020
013b86f
Update index.pug
nishantkumar2019 Aug 25, 2020
53d949b
Update nodejs.yml.backup
saikatkumar-official Aug 25, 2020
1d9d4f1
Merge branch 'Devlopment' into feature/nishantkumar2019-adding-crest-…
saikatkumar-official Aug 25, 2020
7380455
Rename nodejs.yml.backup to nodejs.yml
saikatkumar-official Aug 25, 2020
bbefdd7
Merge branch 'Devlopment' into feature/nishantkumar2019-adding-crest-…
saikatkumar-official Aug 25, 2020
b966b79
Update nodejs.yml
saikatkumar-official Aug 25, 2020
55a4dc9
Update nodejs.yml
saikatkumar-official Aug 25, 2020
3a32aae
Merge pull request #11 from saikatkumar-official/Devlopment
saikatkumar-official Aug 25, 2020
590aaeb
Create node.js.yml
saikatkumar-official Aug 25, 2020
98b1117
Rename nodejs.yml to nodejs.yml.remove
saikatkumar-official Aug 25, 2020
f4f05ca
Merge pull request #13 from saikatkumar-official/feature/nishantkumar…
saikatkumar-official Aug 25, 2020
dd431e0
Rename copyFileToServer.yml.remove to copyFileToServer.yml
saikatkumar-official Aug 25, 2020
a701258
Update README.md
saikatkumar-official Aug 25, 2020
142b343
Update README.md
saikatkumar-official Aug 25, 2020
b56c001
Update index.pug
nishantkumar2019 Aug 25, 2020
e934d91
Update index.pug
nishantkumar2019 Aug 25, 2020
e33820f
Rename copyFileToServer.yml to copyFileToServer.yml.remove
nishantkumar2019 Aug 25, 2020
2553c47
Update index.pug
nishantkumar2019 Aug 25, 2020
6515fee
Update utils.test.js
nishantkumar2019 Aug 25, 2020
d59d034
Update utils.test.js
nishantkumar2019 Aug 25, 2020
5fb3fc8
Merge pull request #15 from saikatkumar-official/feature/test-css1
saikatkumar-official Aug 25, 2020
87c5539
Rename copyFileToServer.yml.remove to copyFileToServer.yml
saikatkumar-official Aug 25, 2020
995914f
Update README.md
nishantkumar2019 Aug 25, 2020
f17e50c
Merge pull request #18 from saikatkumar-official/nishantkumar2019-pat…
saikatkumar-official Aug 25, 2020
2a183ea
Update index.pug
saikatkumar-official Aug 27, 2020
a1344b7
Update copyFileToServer.yml
saikatkumar-official Aug 27, 2020
b59d5dc
Update index.pug
saikatkumar-official Aug 27, 2020
37e52c9
Update index.pug
nishantkumar2019 Aug 27, 2020
64b8ed5
Update index.pug
nishantkumar2019 Aug 27, 2020
1f469ff
Update utils.test.js
nishantkumar2019 Aug 27, 2020
c80c82d
Update utils.test.js
saikatkumar-official Aug 27, 2020
686b564
Merge pull request #20 from saikatkumar-official/feature/nishant-cres…
saikatkumar-official Aug 27, 2020
f1b11e9
Update index.pug
saikatkumar-official Aug 27, 2020
e0bd622
Rename copyFileToServer.yml to copyFileToServer.yml.remove
saikatkumar-official Aug 27, 2020
1bae97c
Rename node.js.yml to node.js.yml.remove
saikatkumar-official Aug 27, 2020
e4b06ab
Rename copyFileToServer.yml.remove to copyFileToServer.yml
saikatkumar-official Aug 27, 2020
29ad3a7
Update index.pug
saikatkumar-official Aug 27, 2020
e59ff71
Create node.js.yml
saikatkumar-official Aug 27, 2020
0e6a508
Update index.pug
nishantkumar2019 Aug 27, 2020
4a842ca
Merge pull request #24 from saikatkumar-official/feature/nishant-cres…
saikatkumar-official Aug 27, 2020
20eb9d8
Update node.js.yml
saikatkumar-official Dec 2, 2022
987bab2
Update node.js.yml
saikatkumar-official Dec 2, 2022
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
42 changes: 42 additions & 0 deletions .github/aws-config.yml.remove
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@

##########################################################
# AWS Configuration file for NodeJS Deploy GitHub Action #
# #
# NOTE: This file holds the variables needed #
# to configure the GitHub Deploy NodeJS #
# on AWS Serverless #
# #
# This file needs to be in the location: #
# - .github/aws-config.yml #
# in your repository to be parsed at run time #
##########################################################

########################################
# AWS S3 Bucket for package and deploy #
########################################
# NOTE: This bucket must exist before the GitHub Action, and match the name of your S3 bucket on Amazon
#s3_bucket: crest-github-cd/{datetime}.zip

##################################
# AWS Cloud Formation Stack name #
##################################
# NOTE: Defaults to "mystack" if left empty
aws_stack_name: mystack

####################
# AWS SAM Template #
####################
# NOTE: This is the AWS SAM template.yml file that we need to deploy
# Pathing is from root of repository:
# Example:
# if file is called `template.yml` and is in the root of repository
# under the '.github' folder:
# sam_template: .github/template.yml
sam_template: sam-template.yml

################################
# region for connection to AWS #
################################
# Default region is: us-west-2
# if not provided below
region: ap-southeast-1
67 changes: 67 additions & 0 deletions .github/workflows/aws.yml.backuo
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
# This workflow will build and push a new container image to Amazon ECR,
# and then will deploy a new task definition to Amazon ECS, when a release is created
#
# To use this workflow, you will need to complete the following set-up steps:
#
# 1. Create an ECR repository to store your images.
# For example: `aws ecr create-repository --repository-name my-ecr-repo --region us-east-2`.
# Replace the value of `ECR_REPOSITORY` in the workflow below with your repository's name.
# Replace the value of `aws-region` in the workflow below with your repository's region.
#
# 2. Create an ECS task definition, an ECS cluster, and an ECS service.
# For example, follow the Getting Started guide on the ECS console:
# https://us-east-2.console.aws.amazon.com/ecs/home?region=us-east-2#/firstRun
# Replace the values for `service` and `cluster` in the workflow below with your service and cluster names.
#
# 3. Store your ECS task definition as a JSON file in your repository.
# The format should follow the output of `aws ecs register-task-definition --generate-cli-skeleton`.
# Replace the value of `task-definition` in the workflow below with your JSON file's name.
# Replace the value of `container-name` in the workflow below with the name of the container
# in the `containerDefinitions` section of the task definition.
#
# 4. Store an IAM user access key in GitHub Actions secrets named `AWS_ACCESS_KEY_ID` and `AWS_SECRET_ACCESS_KEY`.
# See the documentation for each action used below for the recommended IAM policies for this IAM user,
# and best practices on handling the access key credentials.

on:
pull_request:
branches:
- master

name: Deploy to Amazon ECS

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v1
- name: npm install and build webpack
run: |
npm audit fix
npm install

- uses: actions/upload-artifact@master
with:
name: webpack artifacts
path: dist/

deploy:
name: Deploy Node.js app to AWS
needs: build
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v1

- name: Download built artifact
uses: actions/download-artifact@master
with:
name: webpack artifacts
path: public

- name: Deploy to AWS
uses: github/deploy-nodejs@master
env:
AWS_ACCESS_KEY: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
69 changes: 69 additions & 0 deletions .github/workflows/aws_s3.yml.remove
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
# This workflow will build and push a new container image to Amazon ECR,
# and then will deploy a new task definition to Amazon ECS, when a release is created
#
# To use this workflow, you will need to complete the following set-up steps:
#
# 1. Create an ECR repository to store your images.
# For example: `aws ecr create-repository --repository-name my-ecr-repo --region us-east-2`.
# Replace the value of `ECR_REPOSITORY` in the workflow below with your repository's name.
# Replace the value of `aws-region` in the workflow below with your repository's region.
#
# 2. Create an ECS task definition, an ECS cluster, and an ECS service.
# For example, follow the Getting Started guide on the ECS console:
# https://us-east-2.console.aws.amazon.com/ecs/home?region=us-east-2#/firstRun
# Replace the values for `service` and `cluster` in the workflow below with your service and cluster names.
#
# 3. Store your ECS task definition as a JSON file in your repository.
# The format should follow the output of `aws ecs register-task-definition --generate-cli-skeleton`.
# Replace the value of `task-definition` in the workflow below with your JSON file's name.
# Replace the value of `container-name` in the workflow below with the name of the container
# in the `containerDefinitions` section of the task definition.
#
# 4. Store an IAM user access key in GitHub Actions secrets named `AWS_ACCESS_KEY_ID` and `AWS_SECRET_ACCESS_KEY`.
# See the documentation for each action used below for the recommended IAM policies for this IAM user,
# and best practices on handling the access key credentials.

on:
push:
branches:
- master

name: Deploy to Amazon ECS

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v1
- name: npm install and build webpack
run: |
npm audit fix
npm install

- uses: actions/upload-artifact@master
with:
name: webpack artifacts
path: dist/

deploy:
name: Deploy Node.js app to AWS
needs: build
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v1

- name: Download built artifact
uses: actions/download-artifact@master
with:
name: webpack artifacts
path: public

- name: Deploy to AWS
uses: github/deploy-nodejs@master
env:
AWS_ACCESS_KEY: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_S3_BUCKET: crest-github-cd/aws-github-prod.zip
AWS_REGION: ap-southeast-1
50 changes: 50 additions & 0 deletions .github/workflows/copyFileToServer.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: scp copy folder to remote via SSH

on:
push:
branches: [ Devlopment ]

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: checkout1
uses: actions/checkout@v1
- name: Removeing the old distribution
uses: garygrossgarten/github-action-ssh@release
with:
command: |
cd /opt/tonkotsu-nodejs
killall node
rm -rf *
host: ${{ secrets.HOST }}
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
env:
CI: true
- name: Copy folder content recursively to remote
uses: garygrossgarten/github-action-scp@release
with:
local: "."
remote: "/opt/tonkotsu-nodejs"
host: ${{ secrets.HOST }}
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
env:
CI: true

- name: Install the module and Run stagging server
uses: garygrossgarten/github-action-ssh@release
with:
command: |
cd /opt/tonkotsu-nodejs
npm install
npm start </dev/null &>/dev/null &
host: ${{ secrets.HOST }}
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
env:
CI: true


29 changes: 29 additions & 0 deletions .github/workflows/node.js.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions

name: Node.js CI

on:
push:
branches: [ Devlopment ]
pull_request:
branches: [ Devlopment ]

jobs:
build:

runs-on: ubuntu-latest

strategy:
matrix:
node-version: [10.x, 12.x, 14.x]

steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- run: npm ci
- run: npm run build --if-present
- run: npm test
29 changes: 29 additions & 0 deletions .github/workflows/node.js.yml.remove
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions

name: Node.js CI

on:
push:
branches: [ Devlopment ]
pull_request:
branches: [ Devlopment ]

jobs:
build:

runs-on: ubuntu-latest

strategy:
matrix:
node-version: [10.x, 12.x, 14.x]

steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- run: npm ci
- run: npm run build --if-present
- run: npm test
31 changes: 31 additions & 0 deletions .github/workflows/nodejs.yml.remove
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions

name: Node.js CI

on:
push:
branches: [devlopment ]
pull_request:
branches: [devlopment ]

jobs:
build:

runs-on: ubuntu-latest

strategy:
matrix:
node-version: [10.x, 12.x]

steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- run: npm ci
- run: npm run build --if-present
- run: npm test
env:
CI: true
31 changes: 31 additions & 0 deletions .github/workflows/nodejs_1.yml,backup
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions

name: Node.js CI

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

jobs:
build:

runs-on: ubuntu-latest

strategy:
matrix:
node-version: [10.x, 12.x]

steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- run: npm ci
- run: npm run build --if-present
- run: npm test
env:
CI: true
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@

This repository contains the base project part of our on-site GitHub Verified Partner workshop program. It is meant to be used for in-classroom training under the supervision of GitHub coaches.

This is the NodeJS version of our "Tonkotsu" workshop webapp. The codebase is pretty simple: it's a NodeJS app that will connect to GitHub's [Octocat API endpoint](https://api.github.com/octocat) and return the Zen quote of the day. E.g.:
This is the NodeJS version of our "Tonkotsu" workshop webapp. The codebase is pretty simple: it's a NodeJS app that will connect to GitHub's [Octocat API endpoint](https://api.github.com/octocat) and return the Zen quote of the day. E.g

### Demo (sucess)

![out](https://user-images.githubusercontent.com/1078545/57860397-bc7ff380-77ec-11e9-80f8-39e02ef3c035.gif)


### Demo (failure)
### Demo (failure)#

![out](https://user-images.githubusercontent.com/1078545/57860396-bc7ff380-77ec-11e9-8f55-83b879e667d2.gif)

Expand All @@ -30,7 +30,7 @@ Tests:

```
npm run test
```
```'`

Run server (defaults to localhost:3000):

Expand Down
14 changes: 14 additions & 0 deletions appspec.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
version: 0.0
os: linux
files:
- source: /
destination: /opt/tonkotsu-nodejs/
hooks:
BeforeInstall:
- location: deploy/before_install/before_start.sh
timeout: 300
runas: root
AfterInstall:
- location: deploy/before_install/after_start.sh
timeout: 300
runas: root
2 changes: 2 additions & 0 deletions deploy/after_start.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#!/bin/sh
service httpd restart
Loading