Skip to content

Instantly share code, notes, and snippets.

View SunDi3yansyah's full-sized avatar
Verified

Cahyadi Triyansyah SunDi3yansyah

Verified
View GitHub Profile
@SunDi3yansyah
SunDi3yansyah / gpp.php
Last active August 29, 2015 14:05
Aku ora popo
<?php echo "Aku ora popo"; ?>
@SunDi3yansyah
SunDi3yansyah / php5-fpm.sh
Created August 31, 2014 12:27
Service PHP5-FPM
#!/bin/sh -e
set -e
INITSCRIPT="$(basename "$0")"
JOB="${INITSCRIPT%.sh}"
if [ "$JOB" = "upstart-job" ]; then
if [ -z "$1" ]; then
echo "Usage: upstart-job JOB COMMAND" 1>&2
exit 1
@SunDi3yansyah
SunDi3yansyah / nginx.sh
Created August 31, 2014 12:33
Service Nginx
#!/bin/sh
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
DAEMON=/usr/sbin/nginx
NAME=nginx
DESC=nginx
if [ -r /etc/default/nginx ]; then
. /etc/default/nginx
fi
@SunDi3yansyah
SunDi3yansyah / reboot.sh
Created August 31, 2014 12:35
sleep and wake up again
#! /bin/sh
PATH=/sbin:/usr/sbin:/bin:/usr/bin
. /lib/lsb/init-functions
do_stop () {
log_action_msg "Will now restart"
reboot -d -f -i
}
case "$1" in
start)
;;
@SunDi3yansyah
SunDi3yansyah / index.html
Created September 1, 2014 16:30
index of repository/source/blog/
<article>
{% include ../article.html %}
</article>
@SunDi3yansyah
SunDi3yansyah / ex_gist.php
Last active August 29, 2015 14:06
Ex Gist
<?php echo "saya telah melakukan perubahan code"; ?>
@SunDi3yansyah
SunDi3yansyah / lemp.sh
Last active August 29, 2015 14:06
Fail Install LEMP
[root@localhost ~]# yum --enablerepo=remi,remi-test install nginx mysql mysql-server php php-common php-fpm
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
epel/metalink | 5.6 kB 00:00
* base: centos.biz.net.id
* epel: mirror.smartmedia.net.id
* extras: centos.biz.net.id
* remi: mirror.smartmedia.net.id
* remi-test: mirror.smartmedia.net.id
* updates: centos.biz.net.id
@SunDi3yansyah
SunDi3yansyah / error_install_lemp
Created September 4, 2014 15:07
You could try using --skip-broken to work around the problem
[root@septasite ~]# rpm -Uvh http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm
Retrieving http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm
warning: /var/tmp/rpm-tmp.BI92on: Header V3 RSA/SHA256 Signature, key ID 0608b895: NOKEY
Preparing... ########################################### [100%]
1:epel-release ########################################### [100%]
[root@septasite ~]# rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-6.rpm
Retrieving http://rpms.famillecollet.com/enterprise/remi-release-6.rpm
warning: /var/tmp/rpm-tmp.Rqk9aI: Header V3 DSA/SHA1 Signature, key ID 00f97f56: NOKEY
Preparing... ########################################### [100%]
1:remi-release ########################################### [100%]
@SunDi3yansyah
SunDi3yansyah / sub.domain_nginx.conf
Created September 6, 2014 12:33
Create Sub Domain for NGINX a.k.a Virtual Host by. SunDi3yansyah
server {
server_name sub.domain;
access_log /usr/share/nginx/html/sub.domain/access.log;
error_log /usr/share/nginx/html/sub.domain/error.log;
root /usr/share/nginx/html/sub.domain;
location / {
root /usr/share/nginx/html/sub.domain;
index index.php index.htm index.html;
}
@SunDi3yansyah
SunDi3yansyah / gist:8582393baf9dcb582a3a
Created September 6, 2014 13:23
Test gist for octopress gist tag
@@ -590,7 +590,7 @@ class SpritesTest < Test::Unit::TestCase
it "should generate a sprite from nested folders" do
css = render <<-SCSS
- @import "nested/*.png";
+ @import "nested/**/*.png";
@include all-nested-sprites;
SCSS
assert_correct css, <<-CSS