sh Scotch Box供应脚本

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了sh Scotch Box供应脚本相关的知识,希望对你有一定的参考价值。

#!/usr/bin/env bash

echo "Starting the shell script"

cat /var/www/vagrantconfig/.bashrc >> .bashrc

sudo chown -R vagrant $(npm config get prefix)/{lib/node_modules,bin,share}
sudo /usr/local/bin/composer self-update
# -*- mode: ruby -*-
# vi: set ft=ruby :

Vagrant.configure("2") do |config|

    config.vm.box = "scotch/box"
    config.vm.network "private_network", ip: "192.168.33.10"
    config.vm.hostname = "scotchbox"
    config.vm.synced_folder ".", "/var/www", :mount_options => ["dmode=777", "fmode=666"]

    # Optional NFS. Make sure to remove other synced_folder line too
    #config.vm.synced_folder ".", "/var/www", :nfs => { :mount_options => ["dmode=777","fmode=666"] }


    config.vm.provision "shell", path: "./vagrantconfig/provision.sh"

end
# Better Git log
## Thanks Jeffrey Way
alias gl="git log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit"

alias html="cd /var/www/"
alias ..="cd ../"
alias ...="cd ../../"
alias ....="cd ../../../"
alias l="ls -al"
alias ll="ls -hal"
alias ls="ls -Fh"

export PS1="\[\033[36m\]\u\[\033[m\]@\[\033[32m\]\h:\[\033[33;1m\]\w\[\033[m\]$ "
export CLICOLOR=1
export LSCOLORS=ExFxBxDxCxegedabagacad

function cl(){ cd "$@" && ll; }

以上是关于sh Scotch Box供应脚本的主要内容,如果未能解决你的问题,请参考以下文章

Vagrant - 供应脚本不更改目录

使用MySQL Workbench连接到Vagrant Box

Symfony2 和 Twig 在 vagrant box 中的表现

Vagrant Box 镜像准备:Packer 打包 Centos 8.3 系统

Vagrant Box 镜像准备:Packer 打包 Centos 7.9 系统

Vagrant Box 镜像准备:Packer 打包 Centos 6.10 系统