Skip to content

nebur395/Anisclo

Repository files navigation

Anisclo

Build Status codecov

Start using this App!

In order to run this project you have to have installed node.js and npm. Once you have them, follow these steps:

  1. Clone this repo: git clone https://github.com/nebur395/Anisclo
  2. Open a terminal on the root folder of this project.
  3. Run the command npm install. This must be done the first time only, in order to install the dependencies of the project.
  4. Use the following command to start mongod: sudo service mongod start
  5. Get the necessary API keys in this section.
  6. To add an administrator user, please run the following command: node initialize.js. You will be able to log-in with this user with the email 'master@admin.com' and the password 'pass'.
  7. Run npm start in order to launch two instances of the server on port 8080 (HTTP) and 8443 (HTTPS). Alternatively, you can also use node server.js.
  8. Open a web browser (Preferably Mozilla Firefox or Chrome >55.X) and type http://localhost:8080 for the HTTP page, or https://localhost:8443 for the HTTPS equivalent.

API keys

To ensure a correct operation of the application you have to get the following API keys:

Google Map KEY

  1. Go to the file /public/app.js and put your api key in the 7 line.

Google's reCaptcha KEY

  1. Go to the files /public/templates/retrievePassword.html (28 line) and /public/templates/signUp.html (39 line), and put your PUBLIC api key.
  2. Go to the files /routes/user/user.js (107 line) and /routes/user/user.js (515 line), and put your PRIVATE api key.

Google Login KEY

  1. Go to the file /public/app.js and place your Google client api key in line 37.
  2. Go to the file routes/user/user.js and place your secret client api key in line 218.

In order to be able to send emails when a user signs up, confirms it's registration or wants to retrieve a password, follow these steps:

  1. Go to the file routes/user/user.js and follow the comments on the lines 1251, 1253 and 1254 to set up the SMTP service.
  2. In that same file, go to lines 158, 553 and 628 and change the email on that lines with the one you used on the SMTP service setup.

In order to be able to send emails with a created route:

  1. Go to the file routes/poi/route.js and follow the comments on the lines 491, 493 and 494 to set up the SMTP service.
  2. In that same file, go to line 344 and change the email on that line with the one you used on the SMTP service setup.

In order to have a look at the project's API you have to follow these steps:

  1. Run npm start in order to launch the application.
  2. JSON: Open a web browser and type http://localhost:8080/swagger.json to display the application's API in a JSON.
  3. UI Web: Open a web browser and type http://localhost:8080/api-docs/ to display the application's API in a UI web.

Test

In order to run the Protractor tests of this project you have to follow these steps:

  1. Check that Protractor is working by running node_modules/protractor/bin/protractor --version.
  2. Now start up the Selenium Server: node_modules/protractor/bin/webdriver-manager start. This will output a bunch of info logs. You can see information about the status of the server at http://localhost:4444/wd/hub.
  3. Finally, execute node_modules/protractor/bin/protractor test/protractor/conf.js.

In order to run the Mocha tests of this project you only have to execute the following command: npm test

EditorConfig

EditorConfig helps developers maintain consistent coding styles between different editors and IDEs. It is a file format for defining coding styles and a collection of text editor plugins that enable editors to read the file format and adhere to defined styles. You need to create a .editorconfig file in which you define the coding style rules. It is similar to the format accepted by gitignore.

IDEs supported by EditorConfig

These editors come bundled with native support for EditorConfig. Everything should just work: BBEdit, Builder, CLion, GitHub, Gogs, IntelliJIDEA, RubyMine, SourceLair, TortoiseGit, WebStorm.

IDEs not supported by EditorConfig file

To use EditorConfig with one of these editors, you will need to install a plugin: AppCode, Atom, Brackets, Coda, Code::Blocks, Eclipse, Emacs, Geany, Gedit, Jedit, Komodo, NetBeans, NotePadd++, PhpStorm, PyCharm, Sublime Text, Textadept, textmate, Vim, Visual Studio, Visual Studio Code, Xcode

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •