(wherever it says url.com, use your server's domain or IP)
Login to new server as root, then add a deploy user
sudo useradd --create-home -s /bin/bash deploy
sudo adduser deploy sudo
sudo passwd deployAnd Update the new password
| module.exports = function(dbConfig) { | |
| var knex = require('knex')(dbConfig); | |
| var KnexQueryBuilder = require('knex/lib/query/builder'); | |
| KnexQueryBuilder.prototype.paginate = function (per_page, current_page) { | |
| var pagination = {}; | |
| var per_page = per_page || 10; | |
| var page = current_page || 1; | |
| if (page < 1) page = 1; |
(wherever it says url.com, use your server's domain or IP)
Login to new server as root, then add a deploy user
sudo useradd --create-home -s /bin/bash deploy
sudo adduser deploy sudo
sudo passwd deployAnd Update the new password
This is a fork of original gist https://gist.github.com/nrollr/3f57fc15ded7dddddcc4e82fe137b58e, with slight changes on pointing to 5.7 version branch, instead of 8 (latest default of MySQL in Hombrew).
This procedure explains how to install MySQL using Homebrew on macOS (Sierra 10.12 and up)
$ /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"| # Use an official Ubuntu Xenial as a parent image | |
| FROM ubuntu:16.04 | |
| # Install Node.js 8 and npm 5 | |
| RUN apt-get update | |
| RUN apt-get -qq update | |
| RUN apt-get install -y build-essential | |
| RUN apt-get install -y curl | |
| RUN curl -sL https://deb.nodesource.com/setup_8.x | bash | |
| RUN apt-get install -y nodejs |
| server { | |
| listen 80; | |
| server_name localhost; | |
| root /Users/YOUR_USERNAME/Sites; | |
| access_log /Library/Logs/default.access.log main; | |
| location / { | |
| include /usr/local/etc/nginx/conf.d/php-fpm; | |
| } |
| /* source: https://tailwindcss.com/docs/customizing-colors/#default-color-palette */ | |
| :root { | |
| --black: #000000; | |
| --white: #ffffff; | |
| --gray-100: #f7fafc; | |
| --gray-200: #edf2f7; | |
| --gray-300: #e2e8f0; | |
| --gray-400: #cbd5e0; |
| #!/usr/bin/env bash | |
| #styles | |
| VP_NONE='\033[00m' | |
| VP_RED='\033[01;31m' | |
| VP_GREEN='\033[01;32m' | |
| VP_YELLOW='\033[01;33m' | |
| VP_PURPLE='\033[01;35m' | |
| VP_CYAN='\033[01;36m' | |
| VP_WHITE='\033[01;37m' |
| RUN apt update | |
| RUN apt upgrade -y | |
| RUN apt install -y apt-utils | |
| RUN a2enmod rewrite | |
| RUN apt install -y libmcrypt-dev | |
| RUN docker-php-ext-install mcrypt | |
| RUN apt install -y libicu-dev | |
| RUN docker-php-ext-install -j$(nproc) intl | |
| RUN apt-get install -y libfreetype6-dev libjpeg62-turbo-dev libpng12-dev | |
| RUN docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/ |