𝗖𝗹𝗼𝘂𝗱 𝗔𝗿𝗰𝗵𝗶𝘁𝗲𝗰𝘁𝘂𝗿𝗲 𝗮𝗻𝗱 𝗦𝗲𝗰𝘂𝗿𝗶𝘁𝘆: 𝗧𝗵𝗲 𝗡𝗲𝘅𝘁 𝗟𝗲𝘃𝗲𝗹 𝗳𝗼𝗿 𝗗𝗲𝘃𝗲𝗹𝗼𝗽𝗲𝗿𝘀
Your web application works on your local machine. You think the job is done. It is not.
You must decide where your app lives. You must decide how to protect it. You must decide what happens when thousands of people use it at the same time.
Moving to the cloud requires more than just uploading code. You need to understand architecture and security.
PaaS (Platform as a Service) is a great starting point for developers. With PaaS, the cloud provider manages servers, operating systems, and networking. You focus on your code and user experience.
Top PaaS options include:
• AWS App Runner: Great for containerized web apps. It handles deployment and scaling. • Azure App Service: Perfect if you use Microsoft tools like GitHub Actions or Azure DevOps. • Google Cloud Run: Excellent for serverless containers. It can scale to zero to save costs when no one is using it.
Cloud security is your responsibility. The provider gives you tools, but you must use them correctly.
Follow these security rules:
- Use the principle of least privilege. Give users and services only the permissions they need. Use IAM in AWS, Microsoft Entra ID in Azure, or Cloud IAM in Google Cloud.
- Never hardcode passwords. Using const password = "123" in your code is dangerous.
- Use environment variables instead. Use process.env.DB_PASSWORD in your code.
- Always add your .env file to .gitignore.
- Set your real secrets in the cloud provider dashboard, not in your repository.
Think about data sovereignty. You must know where your data lives and which laws apply to it. If you have European users, you must follow GDPR rules.
Prepare for traffic spikes. If an influencer shares your link, your server might crash. You can prevent this with scaling:
• Vertical Scaling: Make your machine more powerful with more CPU or RAM. • Horizontal Scaling: Create more instances of your app and use a load balancer to spread the traffic.
Always ensure your site uses HTTPS. This keeps communication encrypted and safe.
How to practice:
- Create a repository for a simple web app.
- Ensure no sensitive data is in your code.
- Use Vercel or Netlify to deploy it.
- Verify that your site uses HTTPS.
Source: https://dev.to/xinlin25/arquitectura-y-seguridad-en-la-nube-el-proximo-nivel-del-desarrollador-1bnd