deployment-docs

Flask and PostgreSQL (MS3) : Build & deployment

Congratulations, you are nearly there! Now it is time to deploy the project.


These are the final steps to deployment. First, the build is initiated. Then the build and deployment processes are carried out. Finally, the application is deployed and ready for public viewing.

The build process time varies depending on the complexity of the project, the currently available resources from Render.com and a number of other factors.

The build log is available to watch if desired, but this is the normal time to “grab a cuppa”.

The build should complete with a “Build successful 🎉” message. The build then moves on to “Deploying…” and should complete with a “Starting service …” message.

Once deployed, go forth and test! Don’t forget, development does not stop at deployment. Make sure everything works as expected, configuration can be different in development and production versions of software so being thorough is always advised.

Process

  1. Click “Create Web Service

    create web service button

  2. Wait for deployment…

    Watch the console for some activity, deployment can take up to 15 minutes to complete

    a build log with lines indicating the start of a build

  3. Deployment completed!

    When the build and deployment have completed, the console will look something like this:

    a build log with a green success message at the bottom

    It is safe to ignore the red warning, this is due to the use of the python app.py command.

    If the build process does not appear to complete, please refer to our troubleshooting guide.

  4. Open the deployed site via the link below the WEB SERVICE name.

    an anchor element displayed below the name of the web service with a copy to clipboard icon next to it

    The URL can be copied to a clipboard using the provided copy icon. Handy for adding to a README or sharing with a professional network.

  5. Enjoy your newly deployed web service!!

    an example of a deployed site in a browser

If for any reason this process has not succeeded, please refer to our troubleshooting guide.

Up Next

That's it! The project is now deployed to Render.com and ready to be viewed by the public. Congratulations, you have successfully migrated your project! 🎉

Note: To ensure that the development version of your project is also up to date, remember to update the DATABASE_URL variable in your env.py in Gitpod too. If you forget, you'll get an error message that says something like FATAL: role "randomletters" is not permitted to log in. This is because the original Heroku Postgres database no longer exists.