nginx.conf and dockerfile带颜色
wget http://www.vim.org/scripts/download_script.php?src_id=14376 -O nginx.vim
mv nginx.vim /usr/share/vim/vim74/syntax
echo "au BufRead,BufNewFile /application/nginx/* if &ft == '' | setfiletype nginx | endif" >> /usr/share/vim/vim74/filetype.vim #注意路径
docker
/usr/share/vim/vimfiles/doc/dockerfile.txt
*dockerfile.txt* Syntax highlighting for Dockerfiles
Author: Honza Pokorny <https://honza.ca>
License: BSD
INSTALLATION *installation*
Drop it on your Pathogen path and you're all set.
FEATURES *features*
The syntax highlighting includes:
* The directives (e.g. FROM)
* Strings
* Comments
vim:tw=78:et:ft=help:norl:
/usr/share/vim/vimfiles/ftdetect/dockerfile.vim
au BufNewFile,BufRead [Dd]ockerfile,Dockerfile.*,*.Dockerfile set filetype=dockerfile
/usr/share/vim/vimfiles/syntax/dockerfile.vim
if exists("b:current_syntax")
finish
endif
let b:current_syntax = "dockerfile"
syntax case ignore
syntax match dockerfileKeyword /\v^\s*(ONBUILD\s+)?(ADD|ARG|CMD|COPY|ENTRYPOINT|ENV|EXPOSE|FROM|HEALTHCHECK|LABEL|MAINTAINER|RUN|SHELL|STOPSIGNAL|USER|VOLU
ME|WORKDIR)\s/
highlight link dockerfileKeyword Keyword
syntax region dockerfileString start=/\v"/ skip=/\v\\./ end=/\v"/
highlight link dockerfileString String
syntax match dockerfileComment "\v^\s*#.*$"
highlight link dockerfileComment Comment
set commentstring=#\ %s
" match "RUN", "CMD", and "ENTRYPOINT" lines, and parse them as shell
let s:current_syntax = b:current_syntax
unlet b:current_syntax
syntax include @SH syntax/sh.vim
let b:current_syntax = s:current_syntax
syntax region shLine matchgroup=dockerfileKeyword start=/\v^\s*(RUN|CMD|ENTRYPOINT)\s/ end=/\v$/ contains=@SH
nginx.conf and dockerfile带颜色的更多相关文章
- Dockerfile + Nginx.conf文件记录(用于前端项目部署)
Dockerfile + Nginx.conf文件记录(用于前端项目部署) 本教程依据个人理解并经过实际验证为正确,特此记录下来,权当笔记. 注:基于linux操作系统(敏感信息都进行了处理),默认服 ...
- nginx.conf各参数的意义
搬运+翻译至 http://qiita.com/syou007/items/3e2d410bbe65a364b603 /etc/nginx/nginx.conf 记录各个参数的意义 user user ...
- nginx: [emerg] the "ssl" parameter requires ngx_http_ssl_module in /usr/local/nginx/conf/nginx.conf:37
一:开始Nginx的SSL模块 1.1 Nginx如果未开启SSL模块,配置Https时提示错误 1 nginx: [emerg] the "ssl" parameter requ ...
- 构建一个可以统计 qps 的nginx服务的Dockerfile
github 项目地址: https://github.com/SilentCC/nginx_lua_qps_count nginx 是经常会用到的web 服务器,它有出色的并发性能,因此尝尝被用来当 ...
- [NGINX] - 配置文件优化 - NGINX.CONF
Nginx 本文主要针对公司的Nginx负载均衡配置进行解释,配置文件在最下方.因为公司没有使用PHP,所以NGINX里面并没有太多facgi模块相关优化 NGINX.CONF user 语 ...
- nginx: [emerg] the "ssl" parameter requires ngx_http_ssl_module in /usr/local/nginx//conf/nginx.conf:117
SSL相关的配置加到了nginx的配置文件中后,nginx竟然启动不起来了 于是用如下命令测试问题所在: /usr/local/nginx/sbin/nginx -c /usr/local/nginx ...
- the "ssl" parameter requires ngx_http_ssl_module in /usr/local/nginx/conf/nginx.conf
一:开始Nginx的SSL模块 1.1 Nginx如果未开启SSL模块,配置Https时提示错误 原因也很简单,nginx缺少http_ssl_module模块,编译安装的时候带上--with-htt ...
- 【转载】Docker 安装 Nginx 并个性化挂载配置文件 nginx.conf
首先,系统(3.8以上内核的linux)中安装好 Docker 这个运用程序.由于网络原因,我们下载一个Docker官方的镜像需要很长的时间,甚至下载失败.为此,阿里云容器镜像服务提供了官方的镜像站点 ...
- nginx获取头部信息带下划线,获取不到解决方案
nginx获取头部信息带下划线,获取不到解决方案 解决方案: 修改配置文件,进行添加信息如下: underscores_in_headers on; 然后进行重新加载: [root@qa-web co ...
随机推荐
- 无法连接虚拟设备 ide1:0及上不网
无法连接虚拟设备 ide1:0 问题: 启动vmware之后,发现出现无法连接 ide 1:0. 网络查找之后,发现是之前挂载的iso镜像找不到了. 原因: 我把iso镜像放到其他位置. 解决: 指定 ...
- Spring AOP:Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanCreationException
1 报错 Exception encountered during context initialization - cancelling refresh attempt: org.springfra ...
- 轻松搭建ES6开发环境
首先,你要自行查阅什么是ES6和ES5.javascript有什么关系,为什么要编译ES6.废话不多说,just go! 第一步:创建项目并让它成为npm可以管理的仓库. 新建一个项目,名字假设为te ...
- TensorFlow错误ValueError: No gradients provided for any variable
使用TensorFlow训练神经网络的时候,出现以下报错信息: Traceback (most recent call last): File "gan.py", line 1 ...
- BFS,优先队列优化
题意: 'S' : 起点 'T' : 终点 '#' : 毒气室 'B' :氧气 'P':不消耗步数 每次经过毒气室需要一瓶氧气,氧气可以重复获得,但只能带五瓶氧气,问最少步数 solution: HI ...
- 【学习笔记】QT常用类及应用
一.QT基类: QObject 二.QT中常用的库 QT中的类根据功能划分在不同的库中,在用户属性.pro文件中可以看到. 三.Qt基本对话框的使用 常用5类: 通过类名可以直接调用类的静态成员函数. ...
- pytest+allure展示环境信息
allure展示环境信息 要将信息添加到Environment小部件,只需在生成报告之前在目录中创建environment.properties(或environment.xml)文件allure-r ...
- 一首好听的摇滚歌曲(Ever Dream),以及优美的译作
送上一首好听的摇滚歌曲,以及优美的译作.祝大家新年快乐.happy new year! [ti:Ever Dream][ar:Nightwish][al:Century Child][by:吖光] ...
- TCP/IP 和 和 DoD 模型
TCP/IP 模型也被称作 DoD 模型(Department of Defense Model).TCP/IP 字面上代表了两个协议:TCP(传输控制协议)和 IP(网络之间互联协议).TCP/IP ...
- Python input 和 raw_input的区别
转载[http://www.pythonclub.org/python-basic/input] 使用input 和 raw_input 都可以读取控制台的输入,但是input和raw_input在处 ...