noeldiaz

Instruction and Research Services Administrator at Purdue University

Hire Me

Experience

49,095

34 Best Reply Awards

  • Member Since 4 Years Ago
  • 597 Lessons Completed
  • 0 Favorites

9th June, 2016

noeldiaz left a reply on The Meaning Of This Line In Forge.sh • 1 year ago

@awwang10 This is so that things like "apt" and other network subsystems use IPV4 over IPV6 for communications. In fact, on some configurations, without that setting the update service hangs for a while in order to resolve the AAAA records first. I just had to manually change that on a non-forge server recently. You can read more about it here: [https://community.rackspace.com/products/f/25/t/5110].

13th May, 2016

noeldiaz left a reply on Valet 1.1.9 • 1 year ago

@simondavies I've just gotten used to doing "valet uninstall" and then install again on each version upgrade just to be sure. Doing that I have not encountered any errors yet.

noeldiaz left a reply on Subdomains With Laravel Valet • 1 year ago

@barbarouspony On another thread this was asked and I suggested an idea that I believe worked for the person that was asking. Since Valet relies on directories to resolve the domains, I suggested that the person create a symbolic link to the directory with their installation, and that they name this linked directory the subdomain they wanted. So like if you application is in "domain.dev" make a symlink and name it "subdomain.domain.dev" with something like:

ln -s domain.dev subdomain.domain.dev

That will make valet find your subdomain. Supposedly this worked for the user that needed it. Now, since the latests versions of Valet use Caddy server, maybe they will be able to find a way to make this simpler? I think it provides more flexibility. But for now this seems to work.

9th May, 2016

noeldiaz left a reply on Valet V1.1.2 Update: Just Keep Getting The 'It Works' • 1 year ago

@simondavies Oh I see, you mean it is seeing another web server landing page. I think the "It Works" one is from Nginx. So it wouldn't be valet at all. Do you still have a VM running somewhere? Maybe Homestead? Check your VirtualBox GUI too.

noeldiaz left a reply on Valet V1.1.2 Update: Just Keep Getting The 'It Works' • 1 year ago

@simondavies try the 1.1.3 one that just released. FYI, what I have been doing is doing a uninstall and a install on each major update. Just in case they keep making changes to the underlying driver. So far nothing has broken for me on all my sites.

7th May, 2016

noeldiaz left a reply on Valet Sub-domain • 1 year ago

@danzar got an untested idea. What is you made a linked folder for one of the domains to the actual folder with your app? Since valet looks for directories, that might make it work with both names. So like if the app is project.dev run this to make a linked dir next to it:

ln -s project test.project

Not sure if it would work but give it a try.

6th May, 2016

noeldiaz left a reply on Valet Considerations: To Use Or Not To Use • 1 year ago

@renedekat Oh trust me, I know. Been working doing tech support for many years and still the daily struggle it real. :)

noeldiaz left a reply on Valet Considerations: To Use Or Not To Use • 1 year ago

@renedekat It actually mentions most of that on it's installation page. Sure, it won't ensure 100% compatibility in your environment. And yes, it will require your to run local versions of other software (database, redis, etc) that might not match your production stuff. But for quick development it works. I've been using artisan serve for when I get started on projects. But yes, I do final tests and checks on either a VM that mimics production or one of my staging servers. That is the only way to be sure things will go smoothly.

But for someone getting started, this is great. I already had all the pieces (php, dnsmask, db) but this packages it in a nice bundle. Especially for my non-laravel projects. Working today on taking a stab at a driver for Drupal for example.

So I agree with you. There are things to consider and keep in mind. But there is no reason why you can't use this and then serve the same sites from Homestead. That is what I will be doing.

noeldiaz left a reply on Stop Laravel Valet From Automatically Starting? • 1 year ago

@jimmycook looks like your only option so far is to uninstall it or stop it after boot. But you know, on my machine it is only using around 6mb of memory. Heck, my weather widget uses much more than that. I don't see a problem keeping it running all the time. Now, I do stop and start the DB when I need it. Especially since I don't need that or Redis on all projects. Sqlite works great for just testing.

noeldiaz left a reply on I Am Unable To Use Image::make() • 1 year ago

@nightmare is this running from inside a VM? Maybe the script sees itself differently. 8000 is the port to access it from the outside. Try localhost again but remove the port declaration and see if it works with just the regular port 80 maybe? I would try that first.

