Skip to content

Commit

Permalink
pullin my repository from organization to my own repo
Browse files Browse the repository at this point in the history
  • Loading branch information
kraju3 committed May 19, 2020
0 parents commit 2fd8cbd
Show file tree
Hide file tree
Showing 31 changed files with 7,786 additions and 0 deletions.
Binary file added .DS_Store
Binary file not shown.
7 changes: 7 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
node_modules
npm-debug.log
.github
README.md
SECURITY.md
.gitignore
.eslintrcc.json
40 changes: 40 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
{
"parserOptions": {
"ecmaVersion": 2018
},
"env": {
"es6": true,
"amd": true,
"mocha": true,
"node": true
},
"extends": [
"eslint:recommended",
"airbnb-base",
"plugin:prettier/recommended"
],
"rules": {
// mimic airbnb, but at 80 characters instead of 100
"max-len": [
"error",
80,
2,
{
"ignoreUrls": true,
"ignoreComments": false,
"ignoreRegExpLiterals": true,
"ignoreStrings": true,
"ignoreTemplateLiterals": true
}
],
// Allow console.log, but prevent weird console shenanigans
"no-console": "off",
"no-restricted-syntax": [
"error",
{
"selector": "CallExpression[callee.object.name='console'][callee.property.name!=/^(log|warn|error|info|trace)$/]",
"message": "Unexpected property on console object was called"
}
]
}
}
19 changes: 19 additions & 0 deletions .github/workflows/dockerimage.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Docker CI

on:
release:
tags:
- v*
types: [ published ]

jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Build and publish to github packages
run: |
docker build -t docker.pkg.github.com/${{ github.repository }}/mefit:$(echo ${{ github.ref }} | sed 's/refs\/tags\///g') .
echo ${{ secrets.GITHUB_TOKEN }} | docker login docker.pkg.github.com --username ${{ github.actor }} --password-stdin
docker push docker.pkg.github.com/${{ github.repository }}/mefit:$(echo ${{ github.ref }} | sed 's/refs\/tags\///g')
echo ${{ github.ref }}
43 changes: 43 additions & 0 deletions .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: code quality

on: [pull_request]

jobs:
eslint_clean:
name: no linter problems
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js 12.x
uses: actions/setup-node@v1
with:
node-version: 12.x
- run: npm ci
- run: npm run style
env:
CI: true

coverage:
name: sufficient code coverage
runs-on: ubuntu-latest

services:
mongodb:
image: mongo
ports:
# will assign a random free host port
- 27017/tcp

steps:
- uses: actions/checkout@v2
- name: Use Node.js 12.x
uses: actions/setup-node@v1
with:
node-version: 12.x
- run: npm ci
- run: npm run coverage --silent
env:
CI: true
MONGODB_HOST: ${{secrets.MONGODB_HOST}}
MONGODB_PORT: ${{ job.services.mongodb.ports[27017] }} # get randomly assigned published port
API_KEY: ${{secrets.API_KEY}}
104 changes: 104 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,104 @@
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
lerna-debug.log*

# Diagnostic reports (https://nodejs.org/api/report.html)
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json

# Runtime data
pids
*.pid
*.seed
*.pid.lock

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage
*.lcov

# nyc test coverage
.nyc_output

# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# Bower dependency directory (https://bower.io/)
bower_components

# node-waf configuration
.lock-wscript

# Compiled binary addons (https://nodejs.org/api/addons.html)
build/Release

# Dependency directories
node_modules/
jspm_packages/

# TypeScript v1 declaration files
typings/

# TypeScript cache
*.tsbuildinfo

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Microbundle cache
.rpt2_cache/
.rts2_cache_cjs/
.rts2_cache_es/
.rts2_cache_umd/

# Optional REPL history
.node_repl_history

# Output of 'npm pack'
*.tgz

# Yarn Integrity file
.yarn-integrity

# dotenv environment variables file
.env
.env.test

# parcel-bundler cache (https://parceljs.org/)
.cache

# Next.js build output
.next

# Nuxt.js build / generate output
.nuxt
dist

# Gatsby files
.cache/
# Comment in the public line in if your project uses Gatsby and *not* Next.js
# https://nextjs.org/blog/next-9-1#public-directory-support
# public

# vuepress build output
.vuepress/dist

