Skip to content

Instantly share code, notes, and snippets.

@abraaojs
abraaojs / install_docker_centos7.sh
Last active August 17, 2023 08:40
Script to install docker-ce on centos 7
#!/bin/bash
# Created by Abraão Silva
# Install docker in centos
# Remove any old versions
sudo yum remove docker docker-common docker-selinux docker-engine
# Install required packages
sudo yum install -y yum-utils device-mapper-persistent-data lvm2
apiVersion: apps/v1
kind: Deployment
metadata:
name: ubuntu-deployment
labels:
app: ubuntu
spec:
replicas: 1
selector:
matchLabels:
@yonglai
yonglai / playbook_centos_install_docker.yaml
Created November 15, 2017 18:04
An Ansible playbook to install docker-ce on Centos
---
- name: Install docker
gather_facts: No
hosts: default
tasks:
- name: Install yum utils
yum:
name: yum-utils
state: latest
@Balamir
Balamir / get_os_and_browser.php
Created October 7, 2016 12:50
PHP: get user os and browser information
<?php
/**
* Kullanicinin kullandigi isletim sistemi bilgisini alir.
*
* @since 2.0
*/
function getOS() {
$user_agent = $_SERVER['HTTP_USER_AGENT'];