-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
58 additions
and
141 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,53 @@ | ||
# Crostini Development Setup | ||
|
||
## Remove Unneeded Packages | ||
## Setup Shell | ||
|
||
`sudo apt remove apache2` | ||
1. Install | ||
- `~/.ssh/timnolte_id_rsa` | ||
|
||
2. `git init` | ||
3. `git remote add origin [email protected]:timnolte/.shell.git` | ||
4. `GIT_SSH_COMMAND="ssh -i ~/.ssh/timnolte_id_rsa" git fetch` | ||
5. Backup Current Home | ||
- `mkdir backup` | ||
- `cp -R .* ./backup/` | ||
6. `git checkout master` | ||
7. `mkdir workspace` | ||
|
||
## Install Required Packages | ||
### Setup Development Shell | ||
|
||
```bash | ||
sudo apt install net-tools tree wget curl procps mlocate man gettext | ||
sudo apt install ccrypt gnupg2 | ||
sudo apt install grep bash-completion | ||
sudo apt install git subversion php nodejs mariadb-server nginx php-fpm python python-dev python3 python3-dev ruby ruby-dev golang make | ||
sudo apt install rclone ctags | ||
sudo apt install software-properties-common | ||
sudo apt install python-pip python-setuptools python-setuptools-git | ||
sudo apt install ca-certificates apt-transport-https | ||
sudo apt install snapd | ||
$ ~/.config/dev-shell/setup.sh` | ||
``` | ||
|
||
## Install Required Packages | ||
|
||
```bash | ||
$ sudo apt install net-tools tree wget curl procps mlocate man gettext \ | ||
ccrypt gnupg2 \ | ||
grep bash-completion \ | ||
git subversion php-cli python python-pip python-dev \ | ||
python3 python3-pip python3-dev ruby ruby-dev golang make \ | ||
ninja-build gettext libtool libtool-bin autoconf automake cmake \ | ||
g++ pkg-config unzip xsel editorconfig gdb \ | ||
rclone \ | ||
software-properties-common \ | ||
python-pip python-setuptools python-setuptools-git \ | ||
ca-certificates apt-transport-https \ | ||
snapd \ | ||
build-essential libssl-dev zlib1g-dev libbz2-dev libreadline-dev \ | ||
libsqlite3-dev llvm libncurses5-dev libncursesw5-dev \ | ||
xz-utils tk-dev libgdbm-dev liblzma-dev uuid-dev \ | ||
libnotify4 libnspr4 libnss3 libxkbfile1 libsecret-common libsecret-1-0 | ||
``` | ||
|
||
## Install Snap Package Management | ||
|
||
### Install Required Packages | ||
### Install Required Packages for Snap | ||
|
||
```bash | ||
sudo apt install fuse2 | ||
sudo apt install squashfs-tools | ||
sudo apt install libfuse-dev | ||
sudo apt install libattr1 libattr1-dev | ||
sudo apt install zlib1g zlib1g-dev | ||
sudo apt install udev | ||
$ sudo apt install fuse2 squashfs-tools libfuse-dev libattr1 libattr1-dev \ | ||
zlib1g zlib1g-dev udev | ||
``` | ||
|
||
### Build & Install squashfs | ||
|
@@ -44,91 +61,41 @@ sudo apt install udev | |
### System Permissions Fix for Snap | ||
|
||
```bash | ||
sudo chmod 755 / | ||
$ sudo chmod 755 / | ||
``` | ||
|
||
|
||
## Install PHP 7.3 | ||
|
||
1. `wget -q https://packages.sury.org/php/apt.gpg -O- | sudo apt-key add -` | ||
3. `echo "deb https://packages.sury.org/php/ stretch main" | sudo tee /etc/apt/sources.list.d/php.list` | ||
4. `sudo apt update` | ||
5. `sudo apt upgrade` | ||
6. `sudo apt install php7.3-fpm php7.3-opcache php7.3-xml php7.3-xsl php7.3-mbstring` | ||
|
||
|
||
## Setup Shell | ||
|
||
1. Install | ||
- `~/.ssh/timnolte_id_rsa` | ||
|
||
2. `git init` | ||
3. `git remote add origin [email protected]:timnolte/.shell.git` | ||
4. `GIT_SSH_COMMAND="ssh -i ~/.ssh/timnolte_id_rsa" git fetch` | ||
5. Backup Current Home | ||
- `mkdir backup` | ||
- `cp -R .* ./backup/` | ||
6. `git checkout master` | ||
8. `mkdir workspace` | ||
|
||
### Setup Development Shell | ||
|
||
1. `~/.config/dev-shell/setup.sh` | ||
|
||
|
||
## Build & Install Python 3.7 | ||
|
||
### Remove Python 3.5 | ||
|
||
`sudo apt remove python3.5` | ||
|
||
> Note: software-properties-common & unattended-upgrades packages are also removed and may cause unknown issues at this time. | ||
### Install Required Dependancies | ||
```shel | ||
sudo apt install build-essential libssl-dev zlib1g-dev libbz2-dev libreadline-dev | ||
sudo apt install libsqlite3-dev llvm libncurses5-dev libncursesw5-dev | ||
sudo apt install xz-utils tk-dev libgdbm-dev liblzma-dev uuid-dev | ||
``` | ||
|
||
### Download Source & Build Python 3.7 | ||
|
||
1. `cd workspace` | ||
2. `wget https://www.python.org/ftp/python/3.7.3/Python-3.7.3.tgz` | ||
3. `tar -xzvf Python-3.7.3.tgz` | ||
4. `./configure --enable-optimizations --with-ensurepip=install` | ||
5. `make -j8` | ||
6. `sudo make install` | ||
## Python Configuration | ||
|
||
### Setup Python & pip 3.7 as Default Python & Python 3 | ||
```shell | ||
sudo update-alternatives --install /usr/bin/python python /usr/bin/python2 27 | ||
sudo update-alternatives --install /usr/bin/python3 python3 /usr/local/bin/python3.7 37 | ||
sudo update-alternatives --install /usr/bin/python python /usr/bin/python3 37 | ||
sudo update-alternatives --install /usr/bin/python3m-config python3-config /usr/local/bin/python3.7-config 37 | ||
sudo update-alternatives --install /usr/bin/python3m python3m /usr/local/bin/python3.7m 37 | ||
sudo update-alternatives --install /usr/bin/python3m-config python3m-config /usr/local/bin/python3.7m-config 37 | ||
sudo mv /usr/bin/pip /usr/bin/pip.bak | ||
sudo update-alternatives --install /usr/bin/pip pip /usr/bin/pip2 27 | ||
sudo update-alternatives --install /usr/bin/pip3 pip3 /usr/local/bin/pip3.7 37 | ||
sudo update-alternatives --install /usr/bin/pip pip /usr/bin/pip3 37 | ||
``` | ||
|
||
```bash | ||
$ sudo update-alternatives --install /usr/bin/python python /usr/bin/python2 27 | ||
$ sudo update-alternatives --install /usr/bin/python3 python3 /usr/local/bin/python3.7 37 | ||
$ sudo update-alternatives --install /usr/bin/python python /usr/bin/python3 37 | ||
$ sudo update-alternatives --install /usr/bin/python3m-config python3-config /usr/local/bin/python3.7-config 37 | ||
$ sudo update-alternatives --install /usr/bin/python3m python3m /usr/local/bin/python3.7m 37 | ||
$ sudo update-alternatives --install /usr/bin/python3m-config python3m-config /usr/local/bin/python3.7m-config 37 | ||
$ sudo mv /usr/bin/pip /usr/bin/pip.bak | ||
$ sudo update-alternatives --install /usr/bin/pip pip /usr/bin/pip2 27 | ||
$ sudo update-alternatives --install /usr/bin/pip3 pip3 /usr/local/bin/pip3.7 37 | ||
$ sudo update-alternatives --install /usr/bin/pip pip /usr/bin/pip3 37 | ||
``` | ||
|
||
## Build & Install NodeJS 10 & NPM | ||
|
||
> Instead of installing a system package it is more flexible to install NVM and use a user-based NodeJS/NPM. | ||
|
||
1. `cd workspace/` | ||
2. `mkdir ~/.nvm` | ||
2. `curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.0/install.sh | bash` | ||
|
||
3. `curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.36.0/install.sh | bash` | ||
|
||
## Build & Install Neovim | ||
|
||
### Install Required Dependancies | ||
|
||
sudo apt install ninja-build gettext libtool libtool-bin autoconf automake cmake g++ pkg-config unzip xsel editorconfig | ||
```bash | ||
$ sudo apt install ninja-build gettext libtool libtool-bin autoconf automake cmake g++ pkg-config unzip xsel editorconfig | ||
``` | ||
|
||
### Checkout and Build Neovim | ||
|
||
|
@@ -158,10 +125,10 @@ alias vimdiff='nvim -d' | |
|
||
#### System Wide | ||
|
||
```shell | ||
sudo update-alternatives --install /usr/bin/vi vi /usr/bin/nvim 60 | ||
sudo update-alternatives --install /usr/bin/vim vim /usr/bin/nvim 60 | ||
sudo update-alternatives --install /usr/bin/editor editor /usr/bin/nvim 60 | ||
```bash | ||
$ sudo update-alternatives --install /usr/bin/vi vi /usr/bin/nvim 60 | ||
$ sudo update-alternatives --install /usr/bin/vim vim /usr/bin/nvim 60 | ||
$ sudo update-alternatives --install /usr/bin/editor editor /usr/bin/nvim 60 | ||
``` | ||
|
||
### Setup Neovim as IDE | ||
|
@@ -185,64 +152,14 @@ sudo update-alternatives --install /usr/bin/editor editor /usr/bin/nvim 60 | |
|
||
#### Debian Package Method | ||
|
||
##### Install Required Dependancies | ||
|
||
``` | ||
sudo apt install libnotify4 libnspr4 libnss3 libxkbfile1 libsecret-common libsecret-1-0 | ||
``` | ||
##### Download and Install Package | ||
|
||
1. `curl -L "https://go.microsoft.com/fwlink/?LinkID=760868" > ~/.tmp/vscode.deb` | ||
2. `sudo dpkg -i ~/.tmp/vscode.deb` | ||
|
||
#### Snap Package Method | ||
|
||
1. `sudo snap install code --classic` | ||
|
||
### Install PhpStorm | ||
|
||
#### Snap Package Method | ||
|
||
1. `sudo snap install phpstorm --classic` | ||
|
||
|
||
## MariaDB Setup | ||
*Default install instructions after package has been installed* | ||
``` | ||
To start mysqld at boot time you have to copy | ||
support-files/mysql.server to the right place for your system | ||
PLEASE REMEMBER TO SET A PASSWORD FOR THE MariaDB root USER ! | ||
To do so, start the server, then issue the following commands: | ||
'/usr/bin/mysqladmin' -u root password 'new-password' | ||
'/usr/bin/mysqladmin' -u root -h localhost password 'new-password' | ||
Alternatively you can run: | ||
'/usr/bin/mysql_secure_installation' | ||
which will also give you the option of removing the test | ||
databases and anonymous user created by default. This is | ||
strongly recommended for production servers. | ||
See the MariaDB Knowledgebase at http://mariadb.com/kb or the | ||
MySQL manual for more instructions. | ||
You can start the MariaDB daemon with: | ||
/usr/bin/mysqld_safe --datadir='/var/lib/mysql' | ||
Please report any problems at http://mariadb.org/jira | ||
The latest information about MariaDB is available at http://mariadb.org/. | ||
You can find additional information about the MySQL part at: | ||
http://dev.mysql.com | ||
Consider joining MariaDB's strong and vibrant community: | ||
https://mariadb.org/get-involved/ | ||
``` | ||
|
||
### PhpMyAdmin Installation | ||
|
||
1. `sudo apt install phpmyadmin` | ||
2. `sudo ln -s /usr/share/phpmyadmin /var/www/html/mdb-admin` | ||
3. | ||
|