# Serverless directories
.serverless/

# FuseBox cache
.fusebox/

# DynamoDB Local files
.dynamodb/

# TernJS port file
.tern-port
19 changes: 19 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
FROM node:latest

# Create app directory
WORKDIR /usr/src/app

# Install app dependencies
# A wildcard is used to ensure both package.json AND package-lock.json are copied
# where available (npm@5+)
COPY package*.json ./

RUN npm install
# If you are building your code for production
# RUN npm ci --only=production

# Bundle app source
COPY . .

EXPOSE 8080
CMD [ "node", "start" ]
77 changes: 77 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
# Ideas R Us Final Project

![](https://github.com/ckanich-classrooms/final-project-ideas-r-us/workflows/code%20quality/badge.svg)
![](https://github.com/ckanich-classrooms/final-project-ideas-r-us/workflows/Docker%20CI/badge.svg)


## Description

UIC MeFit is a Health Manager that provides users with health management tools such as personalized diet plan, hydration checks, weight tracker,social engagements and most importantly personalized fitness plans to the users.MeFit will enable fitness enthusiasts and non-fitness enthusiasts to embark on a journey to improve their mental and physical health.UIC MeFit is supported on all devices because it’s a webapp and allows users to seamlessly keep track of their daily lifestyle on the go.

We provide personalized diet plans depending on the users fitness needs using FatSecret API. Along with that, we provide personalized fitness plans cater to the users desired physique. MeFit will enable users to track their daily gym activity and weight by incorporating Google Fit API (TBD). This will provide our users with a progress report on their fitness journey. We will also be able to provide you locations to the nearest gyms and nearest restaurants that you could use your cheat days on by incorporating Google Maps API ;). Also 70 percent of our body is made up of water, don’t worry we will have an alert system ready in place for you to empty out them water bottles. To top it off with, we provided a social platform for our users to show off their healthy eating habits and fitness lifestyle to other MeFit users.


## Authors

| Member | Web dev level | Specialization |
| --- | --- | --- |
| Kiran Raju | Intermediate | Cloud: Convert entire app to be cloud-native using Azure|
| Peter Ekhator| Intermediate | DevOps: Build a deployment strategy using Azure Kubernetes Service|

## Deliverables for checkpoint 2
# CRUD Users
- Able to create an user, update an user profile,delete an user
- Able to load an users data when logged in
- Make sure the data is secure
- Check MongoDB Connection

## Deliverables for checkpoint 4

Outline in English what the deliverables will be for checkpoint 4. Reminder that this is not *due*
until checkpoint 2, but failing to plan is planning to fail.

For each specialization, you must list specific checkpoints that are relevant to that particular specialization.
- Trying to establish an API connection for FatSecret API
- Try to finish most of the app functionality
- Set up Cloud enivronment (Azure)
- Trying to register for a Azure Account
- Test the Connection
- Make sure it's able to work properly

- Ensure other external API functionality are working properly
- Figure out a way to keep secrets secure from Github
- WRITE MORE TESTS!!!!!!!YAY
- Using DevOps Strategy to deploy using Azure Kubernets service

## Tests for Checkpoint 4 (fitness.js)
- describe('User Info/Settings')
- describe('Users Execise Routine')
- decribe('Users fitnes plans')
- describe('Google Fit API working properly')
## Deliverables for final project

Outline in English what the deliverables will be for the final checkpoint. This will should be
similar to the **Description** above, but written out as an explicit checklist rather than a human
readable description. Reminder that this is not *due* until checkpoint 4, but failing to plan is
planning to fail.

For each specialization, you must list specific checkpoints that are relevant to that particular specialization.

## Specialization deliverables

For each student/team adding a specialization, name that specialization and describe what
functionality you will be adding.

## Installation

- Install Docker <https://docs.docker.com/install/>.
- Install Docker Compose <https://docs.docker.com/compose/install/>
- Update `docker-compose.yml` with the latest image at <https://github.com/ckanich-classrooms/final-project-ideas-r-us/packages/>

### Deploy on locally
- run `docker-compose up`

### Deploy to Azure
- Create Azure app service
- Update container settings with `docker-compose.yml` configuration file and github packages username and token
- Access web app using url in Azure app service overview blade
Loading

0 comments on commit 2fd8cbd

Please sign in to comment.