Giter VIP home page Giter VIP logo

landing-laravel's Introduction

Landing Laravel - A Links Landing Laravel Application

This application creates a links landing page where you can share relevant links to an audience. Links are initially imported from a links.yml file in the root of the application, and can be managed via Artisan commands (in the console / command-line).

Deploy to DO button

Landing Laravel - application screenshot

This application was developed in the following tutorial series: How To Build a Links Landing Application in PHP with Laravel and Docker Compose.

Managing Links

Links are initially imported from a links.yml file at the root of the repository. The seeds are only imported when the database is empty, so to not duplicate your links.

Link management is done via Artisan commands:

php artisan link:list
php artisan link:create
php artisan link:delete [LINK_ID]

Deploying via DO Deploy Button

If you want to try DigitalOcean's App Platform with this application, you may want to use the Deploy to DigitalOcean button at the top of this README. This will give you less customization options, but you can still manage your links via the console, on the App Platform dashboard.

Development Workflow with Docker Compose

The application includes a Docker Compose setup that you can use for development. Please follow the linked tutorial series for more information about how to set up Docker and Docker Compose.

It's recommended that you fork this repository to your own Github account. Then, clone your forked repository so that you can make changes to the application.

To bring the environment up:

docker-compose up -d

Running Composer:

docker-compose exec app composer install

Setting up App Key:

docker-compose exec app artisan key:generate

Running Migrations and Seeds:

docker-compose exec app artisan migrate --seed

Then you should be able to access the application on localhost:8080.

Change the links.yml file to change the links that get seeded into the database by default, when the application is deployed.

To manage links, use artisan:

docker-compose exec app artisan link:list

This will list all links in the database. To add a new link, use link:create, and link:delete LINK_ID to delete links.

Deploying to App Platform via doctl

To deploy your customized version of this application to DigitalOcean's App Platform, you can use doctl with the included App Spec file. First, edit the .do/deploy.template.yml file to change the github.repo entries to your own forked repository URL. You may also want to change the name of the application. Then, run doctl:

doctl apps create --spec .do/deploy.template.yaml

Then go to your App Platform dashboard to follow the build logs.

You can find more details on how to use doctl and the App Spec file in this post.


Eloquent doesn’t alter database structures, handling only data itself. Eloquent models are usually lean, with class properties automatically inferred from the model’s table structure.

Structural database operations are typically handled in Laravel via database migrations.

  • Migrations allow developers to programmatically define structural changes to the database, such as creating, modifying, and deleting tables.

docker-compose exec app php artisan make:migration create_link_list_table will generate a new file under the database/migrations directory in your Laravel application,That file contains generic code that you’ll modify to set up the lists table.

landing-laravel's People

Contributors

machiobrian avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.