Posts

How to Host Multiple Docker Containers on a Single Droplet with Nginx Reverse Proxy?

  Step 1 - run your Docker containers For the same of simplicity, I will run a simple and I’ll run 2 small  httpd  containers. Run your first container and map port  8080  on your host: docker run -dit --name container-1 -p 8080:80 httpd:2.4 Now if you visit http:// your-dropets-ip :8080, you should be able to see a message saying  It Works! . Just so that we could differentiate the two containers, let’s update the  It works!  message with  Container 1  for example: First get your container ID docker ps Then run the following  sed  command to update the message: docker exec CONTAINER_ID sed -i 's/It works!/Container 1/' /usr/local/apache2/htdocs/index.html This would basically run a search and replace for the  It works!  string and update it with  Container 1  in the default  index.html  file in the container itself. If you visit your Droplet’s IP again in your browser the message should change fr...

Docker Cheatsheet ( Docker Commonds )

Docker is an open platform for developing, shipping, and running applications. Docker enables you to separate your applications from your infrastructure so you can deliver software quickly. With Docker, you can manage your infrastructure in the same ways you manage your applications. By taking advantage of Docker’s methodologies for shipping, testing, and deploying code quickly, you can significantly reduce the delay between writing code and running it in production. In this post, I will mention docker commands which we need or most of the use-cases. Lifecycle Commands Starting and Stopping Containers Docker Image Commands Docker Container And Image Information Network Commands Lifecycle Commands Create a container (without starting it): docker create [IMAGE] Rename an existing container docker rename [CONTAINER_NAME] [NEW_CONTAINER_NAME] Run a command in a new container docker run [IMAGE] [COMMAND] Remove container after it exits docker run --rm [IMAGE] Start a container and keep it r...

How do I clone a SVN repository using git commonds in ubuntu?

 How do I clone a SVN repository using git commonds in ubuntu? sudo  apt -get  install subversion . sudo  apt -get  install git - svn sudo svn clone reposetory_name.

Parsing filters unsupported error during extraction of RAR file in ubuntu

  “Parsing filters unsupported” error during extraction of RAR  in Ubuntu install unrar: sudo apt-get install unrar then to extract, go to the path of the  .rar  file and run commond : unrar x [filename.rar]

Install XAMPP on Ubuntu

  Install XAMPP on Ubuntu Open a  command line  terminal and type the following commands to download and install XAMPP on your system. step1 - Start by navigating to  XAMPP's offical website  and downloading the latest version for Linux. step2 - Once it's downloaded, add execute permissions to the installation file, then execute it. $ chmod +x xampp-linux-*-installer.run $ sudo ./xampp-linux-*-installer.run

How to Install and Secure phpMyAdmin with Nginx on an Ubuntu 18.04 server

Image
  How to Install and Secure phpMyAdmin with Nginx on an Ubuntu 18.04 server Introduction While many users need the functionality of a database system like MySQL, interacting with the system solely from the MySQL command-line client requires familiarity with the SQL language, so it may not be the preferred interface for some. phpMyAdmin  was created so that users can interact with MySQL through an intuitive web interface, running alongside a PHP development environment. In this guide, we’ll discuss how to install phpMyAdmin on top of an Nginx server, and how to configure the server for increased security. Note:  There are important security considerations when using software like phpMyAdmin, since it runs on the database server, it deals with database credentials, and it enables a user to easily execute arbitrary SQL queries into your database. Because phpMyAdmin is a widely-deployed PHP application, it is frequently targeted for attack. We will go over some security measu...