Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
62 changes: 62 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,65 @@
name: Deploy to EC2 (Production)

on:
push:
branches: [ main ]

jobs:
deploy:
runs-on: ubuntu-latest
environment: production

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Create .env file from secrets
run: |
cat > .env <<EOF
DATABASE_URL=postgresql://${{ secrets.DB_USER }}:${{ secrets.DB_PASSWORD }}@${{ secrets.DB_HOST }}:${{ secrets.DB_PORT }}/${{ secrets.DB_NAME }}
AWS_ACCESS_KEY_ID=${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY=${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_REGION=${{ secrets.AWS_REGION }}
AWS_BUCKET_NAME=${{ secrets.AWS_BUCKET_NAME }}
NEXT_PUBLIC_BASE_URL=${{ secrets.NEXT_PUBLIC_BASE_URL || '' }}
EOF
echo ".env created (values masked in logs)."

- name: Start SSH agent and add private key
uses: webfactory/ssh-agent@v0.8.1
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}

- name: Ensure remote dir exists
run: |
ssh -o StrictHostKeyChecking=no ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST }} "mkdir -p ${{ secrets.REMOTE_APP_DIR }}"

- name: Rsync files to remote (excluding node_modules .git)
run: |
rsync -azh --delete --exclude 'node_modules' --exclude '.git' --exclude '.env.local' -e "ssh -o StrictHostKeyChecking=no" ./ ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST }}:${{ secrets.REMOTE_APP_DIR }}

- name: Copy generated .env to remote
run: |
scp -o StrictHostKeyChecking=no .env ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST }}:${{ secrets.REMOTE_APP_DIR }}/.env

- name: Install deps, build and restart (remote)
run: |
ssh -o StrictHostKeyChecking=no ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST }} <<'EOF'
cd ${{ secrets.REMOTE_APP_DIR }} || exit 1
# instalar dependências (omit dev) e build
npm ci --omit=dev || npm install --omit=dev
npm run build || echo "build step finished"
# reiniciar via PM2 (ajuste se seu ecosytem for diferente)
if command -v pm2 > /dev/null; then
if [ -f ecosystem.config.js ]; then
pm2 reload ecosystem.config.js || pm2 start ecosystem.config.js
else
pm2 restart all || pm2 start npm --name "aiarchives" -- start
fi
fi
EOF


name: Deploy AI Archives to EC2

on:
Expand Down
60 changes: 24 additions & 36 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,36 +1,24 @@
This is a [Next.js](https://nextjs.org) project bootstrapped with [`create-next-app`](https://nextjs.org/docs/app/api-reference/cli/create-next-app).

## Getting Started

First, run the development server:

```bash
npm run dev
# or
yarn dev
# or
pnpm dev
# or
bun dev
```

Open [http://localhost:3000](http://localhost:3000) with your browser to see the result.

You can start editing the page by modifying `app/page.tsx`. The page auto-updates as you edit the file.

This project uses [`next/font`](https://nextjs.org/docs/app/building-your-application/optimizing/fonts) to automatically optimize and load [Geist](https://vercel.com/font), a new font family for Vercel.

## Learn More

To learn more about Next.js, take a look at the following resources:

- [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js features and API.
- [Learn Next.js](https://nextjs.org/learn) - an interactive Next.js tutorial.

You can check out [the Next.js GitHub repository](https://github.com/vercel/next.js) - your feedback and contributions are welcome!

## Deploy on Vercel

The easiest way to deploy your Next.js app is to use the [Vercel Platform](https://vercel.com/new?utm_medium=default-template&filter=next.js&utm_source=create-next-app&utm_campaign=create-next-app-readme) from the creators of Next.js.

Check out our [Next.js deployment documentation](https://nextjs.org/docs/app/building-your-application/deploying) for more details.
💻 Software Engineering Internship (TechX Labs, Inc.)
📅 Duration: September 08, 2025 – November 07, 2025
🖥️ Location: Remote (Boston, MA)

📝 Internship Overview
Participated in the Software Engineering Intern program at TechX Labs, gaining hands-on experience with real-world projects focused on large-scale web architecture and distributed systems. Developed technical skills under the guidance of experienced engineers while contributing to enterprise-grade solutions.

⚙️ Key Activities
🧪 Assisted in building and optimizing cloud-native infrastructure
🕵️‍♂️ Contributed to high-availability system design and performance improvements
🔍 Applied security best practices and worked with monitoring/logging systems
🧬 Collaborated with mentors and peers on real-world engineering projects
🛠️ Gained practical experience with technologies such as VMSS, load balancers, and Redis caching

💡 Skills Demonstrated
🛡️ Cloud and Distributed Systems
🚨 Performance Optimization & High-Availability Design
📊 Enterprise-Grade Software Development
🌐 Security Best Practices Implementation
📁 Technical Documentation & Collaboration
🧠 Critical Thinking in Software Engineering

🏁 Conclusion
This internship provided me with valuable practical experience in software engineering, particularly in large-scale web architecture and distributed systems. It strengthened my technical and problem-solving skills while giving me confidence to contribute effectively to professional engineering teams. I look forward to applying these skills in future projects and advancing my knowledge in software development and cloud technologies.