PHP : Composer in docker

Si vous développer en PHP avec tout votre environnement local de développement en docker, alors vous voudriez bien aussi utilisez les bonnes pratiques de docker et placer Composer dans un container. Pour ce faire, il existe donc l’image officiel de Composer sur le hub de docker. Voilà comment, je l’utilise : docker pull composer Ce container sera utilisé en lancement au premier plan et supprimer ensuite, il est inutile de laisser tourner ce container. ...

June 16, 2017 · 1 min · 190 words · oxomichael

Apache2, PHP-FPM

Since Apache version 2.4.10, it’s possible to achieve performance similar to NGINX, mainly by using php-fpm with mod_fcgi. With Ubuntu 14.04 First, enable trusty-backports in /etc/apt/source.list, then give priority to backports packages in the /etc/apt/preferences file: Package: * Pin: release a=trusty-backports Pin-Priority: 500 Then run: $ apt-get update && apt-get upgrade Verify that Apache 2.4.10 is installed: $ apt-get install apache2 Install php-fpm (php5-fpm or php-7.0-fpm): $ apt-get install php5-fpm Create a file /etc/apache2/conf-available/phpfcgi.conf: ...

June 28, 2016 · 2 min · 389 words · oxomichael

Install Eclipse on Ubuntu

Eclipse OXYGEN Download the new oomph installer. Install in your home Create a desktop entry with Icon $ gedit .local/share/applications/eclipse.desktop [Desktop Entry] Name=Eclipse Type=Application Exec=/home/USERNAME/eclipse/eclipse Terminal=false Icon=/home/USERNAME/eclipse/icon.xpm Comment=Integrated Development Environment NoDisplay=false Categories=Development;IDE; Name[en]=Eclipse Name[fr]=Eclipse Eclipse Mars.2 Uncompress the Eclipse archive in your home Edit eclipse.ini File -startup plugins/org.eclipse.equinox.launcher_1.3.100.v20150511-1540.jar --launcher.library plugins/org.eclipse.equinox.launcher.gtk.linux.x86_64_1.1.300.v20150602-1417 -product org.eclipse.epp.package.php.product --launcher.defaultAction openFile -showsplash org.eclipse.platform --launcher.XXMaxPermSize 256m --launcher.defaultAction openFile --launcher.GTK_version 2 --launcher.appendVmargs -vmargs -Dosgi.requiredJavaVersion=1.8 -Xms256m -Xmx1024m

May 12, 2016 · 1 min · 67 words · oxomichael

Linux and USB 3.0: Disabling the UASP Protocol for a Device

After purchasing an ICY DOCK Black Vortex enclosure (MB174SU3S-4SB) to house four backup drives, I noticed that intensive use of rsync was causing slowdowns and unexpected disconnections. A quick look at the kernel logs with dmesg revealed numerous USB-related errors. The enclosure is connected via USB 3.0, as confirmed by the lsusb command: $ lsusb Bus 006 Device 002: ID 152d:0567 JMicron Technology Corp. / JMicron USA Technology Corp. JMS567 SATA 6Gb/s bridge The lsusb -t command shows that the uas (USB Attached SCSI) driver is currently in use: ...

March 2, 2016 · 2 min · 249 words · oxomichael

Guide: Migrating a Git Repository to Another Server

A simple and effective guide to migrating a complete Git repository, including all branches and tags, from one server to another.

February 4, 2016 · 2 min · 251 words · oxomichael

Complete Guide: Migrating an SVN Repository to Git

A step-by-step guide to migrating a project from Subversion (SVN) to Git, preserving commit history and authors.

January 23, 2016 · 3 min · 486 words · oxomichael

Composer and Zend Framework version 1

Define your apps for autoloading You’re still working with Zend Framework 1 (and yes, still apps running without you being able to make an evolution), so here’s a small example of use. First, create your file composer.json { "name": "company/projet", "description": "ma description", "require": { "zendframework/zendframework1": "^1.12" }, "autoload": { "classmap": [ "application/", "library/Application/", ] }, } Use the require and classmap option to create our autoload (again we have an old application). See the composer documentation to add more configuration options (http://getcomposer.org). ...

September 25, 2015 · 2 min · 233 words · oxomichael

Upgrade MySQL in Ubuntu

Updating Ubuntu (from one version to another) and restarting MySQL…..oops it doesn’t work…because for me, the data directory is located outside the standard path, and so apparmor is not happy. To keep it simple and avoid further issues: Backup your MySQL configuration file: $ sudo cp /etc/mysql/my.cnf /etc/mysql/my.cnf.backup Modify the Apparmor configuration by adding a file: $ sudo nano /etc/apparmor.d/local/usr.sbin.mysqld This adds a machine-specific file for local settings containing additional parameters, without changing the base configuration. File content: ...

August 17, 2014 · 1 min · 101 words · oxomichael

Set Up an OpenVPN Server with Samba Share

This article was originally written in 2011. It has been revised for clarity and updated with more modern configurations. Technologies like OpenVPN and Samba are constantly evolving, so always consult the official documentation for the latest recommendations. This guide aims to set up a simple OpenVPN server to secure access to a local network and route all web traffic through it. The local network uses the 192.168.0.0/24 address range. A server on this network, with the IP address 192.168.0.10, will host OpenVPN and a DNS server (dnsmasq) to manage local DNS queries. We will call it “Server.” ...

August 7, 2011 · 5 min · 873 words · oxomichael

Consuming a SOAP Web Service with Basic Authentication in C#

Interacting with SOAP web services, such as those built with PHP, from a .NET application is a common task. When these services are protected by HTTP Basic Authentication, configuring the C# client requires a small extra step, but it’s simpler than it might seem. This guide demonstrates the standard and recommended method for consuming a secure SOAP web service with Basic Auth using C#. The Challenge: Basic Authentication When you add a “Service Reference” to a Visual Studio project for a SOAP web service, the generated client doesn’t automatically handle sending authentication credentials. If you try to call a service method directly, you will likely get a (401) Unauthorized error. ...

June 26, 2011 · 3 min · 498 words · oxomichael