Permalink
Browse files

Added Circle CI deploy files

  • Loading branch information...
1 parent f765459 commit e7d8fc2a5ffb996fa9d6adda432cd38b5f23a7b5 Pat Cox committed Mar 10, 2015
Showing with 80 additions and 0 deletions.
  1. +14 −0 Dockerfile
  2. +2 −0 bin/deploy_qa.sh
  3. +18 −0 circle.yml
  4. +46 −0 nginx.conf
View
@@ -0,0 +1,14 @@
+FROM progrium/busybox
+
+MAINTAINER CenturyLink Labs
+
+RUN opkg-install nginx bash
+
+RUN mkdir /var/lib/nginx
+ADD nginx.conf /etc/nginx/nginx.conf
+
+EXPOSE 80 443 9000
+
+ADD /dist /data/dist
+
+CMD ["/usr/sbin/nginx"]
View
@@ -0,0 +1,2 @@
+#!/bin/bash
+ssh root@8.22.8.236 "docker rm -f imagelayers_ui; docker rmi -f centurylink/imagelayers-ui:qa; docker pull centurylink/imagelayers-ui:qa; docker run -d --name imagelayers_ui -p 9000:9000 centurylink/imagelayers-ui:qa"
View
@@ -16,3 +16,21 @@ dependencies:
test:
override:
- grunt test
+
+deployment:
+ hub:
+ branch: master
+ commands:
+ - export IMAGE_LAYERS_API=http://8.22.8.236:8888 && grunt build
+ - docker build -t centurylink/imagelayers-ui:qa .
+ - docker login -e $DOCKER_EMAIL -u $DOCKER_USER -p $DOCKER_PASS
+ - docker push centurylink/imagelayers-ui:qa
+ - ./bin/deploy_qa.sh
+ Production:
+ branch: release
+ commands:
+ - export IMAGE_LAYERS_API=http://x.x.x.x:xxxx && grunt build
+ - docker build -t centurylink/imagelayers-ui:latest .
+ - docker login -e $DOCKER_EMAIL -u $DOCKER_USER -p $DOCKER_PASS
+ - docker push centurylink/imagelayers-ui:latest
+ - ./bin/deploy_pro.sh
View
@@ -0,0 +1,46 @@
+user nobody nogroup;
+worker_processes 1;
+daemon off;
+error_log /dev/stderr info;
+
+events {
+ worker_connections 1024;
+}
+
+http {
+ include mime.types;
+
+ log_format main '$remote_addr - $remote_user [$time_local] "$request" '
+ '$status $body_bytes_sent "$http_referer" '
+ '"$http_user_agent" "$http_x_forwarded_for"';
+
+ access_log /dev/stdout main;
+
+ sendfile on;
+ tcp_nopush on;
+
+ keepalive_timeout 65;
+
+ gzip on;
+
+ server {
+ listen 80;
+ server_name localhost;
+
+ location / {
+ root /data/dist;
+ index index.html index.htm;
+ }
+
+ #error_page 404 /404.html;
+
+ # redirect server error pages to the static page /50x.html
+ #
+ error_page 500 502 503 504 /50x.html;
+ location = /50x.html {
+ root html;
+ }
+
+ }
+
+}

0 comments on commit e7d8fc2

Please sign in to comment.