/portfolio

A dynamic, full-stack portfolio web application built with Elixir and Phoenix. Features project showcase, admin dashboard, contact form, and easy deployment on Fly.io.

Primary LanguageCSS

Portfolio ๐Ÿš€

Introduction ๐Ÿ‘‹

Welcome to my portfolio project! This is a dynamic, full-stack web application built using Elixir and Phoenix. It showcases my projects, skills, and provides a platform for visitors to get in touch with me. The application is designed to be easily customizable and deployable, making it an ideal starting point for developers looking to create their own online portfolio. You can see it in action at Tech Rationalist. Please note that this is a work in progress project, and I'm continuously improving and adding new features. ๐Ÿ’ผโœจ๐Ÿšง

Features ๐ŸŒŸ

  • Project Showcase: Display and manage your projects with ease. ๐Ÿ“
  • Admin Dashboard: Secure admin interface for content management using the live_admin package. ๐Ÿ”
  • Contact Form: Allow visitors to send you messages directly through the site. ๐Ÿ“ง
  • Markdown Support: Write project descriptions using Markdown for rich formatting. โœ๏ธ
  • Live Updates: Utilizes Phoenix LiveView for real-time interactions. โšก
  • Easy Deployment: Configured for quick deployment on Fly.io. ๐Ÿš€
  • UI Components: Built with Tailwind CSS (included with Phoenix) and daisyUI for a modern and clean UI. ๐ŸŽจ

Requirements ๐Ÿ“‹

Ensure you have the following installed:

Phoenix (v1.7+) will be installed as a dependency when you run mix setup.

Getting Started ๐Ÿ

To start your Phoenix server:

  • Install Node.js dependencies with npm install in the assets directory. This is required to build Tailwind CSS and any UI libraries. ๐Ÿ“ฆ
  • Run mix setup to install and setup dependencies ๐Ÿ› ๏ธ
  • Start Phoenix endpoint with mix phx.server or inside IEx with iex -S mix phx.server ๐Ÿš€

Now you can visit localhost:4000 from your browser. ๐ŸŒ

Admin Functionality ๐Ÿ‘จโ€๐Ÿ’ผ

This application includes an admin interface for managing content and site administration. The admin functionality allows authorized users to:

  • Manage projects displayed on the portfolio ๐Ÿ“Š
  • Handle contact messages received through the site ๐Ÿ“ฌ
  • Perform other administrative tasks as needed ๐Ÿ”ง

Admin access is restricted to authorized personnel only, ensuring the security and integrity of your portfolio content. ๐Ÿ”’

Admin Setup ๐Ÿ› ๏ธ

This application uses a custom admin authentication system. Admin registration is not available through the web interface and should be done via the Elixir interactive shell (IEx) for security reasons. ๐Ÿ”

To create an admin account:

  1. Start an IEx session with your application:

    iex -S mix

    For Livebook users:

    a. Start Livebook by running:

    livebook server

    b. In a separate terminal, start an IEx session with a distributed node:

    iex --name your_app@127.0.0.1 --cookie your_secret_cookie -S mix

    c. In Livebook, connect to this node using the same name and cookie.

    Note: Replace "your_app@127.0.0.1" with a unique name for your application node, and "your_secret_cookie" with a secure, random string. ๐Ÿช

  2. Create a new admin account:

    Portfolio.Backoffice.register_admin(%{email: "admin@example.com", password: "your_secure_password"})

    Replace "admin@example.com" and "your_secure_password" with your desired email and password. ๐Ÿ“ง๐Ÿ”‘

  3. Admin login is available at /admins/log_in ๐Ÿšช

  4. After logging in, you can access the admin dashboard at /admin ๐Ÿ–ฅ๏ธ

Note: Ensure you create at least one admin account to manage the site. Keep the admin credentials secure and do not share them with unauthorized individuals. ๐Ÿ”’

Deployment ๐Ÿš€

This project is configured for deployment on Fly.io. To deploy:

  1. Install the Fly CLI: https://fly.io/docs/hands-on/install-flyctl/ ๐Ÿ’ป
  2. Run fly launch in the project directory. This will create a fly.toml file customized for your deployment. ๐Ÿ›ซ
  3. Deploy your application with fly deploy ๐Ÿš€

Note: The fly.toml file is gitignored as it contains deployment-specific details. ๐Ÿ™ˆ

Custom Domain Configuration ๐ŸŒ

When deploying with a custom domain, ensure that the PHX_HOST environment variable is set correctly in your fly.toml file.

Upcoming Features ๐Ÿš€

I am working on exciting new features to enhance this portfolio project:

Skills Page ๐Ÿ› ๏ธ

  • Dedicated page to showcase technical skills and expertise
  • Visual representation of skill proficiency levels

Blog Support ๐Ÿ“

  • Integrated blogging platform with Markdown support
  • Tagging and categorization of blog posts

Stay tuned for these updates! ๐Ÿ’กโœจ