Summary
In this chapter, we explored best practices and strategies we can use to prepare and run our application in a production environment. We started with database seeding and saw how we can seed the database to have the data required for the initial application setup. The database seeder we created always initializes the database with the required user roles for the API.
Next, we discussed how can we keep permissions in sync across multiple environments, and we created a helper function that will do this job for us. After that, we moved on to media and assets and configured Strapi to use Amazon S3 to save media files instead of saving them on the local hard drive.
Finally, we prepared our API to use the PostgreSQL database in production, and we also tested it out locally with the help of Docker.
In the next chapter, we will explore how to deploy our API to a production environment and we will discuss two deployment strategies: deployment to a software-as-a-service (SaaS...