Skip to content

Instantly share code, notes, and snippets.

View devkoriel's full-sized avatar

Jinsoo Heo devkoriel

View GitHub Profile
@devkoriel
devkoriel / mattermost-nginx-conf
Created March 12, 2019 13:15
Mattermost nginx.conf
server {
listen 80;
server_name chat.example.com;
location ~ /api/v[0-9]+/(users/)?websocket$ {
proxy_pass http://127.0.0.1:<HOST_포트>;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade";
@devkoriel
devkoriel / mattermost-docker-compose.yml
Created March 12, 2019 12:25
Mattermost docker-compose.yml
# This file allows you to run mattermost within your docker swarm mode cluster
# for more informations check: https://docs.docker.com/engine/swarm/
#
# Simply run:
#
# `docker stack up [STACK NAME] -c docker-stack.yml`
#
# In this case `mattermost` is going to be stack name, so the command will be:
#
# `docker stack up mattermost -c docker-stack.yml`
@devkoriel
devkoriel / determinant.c
Last active October 6, 2017 10:56
Calculate determinant by recursive method.
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <malloc.h>
struct matrix_t {
int height;
int width;
int** data;
@devkoriel
devkoriel / application.css
Last active February 22, 2017 11:11
application.css
/*!
* Font Awesome 4.7.0 by @davegandy - http://fontawesome.io - @fontawesome
* License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License)
*/@font-face{font-family:'FontAwesome';src:url("//d2hmp4n7p97ldw.cloudfront.net/assets/font-awesome/fontawesome-webfont-7bfcab6db99d5cfbf1705ca0536ddc78585432cc5fa41bbd7ad0f009033b2979.eot?v=4.7.0");src:url("//d2hmp4n7p97ldw.cloudfront.net/assets/font-awesome/fontawesome-webfont-7bfcab6db99d5cfbf1705ca0536ddc78585432cc5fa41bbd7ad0f009033b2979.eot?v=4.7.0#iefix") format("embedded-opentype"),url("//d2hmp4n7p97ldw.cloudfront.net/assets/font-awesome/fontawesome-webfont-2adefcbc041e7d18fcf2d417879dc5a09997aa64d675b7a3c4b6ce33da13f3fe.woff2?v=4.7.0") format("woff2"),url("//d2hmp4n7p97ldw.cloudfront.net/assets/font-awesome/fontawesome-webfont-ba0c59deb5450f5cb41b3f93609ee2d0d995415877ddfa223e8a8a7533474f07.woff?v=4.7.0") format("woff"),url("//d2hmp4n7p97ldw.cloudfront.net/assets/font-awesome/fontawesome-webfont-aa58f33f239a0fb02f5c7a6c45c043d7a9ac9a0933358
@devkoriel
devkoriel / fibonacci.c
Last active June 11, 2020 17:38
Print Fibonacci sequence using fork()
#include <stdio.h>
#include <sys/types.h>
#include <wait.h>
#include <unistd.h>
#include <stdlib.h>
#include <errno.h>
int main(int argc, char* argv[])
{
int arg = atoi(argv[1]); // 시스템 인자를 정수형으로 변환
@devkoriel
devkoriel / client.c
Created October 16, 2016 16:04
TCP client.c
#include "client.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
@devkoriel
devkoriel / server.c
Created October 16, 2016 16:02
TCP server.c
#include "server.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
@devkoriel
devkoriel / client.c
Created October 16, 2016 15:44
UDP client.c
#include "client.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
@devkoriel
devkoriel / server.c
Last active October 16, 2016 15:43
UDP server.c
#include "server.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>