-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #41 from Code-Hammers/dev
Merging Dev to Main
- Loading branch information
Showing
58 changed files
with
5,113 additions
and
449 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
node_modules/ | ||
npm-debug.log |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
name: build-tests | ||
on: | ||
pull_request: | ||
branches: | ||
- dev | ||
jobs: | ||
unit-testing: | ||
runs-on: ubuntu-latest | ||
env: | ||
JWT_SECRET: ${{ secrets.JWT_SECRET }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Build Docker Image | ||
run: docker build -t brok3turtl3/codehammers:latest -f Dockerfile-dev . | ||
- name: Install Root Dependencies | ||
run: docker run brok3turtl3/codehammers:latest npm install | ||
- name: Install Client Dependencies | ||
run: docker run brok3turtl3/codehammers:latest /bin/sh -c "cd client && npm install" | ||
#- name: List node_modules | ||
#run: docker run brok3turtl3/codehammers:latest /bin/sh -c "ls node_modules && cd client && ls node_modules" | ||
- run: docker-compose -f docker-compose-test.yml up --abort-on-container-exit | ||
env: | ||
JWT_SECRET: ${{ secrets.JWT_SECRET }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
node_modules | ||
.env | ||
dist/ | ||
coverage/ | ||
coverage/ | ||
/client/build/ |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
#SET NODE VERSION | ||
FROM node:18.17.1 as builder | ||
|
||
#CONTAINER WORKING DIRECTORY | ||
WORKDIR /usr/src/app | ||
|
||
#COPY FILES INTO CONTAINER AT /usr/src/app | ||
COPY . . | ||
|
||
#INSTALL ROOT PACKAGES | ||
RUN npm install | ||
|
||
#INSTALL CLIENT PACKAGES | ||
RUN cd client && npm install && npm run build | ||
|
||
#SERVE BUILT FILES | ||
FROM node:18.17.1 | ||
|
||
#SET WORKING DIRECTORY | ||
WORKDIR /usr/src/app | ||
|
||
#COPY FROM BUILDER STAGE | ||
COPY --from=builder /usr/src/app/client/build ./client/build | ||
COPY --from=builder /usr/src/app/node_modules ./node_modules | ||
|
||
#EXPOSE PORT | ||
EXPOSE 80 | ||
|
||
#DEFAULT CMD TO SERVE BUILT FILES | ||
CMD ["npx", "serve", "-s", "client/build", "-l", "80"] |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
#SET NODE VERSION | ||
FROM node:18.17.1 | ||
|
||
#CONTAINER WORKING DIRECTORY | ||
WORKDIR /usr/src/app | ||
|
||
#COPY FILES INTO CONTANER AT /usr/src/app | ||
COPY . . | ||
|
||
#TYING TO EXPLICITLY COPY THE CLIENT FOLDER | ||
COPY ./client /usr/src/app/client | ||
|
||
#INSTALL ROOT PACKAGES | ||
RUN npm install | ||
|
||
#INSTAL CLIENT PACKAGES | ||
RUN cd client && npm install | ||
|
||
#EXPOSE THE WEBPACK-DEV-SERVER PORT | ||
EXPOSE 3000 | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
Thank you for your contribution to Code Hammers's repository! Before merging, please fill out this brief form. | ||
|
||
### Description | ||
|
||
(What does this PR do? What problem does it solve? What feature does it add? What is the impact of this change? What other PRs does this depend on? If this PR is a work in progress, please add the `WIP` label.) | ||
|
||
### Jira Task | ||
|
||
(**Replace this text** with a link to your Jira task link here, or N/A) | ||
|
||
### Testing Instructions | ||
|
||
_**Note:** this does not mean pasting in how to run the Jest tests. Let us know if there is a specific flow we need to follow to test the fuctionality on the site itself, or if there is a specific page you want to test, etc. This is not needed for most PRs._ | ||
|
||
### Checklist | ||
|
||
Please go through each item of this checklist carefully. | ||
|
||
- [x] (Example checked item. Don't add any spaces around the "x".) | ||
|
||
#### All Team Members | ||
|
||
- [ ] I added a descriptive title to this PR. | ||
- [ ] I filled out the **Description**, **Jira Task**, and **Testing Instructions** sections above. | ||
- [ ] I added or updated [Jest unit tests]for any changes to components, server-side controllers, etc. | ||
- [ ] I ran `npm run docker-test` in my local environment to check that this PR passes all unit tests. | ||
- [ ] I did a quick check to make sure my code changes follow the recomended style guide. | ||
|
||
### Additional Notes, Images, etc. | ||
|
||
(This is space for any additional information or attachments you'd like to add as part of this PR.) |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,9 @@ | ||
# Review and refactor error handling. | ||
# Review and refactor error handling. Needs to be more consistent. Need a guidelines section. | ||
|
||
# Review types (Do we need separate types? Will this cause issues later on?) | ||
|
||
# Add much more thorough edge case tetsing on test files. | ||
|
||
# Create a shared types environment for front and back. | ||
|
||
# Create User types for front end |
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
Oops, something went wrong.