Thanks to the original blog post: https://equimper.com/blog/how-to-setup-tailwindcss-in-phoenix-1.4
cd assets
npm i --save-dev tailwindcss postcss-loader postcss-import
/** | |
* @license Copyright (c) 2003-2020, CKSource - Frederico Knabben. All rights reserved. | |
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | |
*/ | |
// The editor creator to use. | |
import ClassicEditorBase from '@ckeditor/ckeditor5-editor-classic/src/classiceditor'; | |
import Essentials from '@ckeditor/ckeditor5-essentials/src/essentials'; | |
import Bold from '@ckeditor/ckeditor5-basic-styles/src/bold'; |
# 把image拉下你的local端 | |
docker pull deniel79/elixir-phx-centos8 | |
# 執行並進入docker裡 | |
docker run -it deniel79/elixir-phx-centos8 | |
# 檢查是否已安裝好 | |
asdf current |
useradd -m -s /bin/bash deploy | |
"deploy ALL=(ALL) NOPASSWD:ALL" > /etc/sudoers.d/10-app-deploy | |
mkdir -p ~deploy/.ssh | |
chown deploy:deploy ~deploy/.ssh | |
chmod 700 ~deploy/.ssh | |
cp ~root/.ssh/authorized_keys ~deploy/.ssh | |
chown deploy:deploy ~deploy/.ssh/authorized_keys |
// References used: | |
// - https://yesviz.com/devices.php | |
// - https://ricostacruz.com/til/css-media-query-breakpoints | |
// - https://tailwindcss.com/docs/responsive-design/#customizing-breakpoints | |
screens: { | |
xs: { max: '575px' }, // Mobile (iPhone 3 - iPhone XS Max). | |
sm: { min: '576px', max: '897px' }, // Mobile (matches max: iPhone 11 Pro Max landscape @ 896px). | |
md: { min: '898px', max: '1199px' }, // Tablet (matches max: iPad Pro @ 1112px). | |
lg: { min: '1200px' }, // Desktop smallest. | |
xl: { min: '1159px' }, // Desktop wide. |
Thanks to the original blog post: https://equimper.com/blog/how-to-setup-tailwindcss-in-phoenix-1.4
cd assets
npm i --save-dev tailwindcss postcss-loader postcss-import
defmodule Randomizer do | |
@moduledoc """ | |
Random string generator module. | |
""" | |
@doc """ | |
Generate random string based on the given legth. It is also possible to generate certain type of randomise string using the options below: | |
* :all - generate alphanumeric random string | |
* :alpha - generate nom-numeric random string |
sudo yum -y install gcc gcc-c++ glibc-devel make ncurses-devel openssl-devel autoconf java-1.8.0-openjdk-devel git | |
sudo yum -y install wxBase.x86_64 | |
sudo yum -y install wget | |
wget http://packages.erlang-solutions.com/erlang-solutions-1.0-1.noarch.rpm | |
sudo rpm -Uvh erlang-solutions-1.0-1.noarch.rpm | |
sudo yum -y install esl-erlang | |
sudo mkdir /opt/elixir | |
sudo git clone https://github.com/elixir-lang/elixir.git /opt/elixir | |
cd /opt/elixir | |
sudo make clean test |
sudo yum install php php-mysql -y | |
sudo yum install epel-release -y | |
sudo yum clean all -y | |
sudo yum update -y | |
sudo yum install phpmyadmin -y | |
service httpd restart |
ssh-keygen -t rsa -b 4096 -N '' -C "[email protected]" -f ~/.ssh/id_rsa | |
ssh-keygen -t rsa -b 4096 -N '' -C "[email protected]" -f ~/.ssh/aws_rsa | |
ssh-keygen -t rsa -b 4096 -N '' -C "[email protected]" -f ~/.ssh/github_rsa | |
ssh-keygen -t rsa -b 4096 -N '' -C "[email protected]" -f ~/.ssh/digital_ocean_rsa | |
ssh-keygen -t rsa -b 4096 -N '' -C "[email protected]" -f ~/.ssh/heroku_rsa |