Skip to content
Snippets Groups Projects
Commit 9cb6b19d authored by Rysev, Gleb (UG - SISC)'s avatar Rysev, Gleb (UG - SISC)
Browse files

Merge branch 'Development'

parents 255aa448 9308f33a
No related branches found
No related tags found
No related merge requests found
Pipeline #31157 failed
...@@ -5,8 +5,7 @@ RUN curl -sL https://deb.nodesource.com/setup_12.x | bash - \ ...@@ -5,8 +5,7 @@ RUN curl -sL https://deb.nodesource.com/setup_12.x | bash - \
nodejs \ nodejs \
&& apt-get upgrade -qq \ && apt-get upgrade -qq \
&& apt-get clean \ && apt-get clean \
&& rm -rf /var/lib/apt/lists/* \ && rm -rf /var/lib/apt/lists/*
&& npm install -g yarn@1
# throw errors if Gemfile has been modified since Gemfile.lock # throw errors if Gemfile has been modified since Gemfile.lock
# RUN bundle config --global frozen 1 # RUN bundle config --global frozen 1
...@@ -14,6 +13,10 @@ RUN curl -sL https://deb.nodesource.com/setup_12.x | bash - \ ...@@ -14,6 +13,10 @@ RUN curl -sL https://deb.nodesource.com/setup_12.x | bash - \
RUN mkdir -p /usr/src/app RUN mkdir -p /usr/src/app
WORKDIR /usr/src/app WORKDIR /usr/src/app
RUN curl -sL https://deb.nodesource.com/setup_12.x | bash -
RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add
RUN echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list
RUN apt-get update && apt-get install -y nodejs --no-install-recommends && rm -rf /var/lib/apt/lists/* RUN apt-get update && apt-get install -y nodejs --no-install-recommends && rm -rf /var/lib/apt/lists/*
RUN apt-get update && apt-get install -y default-mysql-client postgresql-client sqlite3 yarn --no-install-recommends && rm -rf /var/lib/apt/lists/* RUN apt-get update && apt-get install -y default-mysql-client postgresql-client sqlite3 yarn --no-install-recommends && rm -rf /var/lib/apt/lists/*
#RUN gem install bundler -v 1.17.3 #RUN gem install bundler -v 1.17.3
...@@ -25,7 +28,10 @@ COPY Gemfile.lock /usr/src/app/ ...@@ -25,7 +28,10 @@ COPY Gemfile.lock /usr/src/app/
RUN bundle install RUN bundle install
RUN bundle exec rails assets:precompile RUN bundle exec rails assets:precompile
COPY . /usr/src/app COPY package.json /usr/src/app/
RUN npm install
COPY . /usr/src/app/
# COPY entrypoint.sh /usr/bin/ # COPY entrypoint.sh /usr/bin/
# RUN chmod +x /usr/bin/entrypoint.sh # RUN chmod +x /usr/bin/entrypoint.sh
......
# Group 10 Habit Tracker Web App # Group 10 Habit Tracker Web App
### How to run it? ### How to run it?
#### Docker:
1. Make sure docker is installed 1. Make sure docker is installed
2. Clone the repository 2. Clone the repository
3. cd into root repository 3. cd into root repository
...@@ -9,3 +10,9 @@ ...@@ -9,3 +10,9 @@
[![docker-compose up](https://gitlab.eps.surrey.ac.uk/group-10/habit-tracker-web-app/-/wikis/uploads/1b0c612ebe165e45fe7f0c071e55bfe3/image.png "docker-compose up")](https://gitlab.eps.surrey.ac.uk/group-10/habit-tracker-web-app/-/wikis/uploads/1b0c612ebe165e45fe7f0c071e55bfe3/image.png "docker-compose up") [![docker-compose up](https://gitlab.eps.surrey.ac.uk/group-10/habit-tracker-web-app/-/wikis/uploads/1b0c612ebe165e45fe7f0c071e55bfe3/image.png "docker-compose up")](https://gitlab.eps.surrey.ac.uk/group-10/habit-tracker-web-app/-/wikis/uploads/1b0c612ebe165e45fe7f0c071e55bfe3/image.png "docker-compose up")
6. Access the website on localhost:3000 or 127.0.0.1:3000. 6. Access the website on localhost:3000 or 127.0.0.1:3000.
7. For some machines (especially when using Windows) site might be running on another ip, to find it run `docker-machine ip default` 7. For some machines (especially when using Windows) site might be running on another ip, to find it run `docker-machine ip default`
NOTE: This process was tested on Docker for Windows and might change depending on your platform.
#### Alternatively (rails server):
Run as normal rails application with `bundle install` and `rails server`
#### Alternatively (visit deployed version):
[Use this link to access our site on Heroku](hthttps://group-ten-habits-deployment.herokuapp.com/#_=_tp:// "Use this link to access our site on Heroku")
Source diff could not be displayed: it is too large. Options to address this: view the blob.
{ {
"name": "Group10HabitTracker", "name": "Group10HabitTracker",
"private": true, "private": true,
"scripts": {
"start": "webpack-dev-server --host 0.0.0.0 --inline --content-base ."
},
"dependencies": { "dependencies": {
"@babel/preset-react": "^7.12.13", "@babel/preset-react": "^7.12.13",
"@fontsource/roboto": "^4.2.2", "@fontsource/roboto": "^4.2.2",
...@@ -14,7 +17,7 @@ ...@@ -14,7 +17,7 @@
"prop-types": "^15.7.2", "prop-types": "^15.7.2",
"react": "^17.0.1", "react": "^17.0.1",
"react-dom": "^17.0.1", "react-dom": "^17.0.1",
"webpack": "^4.4.0", "webpack": "^4.46.0",
"webpack-dev-server": "^3.11.2" "webpack-dev-server": "^3.11.2"
}, },
"devDependencies": { "devDependencies": {
......
Source diff could not be displayed: it is too large. Options to address this: view the blob.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment