Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
Dmytro Bogatov
Setup-Manager
Commits
1817b720
Verified
Commit
1817b720
authored
May 09, 2018
by
Dmytro Bogatov
💕
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add cluster and www ingresses.
parent
c4ba1fb8
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
31 additions
and
6 deletions
+31
-6
infra/build-services.sh
infra/build-services.sh
+21
-5
infra/sources/data.sh
infra/sources/data.sh
+3
-1
infra/sources/service/ingress/rule-cluster.yaml
infra/sources/service/ingress/rule-cluster.yaml
+7
-0
infra/sources/service/ingress/rule-domain.yaml
infra/sources/service/ingress/rule-domain.yaml
+0
-0
No files found.
infra/build-services.sh
View file @
1817b720
...
...
@@ -34,18 +34,34 @@ generate-ingress () {
for
url
in
${
URLS
[@]
}
do
echo
" -
$url
"
>>
$DIR
/main.yaml
echo
" - www.
$url
"
>>
$DIR
/main.yaml
done
for
main
in
${
MAIN
[@]
}
do
echo
" -
$NAME
.cluster.
$main
"
>>
$DIR
/main.yaml
done
echo
" rules:"
>>
$DIR
/main.yaml
for
url
in
${
URLS
[@]
}
do
cp
$DIR
/rule.yaml
$DIR
/rule-
$NAME
.yaml
cp
$DIR
/rule-domain.yaml
$DIR
/rule-tmp.yaml
sed
-i
-e
"s#__NAME__#
$NAME
#g"
$DIR
/rule-tmp.yaml
sed
-i
-e
"s#__URL__#
$url
#g"
$DIR
/rule-tmp.yaml
cat
$DIR
/rule-tmp.yaml
>>
$DIR
/main.yaml
done
for
main
in
${
MAIN
[@]
}
do
cp
$DIR
/rule-cluster.yaml
$DIR
/rule-tmp.yaml
sed
-i
-e
"s#__NAME__#
$NAME
#g"
$DIR
/rule-
$NAME
.yaml
sed
-i
-e
"s#__URL__#
$
url
#g"
$DIR
/rule-
$NAME
.yaml
sed
-i
-e
"s#__NAME__#
$NAME
#g"
$DIR
/rule-
tmp
.yaml
sed
-i
-e
"s#__URL__#
$
main
#g"
$DIR
/rule-
tmp
.yaml
cat
$DIR
/rule-
$NAME
.yaml
>>
$DIR
/main.yaml
cat
$DIR
/rule-
tmp
.yaml
>>
$DIR
/main.yaml
done
cp
$DIR
/main.yaml
$DIR
/../ingress.yaml
...
...
@@ -74,7 +90,7 @@ generate-service () {
mkdir
-p
services/
$service
/ingress
cp
sources/service/
{
service,deployment
}
.yaml services/
$service
cp
sources/service/ingress/
{
main,rule
}
.yaml services/
$service
/ingress
cp
sources/service/ingress/
{
main,rule
-
*
}
.yaml services/
$service
/ingress
if
[
"
$service
"
==
"legacy-dbogatov-org"
]
then
...
...
infra/sources/data.sh
View file @
1817b720
...
...
@@ -46,6 +46,7 @@ DOMAINS["dbogatov.org"]=$AVALUE
DOMAINS[
"dmytro.app"
]=
$AVALUE
DOMAINS[
"bogatov.app"
]=
$AVALUE
DOMAINS[
"netwatch.app"
]=
$AVALUE
DOMAINS[
"bogatov.kiev.ua"
]=
$AVALUE
DOMAINS[
"darinagulley.com"
]=
$AVALUE
DOMAINS[
"moon-travel.com.ua"
]=
$AVALUE
...
...
@@ -65,7 +66,8 @@ DOMAINS["votings.net"]=$AVALUE
declare
-A
PLACEHOLDERS
PLACEHOLDERS[
"status-dbogatov-org"
]=
"under-maintenance"
PLACEHOLDERS[
"netwatch-app"
]=
"under-maintenance"
PLACEHOLDERS[
"votings-net"
]=
"under-maintenance"
PLACEHOLDERS[
"res-public-net"
]=
"under-maintenance"
...
...
infra/sources/service/ingress/rule-cluster.yaml
0 → 100644
View file @
1817b720
-
host
:
"
__NAME__.cluster.__URL__"
http
:
paths
:
-
path
:
/
backend
:
serviceName
:
__NAME__
servicePort
:
80
infra/sources/service/ingress/rule.yaml
→
infra/sources/service/ingress/rule
-domain
.yaml
View file @
1817b720
File moved
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment