API Rest Microservice - Van Test
This README sets the use of this application to deploy the microservice API Rest.
- Management of Van vehicle data on a database. Search, Create, Update and Delete Van data on database.
- Version: v.1.1.A10.5
- API Microservice Documentation
1.- Go to the GitHub remote repository: GitHub remote microservice repository and validate the steps of this Readme deployment documentation/API code and general data.
2.- On your CLI (Command Line Interface) tool, clone the remote repository from the 1st step using the version control system Git command on your local path repository/directory.
3.- Verify all code/data from GitHub remote repository are on the local repo.
4.- Copy all API code to a new local path/directory, only to deploy the application you need: auth_controller,
constants, db_controller, logger_controller, logs, model, static, templates directories and then, copy
the __init__.py, app.py, Procfile, requirements.txt, wsgi.py files.
5.- Set on the new path directory established on 4 step.
6.- Install the Heroku CLI Platform as a Service following the instructions depending of your operating system.
7.- If you do not have an Heroku account, Create your own
8.- Once that is out of the way, on the Heroku web console dashboard, select New -> Create new app. Once the application is created on Heroku, we're ready to deploy it online.
9.- Execute on your command line tool in your new path app the git init . command to initialize the local repository.
10.- Execute on your command line tool the git add -A command to add the app code to the local Git repository.
11.- Execute on your command line tool the git commit -m "message_to_this_commit" command to commit the changes on
code to the local Git repository.
12.- If you haven't already, log in to your Heroku account and follow the prompts to create a new SSH public key.
Then, execute the heroku login -i command and set your username and password registered on the dashboard.
13.- Execute the heroku login command on your command line tool.
14.- Execute the heroku git:remote -a {your-project-name} command replacing {your-project-name} to your
Heroku and repository name.
15.- Execute the git push heroku master command.
16.- Testing the API. In the log that has been shown in the console you will find a link for your application, this link can also be found under the Settings tab, in the Domains and certificates section Heroku console web dashboard.
17.- If you wanna change the API code, make the change need to execute the 10 to 15 steps.
18.- If you wanna verify the LOG of the API, execute heroku logs --tail command.
1.- Install the Heroku CLI Platform as a Service following the instructions
2.- If you haven't already, log in to your Heroku account and follow the prompts to create a new SSH public key.
$ heroku login
3.- Clone the repository:
3.1. Use Git to clone van-api-microservice's source code to your local machine. First execute command line:
`$ heroku git:clone -a van-api-microservice`.
3.2.- Then, by command line, access to your local repository using: `$ cd van-api-microservice`
4.- Deploy your changes. Make some changes to the code you just cloned and deploy them to Heroku using Git.
4.1.- `$ git add .`
4.2.- `$ git commit -am "make it better"`
4.3.- `$ git push heroku master`