shadrix

shadrix

Member Since 1 Year Ago

Experience Points
50,600
Total
Experience

4,400 experience to go until the next level!

In case you were wondering, you earn Laracasts experience when you:

  • Complete a lesson — 100pts
  • Create a forum thread — 50pts
  • Reply to a thread — 10pts
  • Leave a reply that is liked — 50pts
  • Receive a "Best Reply" award — 500pts
Lessons Completed
449
Lessons
Completed
Best Reply Awards
0
Best Reply
Awards
  • start-engines Created with Sketch.

    Start Your Engines

    Earned once you have completed your first Laracasts lesson.

  • first-thousand Created with Sketch.

    First Thousand

    Earned once you have earned your first 1000 experience points.

  • 1-year Created with Sketch.

    One Year Member

    Earned when you have been with Laracasts for 1 year.

  • 2-years Created with Sketch.

    Two Year Member

    Earned when you have been with Laracasts for 2 years.

  • 3-years Created with Sketch.

    Three Year Member

    Earned when you have been with Laracasts for 3 years.

  • 4-years Created with Sketch.

    Four Year Member

    Earned when you have been with Laracasts for 4 years.

  • 5-years Created with Sketch.

    Five Year Member

    Earned when you have been with Laracasts for 5 years.

  • school-session Created with Sketch.

    School In Session

    Earned when at least one Laracasts series has been fully completed.

  • welcome-newcomer Created with Sketch.

    Welcome To The Community

    Earned after your first post on the Laracasts forum.

  • full-time-student Created with Sketch.

    Full Time Learner

    Earned once 100 Laracasts lessons have been completed.

  • pay-it-forward Created with Sketch.

    Pay It Forward

    Earned once you receive your first "Best Reply" award on the Laracasts forum.

  • subscriber-token Created with Sketch.

    Subscriber

    Earned if you are a paying Laracasts subscriber.

  • lifer-token Created with Sketch.

    Lifer

    Earned if you have a lifetime subscription to Laracasts.

  • lara-evanghelist Created with Sketch.

    Laracasts Evangelist

    Earned if you share a link to Laracasts on social media. Please email [email protected] with your username and post URL to be awarded this badge.

  • chatty-cathy Created with Sketch.

    Chatty Cathy

    Earned once you have achieved 500 forum replies.

  • lara-veteran Created with Sketch.

    Laracasts Veteran

    Earned once your experience points passes 100,000.

  • 10k-strong Created with Sketch.

    Ten Thousand Strong

    Earned once your experience points hits 10,000.

  • lara-master Created with Sketch.

    Laracasts Master

    Earned once 1000 Laracasts lessons have been completed.

  • laracasts-tutor Created with Sketch.

    Laracasts Tutor

    Earned once your "Best Reply" award count is 100 or more.

  • laracasts-sensei Created with Sketch.

    Laracasts Sensei

    Earned once your experience points passes 1 million.

  • top-50 Created with Sketch.

    Top 50

    Earned once your experience points ranks in the top 50 of all Laracasts users.

Level 11
50,600 XP
Nov
04
1 week ago
Activity icon

Replied to How Would You Backup Valuable SQL-data?

@jove short and simple answer. Thanks!

Nov
03
1 week ago
Activity icon

Started a new Conversation How Would You Backup Valuable SQL-data?

Do you have any tips for me what I should do, when I have a server, that saves valuable information in MySQL (like transaction data)? Currently, I would try to install a SQL Replication sever. Does this mean, that I need to pay for an extra server, right?

What would you do in my case? Technically, to be save, I would need to backup all data for every second.

Oct
24
2 weeks ago
Activity icon

Replied to I'm Nervous That My App's Security Has Flaws. Asking For Feedback.

@primordial Actually, I'm wondering. Why is this the case? What are the bots trying to do? I added whois to my fail2ban and I constantly see big companies attacking me, like Microsoft et.c

Oct
19
3 weeks ago
Activity icon

Started a new Conversation How Do I Move My Images To S3 In Production And In Development Let It Stay Locally?

I have read this thread, however I'm still not really sure how to handle this.

Of course, I could set FILESYSTEM_DRIVER to s3, but this won't really work.

Let me explain:

If we upload a simple avatar file:

request()
        ->file('avatar')
        ->store('avatars', 'public')

The file is saved in the DB for example: avatars/R6ZGC9U0c22mKMcAADZbc8kJeU8soTvOuNFvnYgv.jpeg

This file is stored in the local public storage file. However, if we now want to change the default filesystem to S3, nothing is going to change obviously.

Now, this is going to be even harder, when we fetch the image via the assetmethod. Usually, I just need to write:

 public function getAvatarAttribute($avatar)
{
    return asset('storage/' . $avatar));
}

to get the avatar file (because of the symlink in the public folder).

What now? I obviously don't save a storage folder.

How would you handle this?

Oct
09
1 month ago
Activity icon

Replied to Help: Background Video Streaming, What To Use? (YouTube Is Not Allowed)

@tnorthcutt Here watch this in action. I would say this should not be a problem for users.

Vimeo is also an American company so it's a no go as well :(

How expensive would this video example be when I leave it on digitalocean? Let's say with 30k viewers per month?

Activity icon

Started a new Conversation Help: Background Video Streaming, What To Use? (YouTube Is Not Allowed)

In Germany / Europe we have this shitty policy privacy (GDPR) that you are not allowed to use YoutTube Videos in the background if the user didn't accept it. I could load the video on my server, but because I want to have the lowest traffic cost, where would you put the video?

