text 用于Ubuntu 16.04 LTS(Xenial64)Box的Vagrantfile
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了text 用于Ubuntu 16.04 LTS(Xenial64)Box的Vagrantfile相关的知识,希望对你有一定的参考价值。
Vagrant.configure("2") do |config|
config.vm.box = "ubuntu/xenial64"
# config.vm.box = "centos/7"
# 適宜変更する
config.vm.network "private_network", ip: "10.10.10.10"
# note: `unable to re-open stdin: No such file or directory` occurs if not `export DEBIAN_FRONTEND=noninteractive`
config.vm.provision "shell", inline: <<-SHELL
sudo apt-get -y update
sudo apt-get -y dist-upgrade
sudo locale-gen ja_JP.UTF-8
sudo dpkg-reconfigure locales
# update-locale: Error: invalid locale settings: LANG=ja_JP.UTF-8
# sudo update-locale LANG=ja_JP.UTF-8
sudo timedatectl set-timezone Asia/Tokyo
sudo apt-get install -y language-pack-ja language-pack-ja-base manpages-ja manpages-ja-dev
sudo apt-get install -y build-essential software-properties-common
sudo apt-get install -y wget curl zip unzip git
sudo apt-get install -y source-highlight # less に色を付ける
sudo apt-get install -y nginx
# sudo apt-get install -y apache2 # ポートがバッティングする
sudo apt-get install -y sqlite3 libsqlite3-dev
# PostgreSQL
export MYSQLPW=YOUR_MYSQL_ROOT_PASSWORD
echo "mysql-server mysql-server/root_password password $MYSQLPW" | sudo debconf-set-selections
echo "mysql-server mysql-server/root_password_again password $MYSQLPW" | sudo debconf-set-selections
sudo apt-get -y install mysql-server
# /etc/mysql/conf.d/mysql.cnf と /etc/mysql/mysql.conf.d/mysqld.cnf に utf8mb4 の設定を追加する必要がある
# `/etc/mysql/conf.d/mysql.cnf`: [mysql] default-character-set=utf8mb4
# `/etc/mysql/mysql.conf.d/mysqld.cnf`: [mysqld] character-set-server=utf8mb4
sudo apt-get install -y php php-mysql php-dev php-curl php-fpm php-xml php-mbstring libapache2-mod-php
sudo apt-get install -y default-jdk
sudo apt-get install -y ruby ruby-dev
sudo gem install bundler
sudo apt-get install -y python-pip python3-pip
pip install --upgrade pip
pip install virtualenv
sudo apt-get install -y npm
sudo npm install -g n
sudo n 9.3.0
sudo npm install -g yarn
sudo apt-get install -y tig
sudo apt-get install -y sl
sudo apt-get install -y zsh
sudo apt-get -y autoremove
sudo apt-get -y autoclean
sudo reboot
SHELL
end
以上是关于text 用于Ubuntu 16.04 LTS(Xenial64)Box的Vagrantfile的主要内容,如果未能解决你的问题,请参考以下文章
无法在 Ubuntu 16.04 lts 上运行的 apache 2.4.18 服务器上设置 X-Frame 选项
Ubuntu Desktop 16.04 LTS 下成功配置Jupyter的两个python内核版本(2.7x,3.5x)
无法从 ubuntu 16.04 LTS 卸载节点
Ubuntu 16.04 LTS安装Docker
Install Grafana on Ubuntu 16.04 LTS
ubuntu16.04LTS命令行查看版本号