Merge branch 'emine' into 'main'
Use dedicated environment for every one See merge request ansible_env/staging!4
This commit is contained in:
commit
56c3c3ab0c
@ -2,7 +2,9 @@
|
|||||||
|
|
||||||
env: "{{ lookup('env', 'PULUMI_STACK') }}"
|
env: "{{ lookup('env', 'PULUMI_STACK') }}"
|
||||||
application: "{{ lookup('env', 'PULUMI_SUB_STACK') }}"
|
application: "{{ lookup('env', 'PULUMI_SUB_STACK') }}"
|
||||||
|
inventory_remote_user: ubuntu
|
||||||
bastion_group_name: "{{ application }}_bastion"
|
bastion_group_name: "{{ application }}_bastion"
|
||||||
|
base_infrastructure_file_path: "{{ inventory_dir }}/infra/{{ application }}.json"
|
||||||
|
|
||||||
# DNS resolve
|
# DNS resolve
|
||||||
preferred_dns: "8.8.8.8"
|
preferred_dns: "8.8.8.8"
|
||||||
@ -24,26 +26,6 @@ proxy_hostname: "{{ groups[bastion_group_name] | first }}"
|
|||||||
proxy_ip: "{{ hostvars[proxy_hostname].ansible_host }}"
|
proxy_ip: "{{ hostvars[proxy_hostname].ansible_host }}"
|
||||||
proxy_port: 3128
|
proxy_port: 3128
|
||||||
|
|
||||||
# console
|
|
||||||
# console staging
|
|
||||||
console_repo: "git.felcloud.io/billing/billing_website.git"
|
|
||||||
console_branch: "prod"
|
|
||||||
console_image_name: "nexus.felcloud.io/felcloud/console"
|
|
||||||
console_version: 0.1.2
|
|
||||||
|
|
||||||
# console database
|
|
||||||
console_database_name: "billing"
|
|
||||||
console_database_user: "billingW"
|
|
||||||
console_database_passwd: !vault |
|
|
||||||
$ANSIBLE_VAULT;1.1;AES256
|
|
||||||
34646331363564376132633734303661376433386139306438623462386633376635343664663637
|
|
||||||
6465363736346437333965333836643862386565616230330a646333373934343761393932383765
|
|
||||||
66616166663061666563363534646464313430383363613164653337663565333337303334646366
|
|
||||||
3338666262346263650a623037626165363730386462633331393438326131656638626430383939
|
|
||||||
62633637303662666366313236366461613362343961333865646465326532613432393436363335
|
|
||||||
3731366461653937613133383834666632633231646664623363
|
|
||||||
console_database_url: "{{ groups['console_database'][0] }}:27017,{{ groups['console_database'][1] }}:27017,{{ groups['console_database'][2] }}:27017"
|
|
||||||
|
|
||||||
# Keycloak
|
# Keycloak
|
||||||
identity_provider_url: "https://identity.felcloud.io/auth/realms"
|
identity_provider_url: "https://identity.felcloud.io/auth/realms"
|
||||||
keycloak_password: !vault |
|
keycloak_password: !vault |
|
||||||
@ -84,10 +66,18 @@ smtp_passwd: !vault |
|
|||||||
37613930656565306266623537333661613266636365373038663636666439626437
|
37613930656565306266623537333661613266636365373038663636666439626437
|
||||||
|
|
||||||
# docker registry
|
# docker registry
|
||||||
felcloud_docker_registry: "nexus.felcloud.io/felcloud"
|
felcloud_docker_registry: "repository.felcloud.io/felcloud"
|
||||||
|
felcloud_docker_registry_user: cloud
|
||||||
|
felcloud_docker_registry_passwd: !vault |
|
||||||
|
$ANSIBLE_VAULT;1.1;AES256
|
||||||
|
30353938636561343133303061303336653130383363646430616536326131393766646239393530
|
||||||
|
3761626633393637396436386135663034616531663135390a666134363539366465393364306230
|
||||||
|
38656537373438353737323430623462616332373835663837366434343739383765336361326331
|
||||||
|
3330643466643730660a636236376133323730336561643532393130646639386263623263323339
|
||||||
|
6563
|
||||||
|
|
||||||
# mongodb global
|
## mongodb global
|
||||||
mongodb_replicaset_name: "rs0"
|
#mongodb_replicaset_name: "rs0"
|
||||||
mongodb_script_local_config_path: "mongo-scripts"
|
#mongodb_script_local_config_path: "mongo-scripts"
|
||||||
mongodb_list_js_scripts:
|
#mongodb_list_js_scripts:
|
||||||
- "03_initaira.js"
|
# - "03_initaira.js"
|
||||||
|
84
group_vars/emine
Normal file
84
group_vars/emine
Normal file
@ -0,0 +1,84 @@
|
|||||||
|
---
|
||||||
|
base_infrastructure_file_path: "{{ inventory_dir }}/infra/emine.json"
|
||||||
|
|
||||||
|
# docker registry
|
||||||
|
felcloud_docker_registry: "repository.felcloud.io/felcloud"
|
||||||
|
|
||||||
|
# haproxy
|
||||||
|
haproxy_local_config_path: "reverse-proxy/haproxy.cfg"
|
||||||
|
haproxy_list_tls:
|
||||||
|
- wildcard.felcloud.io
|
||||||
|
haproxy_nbproc: 1
|
||||||
|
public_vip_address:
|
||||||
|
- "{{ fip_console.address }}"
|
||||||
|
haproxy_first_tls: "/etc/haproxy/tls/wildcard.felcloud.io.pem"
|
||||||
|
default_backend: "console_emine"
|
||||||
|
haproxy:
|
||||||
|
backends:
|
||||||
|
- name: nosql
|
||||||
|
frontend: "emine-dev-db.felcloud.io"
|
||||||
|
servers:
|
||||||
|
- "acl draw-auth http_auth(basic-auth-list)"
|
||||||
|
- "http-request auth realm draw unless draw-auth"
|
||||||
|
- "server {{ groups['emine_db'][0] }} {{ hostvars[groups['emine_db'][0]]['ansible_host'] }}:3000"
|
||||||
|
- name: console_emine
|
||||||
|
frontend: "emine-dev.felcloud.io"
|
||||||
|
servers:
|
||||||
|
- "server {{ groups['emine_web'][0] }} {{ hostvars[groups['emine_web'][0]]['ansible_host'] }}:8080"
|
||||||
|
|
||||||
|
# mongodb global
|
||||||
|
mongodb_replicaset_name: "rs0"
|
||||||
|
mongodb_script_local_config_path: "mongo-scripts"
|
||||||
|
mongodb_list_js_scripts:
|
||||||
|
- "03_initbilling.js"
|
||||||
|
|
||||||
|
# mongodb
|
||||||
|
mongodb_root_user: root
|
||||||
|
mongodb_root_passwd: !vault |
|
||||||
|
$ANSIBLE_VAULT;1.1;AES256
|
||||||
|
34333139613963386461663666616630336663613631643638626665623137323332323465326632
|
||||||
|
3531313966376633636235373531376534643234306339370a373239393364633663366431386138
|
||||||
|
36663132656663393664316561306262623236326361623935613430346138353731656565396261
|
||||||
|
6564336464303531620a643062623464623634623565366230326531643162323034333635393966
|
||||||
|
37343234643931666635636637396363333432643032333536396538303832346634
|
||||||
|
mongodb_init_database: "admin"
|
||||||
|
|
||||||
|
nosqlclient_user: nosqlclient
|
||||||
|
nosqlclient_passwd: !vault |
|
||||||
|
$ANSIBLE_VAULT;1.1;AES256
|
||||||
|
34323766623465326261326662316230376633366362373938383966613237616232323433613532
|
||||||
|
6165643266333164386330646131396562326262626431320a663437656134633663396137356261
|
||||||
|
35633230633732663566306363326635336633303965343538633836303662386638363535343635
|
||||||
|
3737663437303932610a656434383436626264326566636336396130666265353039313165656331
|
||||||
|
3564
|
||||||
|
nosqlclient_database: "nosqlclient"
|
||||||
|
|
||||||
|
# console database
|
||||||
|
console_database_name: "billing"
|
||||||
|
console_database_user: "billingW"
|
||||||
|
console_database_passwd: !vault |
|
||||||
|
$ANSIBLE_VAULT;1.1;AES256
|
||||||
|
34646331363564376132633734303661376433386139306438623462386633376635343664663637
|
||||||
|
6465363736346437333965333836643862386565616230330a646333373934343761393932383765
|
||||||
|
66616166663061666563363534646464313430383363613164653337663565333337303334646366
|
||||||
|
3338666262346263650a623037626165363730386462633331393438326131656638626430383939
|
||||||
|
62633637303662666366313236366461613362343961333865646465326532613432393436363335
|
||||||
|
3731366461653937613133383834666632633231646664623363
|
||||||
|
console_database_url: "{{ groups['emine_db'][0] }}:27017,{{ groups['emine_db'][1] }}:27017,{{ groups['emine_db'][2] }}:27017"
|
||||||
|
|
||||||
|
# console
|
||||||
|
console_repo: "ssh://git@git.felcloud.io:2224/billing/billing_website.git"
|
||||||
|
console_branch: "prod"
|
||||||
|
console_image_name: "repository.felcloud.io/felcloud/console"
|
||||||
|
console_version: 1.0.0
|
||||||
|
console_container_port: 8080
|
||||||
|
|
||||||
|
# linux users
|
||||||
|
users:
|
||||||
|
- name: emine
|
||||||
|
group: emine
|
||||||
|
groups: sudo
|
||||||
|
shell: '/bin/bash'
|
||||||
|
ssh_pub_keys:
|
||||||
|
- 'ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDQx/ruuz9HUmS44qSMckfpO/Gk6HukIEUO1DfxxiynMMPp6wsWSz799AgeIsu19qfG1T42hMBy1OoBKIJ91YCOKD43zHu5XoleHKZo2kXHHFsQdtZAm4WcRDMzDsbz5gNEboqKStD4bJ+74GORpnVTpypVWX8f2yahTheb38qRpAwmYOCviL4cak2d6RgVi5eWyvGsVJmcd//7301Dg2FH8l+CmSuRKRY6f27fwqvZUsWx8ZJI0z18q8IHAdqyt67WmY6dLYV+8vQLGAo50ElKPTxrIUnOUmiZZI9oaoqemH7hdiSYMUnp/26Ob0xPafcHsJT1+mqS8H3DDMJf5jsEPwSdR+3pnIMm8vwKW6PJVRZPO5p/lugza0XbPTwKWlZeb6poVs1I2pwScedPgVnLMRuWA4rtEamarPlQ2QZS04+2J3TvuOMcHI0vM/T269bTEOk7UghKz5Km3YYPrQVi728zitAc4BOzk5cxJ4GnO+ttEIHWnZT9Vn/slEHNy3NYnB1hX5a5++/fE1xC9KIBLWqiXONDHyPdsoYqrmtkc82rxkyMtwppY9vvAbkWwrSGSiGM7t/EceB2ZlC8EmzNc1tvDaYDmgGEFMDtsOBO6qNVKjxvP8fYdQgzaasarwcbCYG9VgwhEyUJVYM7s9I+VPZhkXI5ZEjXJ0uIHcbU+w== dell-xps'
|
||||||
|
console_url: emine-dev.felcloud.io
|
3
infra/base.json
Normal file
3
infra/base.json
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
"INTERNET_Network_ID": "e8d04c1f-0b49-4e87-a1f3-bea618782c90"
|
||||||
|
}
|
@ -1,6 +1,5 @@
|
|||||||
{
|
{
|
||||||
"application_name": "emine",
|
"application_name": "emine",
|
||||||
"INTERNET_Network_ID": "e8d04c1f-0b49-4e87-a1f3-bea618782c90",
|
|
||||||
"network": [{
|
"network": [{
|
||||||
"name": "emine_network",
|
"name": "emine_network",
|
||||||
"bastion_access": "yes",
|
"bastion_access": "yes",
|
||||||
@ -11,10 +10,8 @@
|
|||||||
"dns_servers": ["8.8.8.8"],
|
"dns_servers": ["8.8.8.8"],
|
||||||
"linked_router": [{"router_name": "emine_router"}]
|
"linked_router": [{"router_name": "emine_router"}]
|
||||||
},
|
},
|
||||||
"port": [{
|
"port": [
|
||||||
"name": "vip_emine",
|
]
|
||||||
"fip_pool": "INTERNET"
|
|
||||||
}]
|
|
||||||
}],
|
}],
|
||||||
"router": [{
|
"router": [{
|
||||||
"router_name": "emine_router",
|
"router_name": "emine_router",
|
||||||
@ -26,23 +23,47 @@
|
|||||||
"security_group": [
|
"security_group": [
|
||||||
],
|
],
|
||||||
"instance": [{
|
"instance": [{
|
||||||
"name": "stg-emine-00",
|
"name": "stg-emine-console-00",
|
||||||
"az": "FR_Roubaix",
|
"az": "FR_Roubaix",
|
||||||
"flavor": "Atto.L",
|
"flavor": "Atto.L",
|
||||||
"image": "Ubuntu 20.04 LTS - Focal",
|
"image": "Ubuntu 20.04 LTS - Focal",
|
||||||
"keypair": "dell XPS",
|
"keypair": "dell XPS",
|
||||||
"security_group": ["all_open"],
|
"security_group": ["all_open"],
|
||||||
"inventory_group": "emine_web",
|
"inventory_group": "emine_web",
|
||||||
"network": [{"name": "emine_network"}]
|
"network": [{"name": "emine_network"}],
|
||||||
|
"fip": [{
|
||||||
|
"floatingip": "fip_console",
|
||||||
|
"pool": "INTERNET"
|
||||||
|
}]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "stg-emine-01",
|
"name": "stg-emine-mongodb-00",
|
||||||
"az": "FR_Roubaix",
|
"az": "FR_Roubaix",
|
||||||
"flavor": "Femto.L",
|
"flavor": "Femto.L",
|
||||||
"image": "Ubuntu 20.04 LTS - Focal",
|
"image": "Ubuntu 20.04 LTS - Focal",
|
||||||
"keypair": "dell XPS",
|
"keypair": "dell XPS",
|
||||||
"security_group": ["all_open"],
|
"security_group": ["all_open"],
|
||||||
"inventory_group": "emine_web",
|
"inventory_group": "emine_db",
|
||||||
|
"network": [{"name": "emine_network"}]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "stg-emine-mongodb-01",
|
||||||
|
"az": "FR_Roubaix",
|
||||||
|
"flavor": "Femto.L",
|
||||||
|
"image": "Ubuntu 20.04 LTS - Focal",
|
||||||
|
"keypair": "dell XPS",
|
||||||
|
"security_group": ["all_open"],
|
||||||
|
"inventory_group": "emine_db",
|
||||||
|
"network": [{"name": "emine_network"}]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "stg-emine-mongodb-02",
|
||||||
|
"az": "FR_Roubaix",
|
||||||
|
"flavor": "Femto.L",
|
||||||
|
"image": "Ubuntu 20.04 LTS - Focal",
|
||||||
|
"keypair": "dell XPS",
|
||||||
|
"security_group": ["all_open"],
|
||||||
|
"inventory_group": "emine_db",
|
||||||
"network": [{"name": "emine_network"}]
|
"network": [{"name": "emine_network"}]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -55,7 +76,7 @@
|
|||||||
"inventory_group": "emine_bastion",
|
"inventory_group": "emine_bastion",
|
||||||
"network": [{"name": "emine_network"}],
|
"network": [{"name": "emine_network"}],
|
||||||
"fip": [{
|
"fip": [{
|
||||||
"floatingip": "fip_emine",
|
"floatingip": "fip_bastion",
|
||||||
"pool": "INTERNET",
|
"pool": "INTERNET",
|
||||||
"bastion_access": "yes"
|
"bastion_access": "yes"
|
||||||
}]
|
}]
|
||||||
|
Loading…
Reference in New Issue
Block a user