Skip to content
This repository was archived by the owner on Jan 23, 2025. It is now read-only.

Commit 34a05ad

Browse files
committed
Prod enviroment details updated
1 parent ff60618 commit 34a05ad

File tree

3 files changed

+161
-3
lines changed

3 files changed

+161
-3
lines changed

.circleci/config.yml

Lines changed: 134 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,130 @@ jobs:
6464
cp -f buildvar-web.conf buildvar.conf
6565
./deploy.sh DEV $VER
6666
#cp ./../buildscript/master_deploy.sh .
67+
"build-qa":
68+
docker:
69+
- image: openjdk:7
70+
steps:
71+
# Initialization.
72+
- run:
73+
name: Installation of build dependencies.
74+
command: |
75+
apt update
76+
apt install -y openssl ant git zip jq
77+
mkdir ~/awscli
78+
cd ~/awscli
79+
curl "https://s3.amazonaws.com/aws-cli/awscli-bundle.zip" -o "awscli-bundle.zip"
80+
unzip awscli-bundle.zip
81+
./awscli-bundle/install -i /usr/local/aws -b /usr/local/bin/aws
82+
cd /usr/share/ant/lib
83+
wget https://repo1.maven.org/maven2/org/codehaus/groovy/groovy-all/1.7.8/groovy-all-1.7.8.jar
84+
wget https://repo1.maven.org/maven2/ant-contrib/ant-contrib/1.0b3/ant-contrib-1.0b3.jar
85+
cd ~
86+
wget http://downloads.sourceforge.net/project/jboss/JBoss/JBoss-4.2.3.GA/jboss-4.2.3.GA-jdk6.zip
87+
unzip jboss-4.2.3.GA-jdk6.zip
88+
cd project
89+
- run:
90+
name: checking out build repo
91+
command: |
92+
git clone --branch master https://github.com/topcoder-platform/tc-deploy-scripts ../buildscript
93+
#git clone --branch master git@github.com:appirio-tech/ops.git ../direct-config-update
94+
#git clone --branch master https://$GITUSER:$GITPASSWD@github.com/appirio-tech/ops ../direct-config-update
95+
- checkout
96+
- run:
97+
name: copying configuration file
98+
command: |
99+
cp ./../buildscript/direct/conf/dev/token.properties.enc .
100+
openssl enc -aes-256-cbc -d -in token.properties.enc -out token.properties -k $SECPASSWD
101+
- run:
102+
name: Installation of build dependencies.
103+
command: |
104+
javac -version
105+
ant -version
106+
aws --version
107+
ant package-direct package-static-direct
108+
- store_artifacts:
109+
path: ./direct.jar
110+
destination: direct.jar
111+
- store_artifacts:
112+
path: ./direct-static-all.jar
113+
destination: direct-static-all.jar
114+
- run:
115+
name: Build Pacakge
116+
command: ./build-package.sh QA
117+
- run:
118+
name: Deployment direct app.
119+
command: |
120+
#cp ./../buildscript/master_deploy.sh .
121+
cp -f buildvar-app.conf buildvar.conf
122+
./deploy.sh QA $VER
123+
- run:
124+
name: Deployment direct web
125+
command: |
126+
cp -f buildvar-web.conf buildvar.conf
127+
./deploy.sh QA $VER
128+
#cp ./../buildscript/master_deploy.sh .
129+
"build-prod":
130+
docker:
131+
- image: openjdk:7
132+
steps:
133+
# Initialization.
134+
- run:
135+
name: Installation of build dependencies.
136+
command: |
137+
apt update
138+
apt install -y openssl ant git zip jq
139+
mkdir ~/awscli
140+
cd ~/awscli
141+
curl "https://s3.amazonaws.com/aws-cli/awscli-bundle.zip" -o "awscli-bundle.zip"
142+
unzip awscli-bundle.zip
143+
./awscli-bundle/install -i /usr/local/aws -b /usr/local/bin/aws
144+
cd /usr/share/ant/lib
145+
wget https://repo1.maven.org/maven2/org/codehaus/groovy/groovy-all/1.7.8/groovy-all-1.7.8.jar
146+
wget https://repo1.maven.org/maven2/ant-contrib/ant-contrib/1.0b3/ant-contrib-1.0b3.jar
147+
cd ~
148+
wget http://downloads.sourceforge.net/project/jboss/JBoss/JBoss-4.2.3.GA/jboss-4.2.3.GA-jdk6.zip
149+
unzip jboss-4.2.3.GA-jdk6.zip
150+
cd project
151+
- run:
152+
name: checking out build repo
153+
command: |
154+
git clone --branch master https://github.com/topcoder-platform/tc-deploy-scripts ../buildscript
155+
#git clone --branch master git@github.com:appirio-tech/ops.git ../direct-config-update
156+
#git clone --branch master https://$GITUSER:$GITPASSWD@github.com/appirio-tech/ops ../direct-config-update
157+
- checkout
158+
- run:
159+
name: copying configuration file
160+
command: |
161+
cp ./../buildscript/direct/conf/dev/token.properties.enc .
162+
openssl enc -aes-256-cbc -d -in token.properties.enc -out token.properties -k $SECPASSWD
163+
- run:
164+
name: Installation of build dependencies.
165+
command: |
166+
javac -version
167+
ant -version
168+
aws --version
169+
ant package-direct package-static-direct
170+
- store_artifacts:
171+
path: ./direct.jar
172+
destination: direct.jar
173+
- store_artifacts:
174+
path: ./direct-static-all.jar
175+
destination: direct-static-all.jar
176+
- run:
177+
name: Build Pacakge
178+
command: ./build-package.sh PROD
179+
- run:
180+
name: Deployment direct app.
181+
command: |
182+
#cp ./../buildscript/master_deploy.sh .
183+
cp -f buildvar-app.conf buildvar.conf
184+
./deploy.sh PROD $VER
185+
- run:
186+
name: Deployment direct web
187+
command: |
188+
cp -f buildvar-web.conf buildvar.conf
189+
./deploy.sh PROD $VER
190+
#cp ./../buildscript/master_deploy.sh .
67191
68192
workflows:
69193
version: 2
@@ -72,4 +196,13 @@ workflows:
72196
- build-dev:
73197
filters:
74198
branches:
75-
only: dev-circleci
199+
only: [dev, dev-circleci]
200+
- build-qa:
201+
filters:
202+
branches:
203+
only: qa
204+
- build-prod:
205+
filters:
206+
branches:
207+
only: master
208+