Activity icon

Replied to GitLab CI: Do You Put Your MIX_keys Into .env.exampe?

I think you didn't understand my question or maybe I didn't understand your answer.

So let's go to: https://github.com/laravel/laravel/blob/master/.env.example

At the very bottom you will see:

MIX_PUSHER_APP_KEY="${PUSHER_APP_KEY}"
MIX_PUSHER_APP_CLUSTER="${PUSHER_APP_CLUSTER}"

How could you tell GitLab the PUSHER_APP_KEY when using it in a docker enviroment?

Oct
07
1 month ago
Activity icon

Started a new Conversation GitLab CI: Do You Put Your MIX_keys Into .env.exampe?

Hey :) so I read a lot about GitLab CI and how you can deploy your server. However, now I noticed that there might be a small problem. Wenn GitLab is running npm run production it compiles the code with the MIX_<variables>.

Normally, I would not put the API keys in .env.example, but in this case does it really matter, because you can read out the keys anyway by looking into the javascript code?

Oct
06
1 month ago
Activity icon

Started a new Conversation Phpunit Test Slow - On Local Machine 3 Minutes On GitLab-CI 44 Minutes

Do you have any tips on what I can do about this?

I have 745 tests that I am testing before deploying, however on GitLab-CI it takes ages to complete them. I run 3 workes at the time, but still.

I'm considering to rewrite every test so I don't need to call resfreshDatabase-Trait. But still that's tough... Any ideas?

How/when and where do you test your app?

Oct
05
1 month ago
Activity icon

Started a new Conversation On What Kind Of Computer Does GitLab CI Work?

That's not quite clear for me and I cannot find the answer. I'm using GitLab CI, however, the phpunit stage is soooo slow and I don't really why. (On my computer, 745 tests finish in 3.25 minutes on GitLab 35 Minutes...)

What are the specs of the GitLab CI computers/servers?

Sep
30
1 month ago
Activity icon

Started a new Conversation Would You Still Phpunit Test On The Server Before Deployment?

I'm currently reading this: https://docs.gitlab.com/ee/ci/examples/laravel_with_gitlab_and_envoy/index.html

And now I wonder, would you still test your code on the server via docker although your testing is fine locally on your computer?

When does it make sense?

Sep
29
1 month ago
Activity icon

Replied to Which Server Do You Take For Digital Ocean?

@snapey thanks for your reply. Interesting! Currently, I fixed this prolblem by installing Laravel locally and then via git clone bringing it to the server.

My question to you. Are you using swap for memory? Or is the 1gb of ram enough for your websites?

Sep
28
1 month ago
Activity icon

Started a new Conversation Which Server Do You Take For Digital Ocean?

So I'm starting to prep for the deployment of my website. However, I have the problem that the cheapest droplet (5$) is too weak for even install Laravel via composer...

I get the error:

proc_open(): fork failed - Cannot allocate memory

I could fix this by adding swap, however since the server are using SSD it's not recommended.

What kind of droplet are you currently using for a staging sever? and what kind for a production server that has low traffic? And what would you use for a page like Laracast?

Thank you :)

Jul
16
3 months ago
Jul
15
3 months ago
Activity icon

Started a new Conversation What Kind Of Browser/App Is This? (Showing Responsive Devices As A Browser)

I'm watching a Tailwind video and saw this:

image

Do you know what this could be?

Original source is from here: https://tailwindcss.com/course/responsive-design/

Jun
26
4 months ago
Activity icon

Commented on Go Go Gadget Tailwind

Ha nice. I'm first writing with the new comment feature :D

Jun
24
4 months ago
Activity icon

Replied to Why Does Laravel Notifications Table Use UUID Instead Of ID?

I like the question @thebigk . Just to add something for people who don't know it. If you are still using normal IDs, but you want to hide your information what @cronix is referring, you could use HashIds. It converts numbers like 347 into strings like “yr8”.

Jun
21
4 months ago
Activity icon

Replied to How To Avoid Interface Segregation In My Case? (SOLID)

@DRFRAKER - Thanks for your suggestion. But I cannot do that. Why? Because we cannot create a new instance. Internally we don't know what is "coming" to us.

Just to give a real-life example and unfortunately the long version.

 $invoice->create(new InvoiceFoodBuyer($event->order));
 $invoice->create(new InvoiceFoodSeller($event->order));

Invoice is created for Buyer and for Seller. InvoiceFoodBuyer implements A and B Interfaces.

Inside of $invoice->create

We have a function that creates PDFs.

 (new InvoicePDF($invoiceType))->createPdf();

$invoiceType should implement B interfaces,

However everything in $invoice->create() should implement A interfaces...

Jun
20
4 months ago
Activity icon

Started a new Conversation How To Avoid Interface Segregation In My Case? (SOLID)

Hey hey :)

I'm trying to use the SOLID-principles, however, I have a problem with Type-Hinting.

First, have a look at my code, but it is important to note: $a implements AInterface and BInterface.

public function create(AInterface $a): void
{
  ...
  $class = new SuperClass($a); //---> here is the problem, it wants BInterface, not AInterface
  ..
}

For the first create method, we just care about the AInterface-Methods

Inside of SuperClass we just care about the BInterface-Methods

However, my intelephense writes, that the type is wrong.

Currently, I just merged AInterface and BInterface together, but Interface Segregation states that we should not force to use a method when not used.

How would you do this?

I've looked it up and some solutions are using a third interface, extending AInterface and BInterface.