noeldiaz left a reply on Is Laravel Valet Just For Mac? • 1 year ago

@Mehran keep an eye on this PR (https://github.com/laravel/valet/pull/9). They almost got everything needed to run it on Ubuntu/Debian distributions.

5th May, 2016

noeldiaz left a reply on Laravel Valet • 1 year ago

@lstables I just had it running with Homestead at the same time to transfer my DB contents from Homestead to a locally installed MariaDB. So you can run them both. But maybe entries on your hosts file are conflicting? Especially if you named them the same?

noeldiaz left a reply on Laravel Valet • 1 year ago

@adeptinkandpixel the config file should not be under root. Did you run it with sudo? The composer part or the "install" part? Everything should end up under your user directory "mmccarthy".

noeldiaz left a reply on Laravel Valet • 1 year ago

@christopher If you don't want maria running all the time, instead of the brew services you can do:

mysql.server start
and 
mysql.server stop

You can see all the options with:

brew info mariadb

Same commands if you install Mysql instead of MariaDB too.

noeldiaz left a reply on Laravel Valet • 1 year ago

I've used this setup for quite a while now, just with a manual setup of php, dnsmaq, and database. This seems like a nice wrapper around everything. Now, I have tried to replicate the environment on windows, since setting up homestead there is always a pain compared to osx/linux. I had it working a while back using AcrylicDNS (http://mayakron.altervista.org/wikibase/show.php?id=AcrylicHome) but I don't have that windows machine anymore.

Now sure, this is not a reproduction of the "real" environment when the app going into production. I'll still keep Homestead around for that final check. But during the heavy development part of my apps this is good enough to get going fast and be able to switch projects easily. Can't complain about the fact that the app renders in a fraction of the time on each load too.

Plus inserting/updating many thousands of records on the database is way faster when it is running natively on the host! Had some problems since some of my databases are huge.

noeldiaz left a reply on How Does The Spark Updater Work ? • 1 year ago

@virajkhatavkar Ah I see. Well, you can look at the code for that too under the "spark" folder in your installation. I see under "src\Console\Commands\UpdateCommand.php" the steps it takes when you execute it. Looks like it does basically the same as the installer: downloads the new zip version, prepares it, updates the views, and then runs any other update commands it needs. It is all nicely split in separate files you you can step through it and see what it does.

4th May, 2016

noeldiaz left a reply on Does Laravel-ide-helper Not Support Redis? • 1 year ago

@Spec if you figure it out reply back. I'll do the same.

noeldiaz left a reply on Does Laravel-ide-helper Not Support Redis? • 1 year ago

@Spec I see what you are saying. And I see that calling it like that works. But the autocomplete on storm is not picking it up that way. Same here. Not sure why. Even tried rebuilding the meta and ide files and still nothing.

noeldiaz left a reply on Does Laravel-ide-helper Not Support Redis? • 1 year ago

@Specs you are correct, it doesn't seem to show that. The error states that function "get" is not a public static function, which is true. So you can access it with the :: operator. Now, this seems to work , initiating the object and then calling the function. It autocompletes perfectly:

$redis = new Redis();
$redis->get($key);

noeldiaz left a reply on Does Laravel-ide-helper Not Support Redis? • 1 year ago

@Specs this is what mine looks like, is this what you mean? https://shots.piscpr.com/Redis-lXvhgDAKeC/

noeldiaz left a reply on Does Laravel-ide-helper Not Support Redis? • 1 year ago

@Specs This is what mine looks when I start to use it, is this what you mean? (https://shots.piscpr.com/Redis-lXvhgDAKeC/)

noeldiaz left a reply on How Does The Spark Installer Work ? • 1 year ago

@virajkhatavkar Did you look through the code? (https://github.com/laravel/spark-installer) It actually was a lot simpler than I figured. Just executes a bunch of commands with the Symphony process component. I'm actually using it as a basis for a simple installer for my sites. I particularly like the way that it adds the service provider entries to the app.php file and package requirements to composer. Those are steps I keep repeating over and over and I want to streamline them.

noeldiaz left a reply on Does Laravel-ide-helper Not Support Redis? • 1 year ago

@Specs My bad, I'm using that version too. Did you have it generate the meta file? That makes it work much better when resolving out of the IoC (https://github.com/barryvdh/laravel-ide-helper#phpstorm-meta-for-container-instances). If not, it's not popping any code hints to you when you try the Facade?

noeldiaz left a reply on Does Laravel-ide-helper Not Support Redis? • 1 year ago

@Specs What IDE are you trying to get to work with it? I have it set up with phpstorm 9 and the usual hints pop right up. I also went ahead and generated the phpstorm.meta file to get it to work better. But the project I'm looking right now I'm not even using Redis and it all seems to work regardless out of the box.

noeldiaz left a reply on Typical Deployment Process • 1 year ago

@fsdolphin I develop and test locally, with either a VM or the build in php server. Once I'm pretty sure things work I push to my repository. After that I can pull down on my dev/test server to make sure everything works, or on production to deploy. I don't work on code other than on my local setup and always just push to repository (a Gitlab instance on a hosted server). But I also work alone so your situation might be different.

noeldiaz left a reply on How Does Laravel Forge Work? • 1 year ago

@infernobass7 Not sure if it is published anywhere, but maybe you could just open port 22 to the IPs of the forge servers. That way you don't have it open to the world. Other than that, it just uses SSH for everything. I have added private servers to it. But caution, it expects certain packages to be installed in certain ways for it to fully work. If you have a pretty basic Ubuntu setup with Nginx you should be good to go.

noeldiaz left a reply on File Permissions On Server, Keep Updates Possible • 1 year ago

@pdechery You certainly don't want folders at 777. That is just asking for trouble since that allows executables to run from there. You should do what you say, make the webserver group (in your case httpd I believe) the owner.

But you know, you don't need for the server to own anything other than the "storage" and the "cache" directory. Looking at my sites I keep everything owned by my user account, but change group ownership on those two directories to the webserver user.

You could always have the webserver group own everything, but it is not needed.

I update some sites through ssh. Others with git. So far this setup has worked perfectly.

noeldiaz left a reply on What Do You Use To Monitor Your Forge Server? • 1 year ago

@thomthom out of curiosity, are you using version 14.04 of ubuntu or the newly released 16.04? If you are using the newer one maybe the packages are not updated for it? Check with:

more /etc/os-release

If not, you could try updating the system first and doing a restart just in case.

sudo apt update
sudo apt upgrade
sudo apt-get autoremove
reboot

Then try again? Maybe it will help resolve any missing dependencies.

noeldiaz left a reply on What Do You Use To Monitor Your Forge Server? • 1 year ago

@thomthom Correct. In Ubuntu you do not normally run as root. But with sudo you can execute any command with root privileges.

3rd May, 2016

noeldiaz left a reply on What Do You Use To Monitor Your Forge Server? • 1 year ago

@thomthom You won't regret it. On 15 sites now and I would not be able to stay on top of problems without it. Integrates well with other services too. Have it hooked up to gitlab issues to track things to fix and the ever expanding to-do list.

noeldiaz left a reply on What Do You Use To Monitor Your Forge Server? • 1 year ago

@thomthom NewRelic actually compiles quite a bit of information about php application errors. Definitely set it up on your server. For most things I use bugsnag. It is just $9 a month now I believe and it does a great job of collecting app errors. I really like it and I am trying to get the on premise version bought for my job.

noeldiaz left a reply on What Do You Use To Monitor Your Forge Server? • 1 year ago

@thomthom I've had good experience with NewRelic's free server monitoring tier. Here is a good article about how to set it up [https://serversforhackers.com/using-new-relics-free-server-monitoring].

I do most of my hosting on Linode so I also use their LongView monitoring service.

28th April, 2016

noeldiaz left a reply on Sporadic 502 Bad Gateway On Homestead Box • 1 year ago

@thomthom You know, a few months back, I had all sorts of issues with homestead. Mostly because I was using a combination of boxes plus multiple providers (virtualbox and vmware). I had horrible slowness with Navicat to the box.

I ended up just wiping them clear and starting just with virtualbox from scratch. Have not had any problems for months and use the box on a daily basis for development.

27th April, 2016

noeldiaz left a reply on Sporadic 502 Bad Gateway On Homestead Box • 1 year ago

@thomthom You should definitely only have 1 "homestead" box running. Sounds like you have 2 running at the same time. The homestead7 one is probably the older one, since that sounds like when homestead was just beginning to support php 7. I would stop them both in virtualbox, then start the right one from the homestead folder. Maybe you are having IP conflicts between them? For sure you are wasting resources running both, so that could also affect your performance.

As far as things to check inside the box, I would look in your laravel log in the "storage/logs/laravel.log" and even in your web server log "/var/log/nginx". One of those two should have more information about your 502 errors. But stop the rogue VM first and see if that helps.

noeldiaz left a reply on CAS Authentication • 1 year ago

@mcqueena Last application I set up with CAS was a laravel 4 app, and I ended up just creating a "cas" filter to use. Since you probably are using laravel 5, just create a middleware and do the CAS check there? Then, instead of the "auth" middleware, you can just use your CAS one. Should be very simple to do, just a straight swap with auth mechanisms.

25th April, 2016

noeldiaz left a reply on Where To Find A Complete Api-like Documentation For Laravel Excel? • 1 year ago

@llevvi Hey there, just got back to this thread. Yeah, as far as I understand it LaravelExcel is just a wrapper over PHPExcel so it should have access to all the functions?

Now, I should say that even though I use it on some of my pages daily to export Excel files, I have not messed with the import for a long time. But this discussion interests me since I have one project now that importing multi-sheet excel files would be fantastic. Right now I cheat and convert to CSV (mostly since excel is a pain changing date formats and leading zero numbers).

So I don't have a solution for you, but I will see if I can give it a stab tonight when I get back to that project.

noeldiaz left a reply on Where To Find A Complete Api-like Documentation For Laravel Excel? • 1 year ago

@llevvi I thought their documentation was pretty good? Is this where you went? http://www.maatwebsite.nl/laravel-excel/docs/import

Where in your code is it failing? I've had issues sometimes with weird excel layouts but overall works pretty well.

22nd April, 2016

noeldiaz left a reply on Set SET Sql_mode On Homestead • 1 year ago

@ScottBaxter You can do it on your database.php definitions. Check out this post from Matt Stauffer's blog, shows all the options:

https://mattstauffer.co/blog/strict-mode-and-other-mysql-customizations-in-laravel-5-2

21st April, 2016

noeldiaz left a reply on Multiple Dropzone.js On One Page - Access "this" • 1 year ago

@Reached sounds logical. I had a similar problem placing multiple google maps on a page a while ago. Your comment made me look how I solved it. I guess I never really did but I ended up cheating. I also didn't want to repeat the code, so I ended up placing the JS code in a partial and then passing it the parameters I needed to make it work:

@section('scripts')
    @include('partials.googlemap', [
        'latitude' => $data['latitude'],
        'longitude' => $data['longitude']
    ])
@stop

Looking at the page I use that partial in multiple places to make maps, and that way I only have 1 place for the JS code. I also see I did something similar on another part of the page, where I had multiple bootstrap-multiselect drop-downs and I got tired of writing the code over and over and ended up doing this:

@section('scripts')
    <script type="text/javascript">
        $(function() {
            @include('partials.multiselect', ['element' => 'completeStatus', 'label' => 'Statuses'])
            @include('partials.multiselect', ['element' => 'inspectionType', 'label' => 'Types'])
        });
    </script>
@stop

There I pass the element name too so it binds to the right one. That way I can include as many as possible on same page but just have 1 JS code.

noeldiaz left a reply on Multiple Dropzone.js On One Page - Access "this" • 1 year ago

@Reached not sure if this is anything, but I see that you are attaching your dropzone using the .image-upload class? If that is the case, and both elements are on the page, then they both would get targeted by the dropzone right?

Maybe this is a case where you will need to call the javascript twice for the two elements using ID so that they are unique? Or maybe modify the code so that you can read some unique element from each snippet so that your code can determine if it is one or the other?

15th April, 2016

noeldiaz left a reply on Spark Or Elixir Issue? • 1 year ago

@tptompkins Did your npm install finish correctly? Maybe it didn't get all the necessary libraries? You could try running it again with "npm install --save" and then try gulp again?

14th April, 2016

noeldiaz left a reply on Develop Front End Theme As Separate Package From App • 1 year ago

@harryg You seem to be on the same path I just started. I finally got tired of reinventing the wheel and I sat down yesterday to finally learn how to make packages. And I tell you, it is awesome. I think it would be just what you need. I'm still learning the ropes but now I have a modular section of my app that has it's own views, controllers, and classes. And just like you say, I wanted default views but the ability to publish and edit as needed. Here is the article/tutorial I started with [http://laraveldaily.com/how-to-create-a-laravel-5-package-in-10-easy-steps/].

Now I'm starting to hunt down other packages to see how they did things and learn some more.

noeldiaz left a reply on DO Server Run Bash Commands • 1 year ago

@Piso this package from the Laravel Collective wraps SSH commands so you can easily execute them from within your application:

https://laravelcollective.com/docs/5.0/ssh

But like it was mentioned before, if you just want to run commands to do things like migrate and pull your site then Envoy is a good solution.

12th April, 2016

noeldiaz left a reply on Laravel Homestead Schedule Tasking On Windows • 1 year ago

@yigitozmen the command you list for the cron job looks off. You are missing the "artisan" part. On the documentation it is shown as:

* * * * * php /path/to/artisan schedule:run >> /dev/null 2>&1

So I think you have it close, just missing that part.

noeldiaz left a reply on Laravel Website On Digital Ocean Keeps Crashing • 1 year ago

@jasonlosito check and make sure you have turned swap on for your droplet. Without that you will crash when you run out of memory, especially on a small one. Here is a link to another forum thread where they discuss setting up the swap [https://laracasts.com/discuss/channels/forge/does-forge-run-ok-on-a-digitalocean-512mb-instance].

Won't be a solution if you end up doing more than what the droplet can handle, but should help you prevent most of the crashes.

noeldiaz left a reply on Connecting To SQL Server From MacOS? • 1 year ago

@Cleon getting SQL Server to play nice from outside of windows is a pain. I know, I gave up and just moved the relevant php files to IIS on the SQL server. :) But your question got me wondering and I found this link with some more suggestions for under OSX [https://github.com/BellevueCollege/public-docs/blob/master/PHP/configure-mssql-pdodblib-mac.md].

Some things listed here I have not tried. Might give it a shot here soon. In case it helps. If I get to try it I'll report back.

noeldiaz left a reply on Trying To Install PhpMyAdmin On Forge/Digital Ocean • 1 year ago

@dos Yeah, forge uses nginx for web server. I would not recommend running both apache and nginx, mostly since you will only be able to run one on port 80.

But you know, here's an alternative. I take it you already have a laravel site on forge right? And probably under nginx already? If so do this. Go into the "public" folder of the laravel site and create a new folder in there to hold the adminer php file. So line make a folder called "adminer" under public, place the file in there, and rename it to "index.php". Then, after you go into that file and fill in the settings, you will be able to access it as:

http://yoursite.com/adminer/

Anything inside the "public" dir gets processed as-is. So this works. Just tried it on one of my sites.

That's a quick and dirty way to get it up without having to mess with your webserver. The correct way, if you want it separate, it to set up another site under nginx and point it to a directory with the adminer file. I would also choose a more cryptic name for the directory so it is harder to find, and maybe even look into htpasswd authentication or IP based blocks on that directory.

But this should get you going.

noeldiaz left a reply on Trying To Install PhpMyAdmin On Forge/Digital Ocean • 1 year ago

@dos well for your second thing you don't have php 5 installed, you have 7. So the correct command would be:

sudo service php7.0-fpm restart

Now for your first thing, it could be that MySQL is only listening to localhost and binding to it and thus will not allow you to just connect locally to it. That would be in your /etc/mysql/my.cnf. Might need to adjust your bind setting and restart.

Also, if you want something easier to install, I'm a big fan of Adminer [https://www.adminer.org]. One file and you are good to go with full compliment of options.

1st April, 2016

noeldiaz left a reply on Laravel 5.2 ACL Package • 1 year ago

@concept_core Big fan of all packages from Spatie. Check out this one for roles and permissions https://github.com/spatie/laravel-permission and this one for authorization https://github.com/spatie/laravel-authorize. Lots of other good ones to check out in their repository or check out their nice list here: https://spatie.be/opensource/laravel

28th March, 2016

noeldiaz left a reply on Design On Homepage Broken - Firefox Issue • 1 year ago

I bet it is. I'm running Firefox 45.0.1 and no plugins active on it. Works great otherwise in Safari and Chrome on my Mac.

Edit Your Profile
Update

Want to change your profile photo? We pull from gravatar.com.