buildvar-app.conf

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,22 @@
11
APPNAME="direct"
22
PACKAGETYPE="app"
3+
DEPLOY=1
34
DEV_AWS_REGION="us-east-1"
45
DEV_AWS_CD_APPNAME="direct-app"
56
DEV_AWS_CD_DG_NAME="direct-app"
67
DEV_AWS_CD_DG_CONFIGURATION="CodeDeployDefault.AllAtOnce"
78
DEV_AWS_S3_BUCKET="tc-direct-app"
89
DEV_AWS_S3_KEY_LOCATION=""
9-
DEPLOY=1
10+
QA_AWS_REGION="us-east-1"
11+
QA_AWS_CD_APPNAME="direct-app"
12+
QA_AWS_CD_DG_NAME="direct-app"
13+
QA_AWS_CD_DG_CONFIGURATION="CodeDeployDefault.AllAtOnce"
14+
QA_AWS_S3_BUCKET="tc-direct-app-qa"
15+
QA_AWS_S3_KEY_LOCATION=""
16+
PROD_AWS_REGION="us-east-1"
17+
PROD_AWS_CD_APPNAME="direct-app"
18+
PROD_AWS_CD_DG_NAME="direct-app"
19+
PROD_AWS_CD_DG_CONFIGURATION="CodeDeployDefault.AllAtOnce"
20+
PROD_AWS_S3_BUCKET="tc-direct-app-prod"
21+
PROD_AWS_S3_KEY_LOCATION=""
1022

buildvar-web.conf

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,22 @@
11
APPNAME="direct"
22
PACKAGETYPE="web"
3+
DEPLOY=1
34
DEV_AWS_REGION="us-east-1"
45
DEV_AWS_CD_APPNAME="direct-web"
56
DEV_AWS_CD_DG_NAME="direct-web"
67
DEV_AWS_CD_DG_CONFIGURATION="CodeDeployDefault.AllAtOnce"
78
DEV_AWS_S3_BUCKET="tc-direct-web"
89
DEV_AWS_S3_KEY_LOCATION=""
9-
DEPLOY=1
10+
QA_AWS_REGION="us-east-1"
11+
QA_AWS_CD_APPNAME="direct-web"
12+
QA_AWS_CD_DG_NAME="direct-web"
13+
QA_AWS_CD_DG_CONFIGURATION="CodeDeployDefault.AllAtOnce"
14+
QA_AWS_S3_BUCKET="tc-direct-web-qa"
15+
QA_AWS_S3_KEY_LOCATION=""
16+
PROD_AWS_REGION="us-east-1"
17+
PROD_AWS_CD_APPNAME="direct-web"
18+
PROD_AWS_CD_DG_NAME="direct-web"
19+
PROD_AWS_CD_DG_CONFIGURATION="CodeDeployDefault.AllAtOnce"
20+
PROD_AWS_S3_BUCKET="tc-direct-web-prod"
21+
PROD_AWS_S3_KEY_LOCATION=""
22+

0 commit comments

Comments
 (0)