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

Commit af1e51f

Browse files
authored
Merge pull request #114 from epiphany-platform/develop
0.2.0 Release
2 parents b33e922 + 0fdc65b commit af1e51f

File tree

233 files changed

+5137
-1056
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

233 files changed

+5137
-1056
lines changed

.dockerignore

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,5 +11,5 @@ certs/
1111
tests/
1212
Dockerfile
1313

14-
data/
15-
build/
14+
core/data/
15+
core/build/

.markdownlint.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
{
22
"MD013": false,
33
"MD029": false,
4+
"MD031": false,
5+
"MD032": false,
46
"MD034": false
57
}

CHANGELOG-0.1.2.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
# Changelog 0.1.1
1+
# Changelog 0.1.2
22

33
## [0.1.2] - 2018-12-05
44

55
### Changed
66

7-
- Kubernetes v1.11.5 installation
7+
- Kubernetes v1.11.5 installation

CHANGELOG-0.2.0.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Changelog 0.2.0
2+
3+
## [0.2.0] - 2019-02-19
4+
5+
### Changed
6+
7+
- Kubernetes v1.13.0 installation
8+
- Filebeat 6.5.4 installation
9+
- RabbitMQ installation inside Kubernetes (clustered RabbitMQ) #17
10+
- RabbitMQ installation outside of Kubernetes (VM) #17
11+
- PostgreSQL installation with replication #16
12+
- Authentication service installation (Keycloak) inside Kubernetes
13+
- Automatic untainting Kubernetes Master when single Master deployed without Nodes #22
14+
- Example applications added to /examples
15+
- Keycloak authentication (dotnet, java, python, javascript) #19
16+
- RabbitMQ/Kafka (dotnet) #50, #39
17+
- Documentation updates
18+
19+
### Fixed
20+
21+
- Filebeat memory consumption when Elasticsearch does not accept data #61

CHANGELOG.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,10 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
77

88
## Current release
99

10-
- [CHANGELOG-0.1.2.md](./CHANGELOG-0.1.2.md)
10+
- [CHANGELOG-0.2.0.md](./CHANGELOG-0.2.0.md)
1111

1212
## Older releases
1313

14-
- [CHANGELOG-0.1.1.md](./CHANGELOG-0.1.1.md)
15-
- [CHANGELOG-0.1.0.md](./CHANGELOG-0.1.0.md)
14+
- [CHANGELOG-0.1.2.md](./CHANGELOG-0.1.2.md)
15+
- [CHANGELOG-0.1.1.md](./CHANGELOG-0.1.1.md)
16+
- [CHANGELOG-0.1.0.md](./CHANGELOG-0.1.0.md)

README.md

Lines changed: 27 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -2,39 +2,46 @@
22

33
## Overview
44

5-
Epiphany at it's core is full automation of Kubernetes and Docker plus additional builtin services such as Kafka for high speed messaging/events, Prometheus for monitoring and Graphana for dashboards, Elasticsearch and Kibana for centralized logging. Other optional services are being evaluated now.
5+
Epiphany at its core is a full automation of Kubernetes and Docker plus additional builtin services such as Kafka for high speed messaging/events, Prometheus for monitoring and Graphana for dashboards, Elasticsearch and Kibana for centralized logging. Other optional services are being evaluated now.
66

77
Epiphany can run on as few as one node (laptop, desktop, server) but the real value comes from running 3 or more nodes for scale and HA. Nodes can be added or removed at will depending on data in the manifest. Everything is data driven so simply changing the manifest data and running the automation will modify the environment.
88

99
We currently use Terraform and Ansible for our automation orchestration. All automation is idempotent so you can run it as many times as you wish and it will maintain the same state unless you change the data. If someone makes a "snow flake" change to the environment (you should never do this) then simply running the automation again will put the environment back to the desired state.
1010

11-
## Table of Contents
11+
## Quickstart
1212

13-
<!-- TOC -->
13+
Fork the `epiphany` repository and modify the yaml's under `core/data/` directory. For example in `data/azure/infrastructure/epiphany-playground/basic-data.yaml` file you will need to modify a few values (like you Azure subscription name, directory path for ssh keys). Once you are done done with `basic-data.yaml` you can execute Epiphany with the command:
14+
15+
```shell
16+
./epiphany -a -b -i -f infrastructure/epiphany-playground -t infrastructure/epiphany-template
17+
```
18+
19+
This setup works on a simplified file that is fine to start with, if you need more control over the infrastructure created you should look at `data/azure/infrastructure/epiphany-bld-apps/data.yaml`.
20+
Execution of this full profile would look like:
1421

15-
- [Epiphany project](docs/home/README.md)
22+
```shell
23+
./epiphany -a -b -i -f infrastructure/epiphany-bld-apps
24+
```
1625

17-
- [How-to guides](docs/home/HOWTO.md)
26+
Find more information using table of contents below - especially the [How-to guides](docs/home/HOWTO.md).
1827

19-
- [Troubleshooting](docs/home/TROUBLESHOOTING.md)
28+
## Documentation
2029

30+
<!-- TOC -->
31+
32+
- Platform
33+
- [Resources](docs/home/RESOURCES.md)
34+
- [How-to guides](docs/home/HOWTO.md)
35+
- [Troubleshooting](docs/home/TROUBLESHOOTING.md)
2136
- Architecture
2237
- [Logical View](docs/architecture/logical-view.md)
23-
2438
- [Process View](docs/architecture/process-view.md)
25-
2639
- [Physical View](docs/architecture/physical-view.md)
27-
28-
- [How-to contribute](docs/home/CONTRIBUTING.md)
29-
30-
- [Workflow to follow](docs/home/GITWORKFLOW.md)
31-
32-
- [Governance model](docs/home/GOVERNANCE.md)
33-
34-
- [Changelog](CHANGELOG.md)
35-
36-
- [Project layout](docs/project_layout.md)
40+
- Project
41+
- [How-to contribute](docs/home/CONTRIBUTING.md)
42+
- [Workflow to follow](docs/home/GITWORKFLOW.md)
43+
- [Governance model](docs/home/GOVERNANCE.md)
44+
- [Notices](docs/home/NOTICES.md)
45+
- [Changelog](CHANGELOG.md)
3746

3847
<!-- TOC -->
39-
40-
---

core/README.md

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,5 @@
1-
# Epiphany
1+
# Core
22

3-
## Overview
3+
This folder contains the Epiphany core.
44

5-
Epiphany at it's core is full automation of Kubernetes and Docker plus additional builtin services such as Kafka for high speed messaging/events, Prometheus for monitoring and Graphana for dashboards, Elasticsearch and Kibana for centralized logging. Other optional services are being evaluated now.
6-
7-
Epiphany can run on as few as one node (laptop, desktop, server) but the real value comes from running 3 or more nodes for scale and HA. Nodes can be added or removed at will depending on data in the manifest. Everything is data driven so simply changing the manifest data and running the automation will modify the environment.
8-
9-
We currently use Terraform and Ansible for our automation orchestration. All automation is idempotent so you can run it as many times as you wish and it will maintain the same state unless you change the data. If someone makes a "snow flake" change to the environment (you should never do this) then simply running the automation again will put the environment back to the desired state.
10-
11-
For the full story, go to [Epiphany documentation](https://github.com/epiphany-platform/docs/README.md).
5+
For the full story, go to [Epiphany documentation](../README.md).

core/assets/images/container48pxvector.svg

Lines changed: 0 additions & 3 deletions
This file was deleted.

core/assets/images/diagrams/playground/epiphany-playground.png

Lines changed: 0 additions & 3 deletions
This file was deleted.

core/assets/images/logos/epiphany.png

Lines changed: 0 additions & 3 deletions
This file was deleted.

core/assets/images/logos/epiphany.svg

Lines changed: 0 additions & 3 deletions
This file was deleted.

core/assets/images/security.png

Lines changed: 0 additions & 3 deletions
This file was deleted.

core/bin/gen_docs.sh

100644100755
File mode changed.

core/bin/template_engine

100644100755
File mode changed.

core/core/src/ansible/deployments.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
---
2+
# Ansible playbook that deploys applications on Kubernetes after cluster creation
3+
4+
- hosts: all
5+
tasks: [ ]
6+
7+
- hosts: deployments
8+
become: true
9+
become_method: sudo
10+
roles:
11+
- deployments

core/core/src/ansible/filebeat.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
---
2-
# Ansible playbook that makes sure the base items for all nodes are installed
2+
# Ansible playbook that installs and configures Filebeat
3+
4+
- hosts: elasticsearch:kibana # To gather facts
5+
tasks: [ ]
36

47
- hosts: filebeat
58
become: true

core/core/src/ansible/roles/common/files/operations.sh

100644100755
File mode changed.

core/core/src/ansible/roles/common/tasks/main.yml

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -73,14 +73,6 @@
7373
- disableswap
7474
notify: restart waagent
7575

76-
- name: Manage {{ admin_user.name }} key
77-
copy:
78-
src: "{{ admin_user.key_path }}"
79-
dest: /home/{{ admin_user.name }}/.ssh/id_rsa
80-
mode: 0600
81-
owner: "{{ admin_user.name }}"
82-
group: "{{ admin_user.name }}"
83-
8476
- name: Disable SELinux at next reboot
8577
selinux:
8678
state: disabled
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
postgresql_database_port: "5432"
2+
configuration_temp_directory: "/home/{{ admin_user.name }}/epiphany-auth"
3+
default_namespace: "default"
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
- name: Clean configs path
2+
file:
3+
state: absent
4+
path: "{{ configuration_temp_directory }}/"
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
- name: Create database for Epiphany Auth Service
2+
delegate_to: "{{ groups['postgresql'] | first }}"
3+
become_user: postgres
4+
postgresql_db:
5+
name: "{{ data.database.name }}"
6+
7+
- name: Add postresql user
8+
delegate_to: "{{ groups['postgresql'] | first }}"
9+
become_user: postgres
10+
postgresql_user:
11+
db: "{{ data.database.name }}"
12+
name: "{{ data.database.user }}"
13+
password: "{{ data.database.password }}"
14+
role_attr_flags: CREATEDB,NOSUPERUSER
15+
expires: infinity
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
- name: Create directory for files
2+
file:
3+
path: "{{ configuration_temp_directory }}"
4+
state: directory
5+
become_user: "{{ admin_user.name }}"
6+
7+
- name: Upload auth-service yaml
8+
become: yes
9+
template:
10+
dest: "{{ configuration_temp_directory }}/{{ auth_service_name }}-{{ namespace_name }}.yml"
11+
src: auth-service/auth-service.yml.j2
12+
owner: "{{ admin_user.name }}"
13+
group: "{{ admin_user.name }}"
14+
mode: 0644
15+
16+
- name: Apply Epiphany Auth Service deployment
17+
shell: kubectl apply --kubeconfig=/home/{{ admin_user.name }}/.kube/config -f {{ configuration_temp_directory }}/{{ auth_service_name }}-{{ namespace_name }}.yml
18+
become_user: "{{ admin_user.name }}"
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
- name: Include validation
2+
include_tasks: "validation.yml"
3+
4+
- name: Include database configuration when Epiphany storage used
5+
include_tasks: "configure-database.yml"
6+
when: data.database.address is undefined
7+
8+
- name: Include variables setup
9+
include_tasks: "set-variables.yml"
10+
11+
- name: Include service creation
12+
include_tasks: "create-service.yml"
13+
14+
- name: Include cleanup tasks
15+
include_tasks: "cleanup.yml"
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
- name: Set storage address if not set
2+
set_fact:
3+
auth_service_db_address: "{{ data.database.address | default(hostvars[groups['postgresql'][0]]['ansible_default_ipv4']['address']) }}"
4+
5+
- name: Set storage port if not set
6+
set_fact:
7+
auth_service_db_port: "{{ data.database.port | default(postgresql_database_port) }}"
8+
9+
- name: Set namespace variable
10+
set_fact:
11+
namespace_name: "{{ data.service.namespace | default(default_namespace) | lower }}" # Kubernetes (as of v1.11) accepts only lowercase namespace names.
12+
13+
- name: Set service name variable if set
14+
set_fact:
15+
auth_service_name: "{{ data.service.name | lower }}" # Kubernetes (as of v1.11) accepts only lowercase service names.
16+
when: data.service.name is defined
17+
18+
- name: Set service name variable for default
19+
set_fact:
20+
auth_service_name: "as-{{ namespace_name }}" # Kubernetes (as of v1.11) accepts only lowercase service names.
21+
when: data.service.name is undefined
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
- name: Verify storage configuration
2+
assert:
3+
that: "not ({{ groups['postgresql'] | length }} == 0 and data.database.address is not defined)"
4+
msg: "At least one postgresql component or database address has to be defined."
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
- name: Clean configs path
3+
file:
4+
state: absent
5+
path: "{{ configuration_temp_directory }}/"
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
---
2+
- name: Upload namespace yaml definition
3+
become: yes
4+
template:
5+
dest: "{{ configuration_temp_directory }}/{{ rabbitmq_service_name }}-ns-{{ namespace_name }}.yml"
6+
src: rabbitmq/rabbitmq-namespace.yml.j2
7+
owner: "{{ admin_user.name }}"
8+
group: "{{ admin_user.name }}"
9+
mode: 0644
10+
11+
- name: Apply namespace
12+
shell: kubectl apply --kubeconfig=/home/{{ admin_user.name }}/.kube/config -f {{ configuration_temp_directory }}/{{ rabbitmq_service_name }}-ns-{{ namespace_name }}.yml
13+
become_user: "{{ admin_user.name }}"
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
---
2+
- name: Upload rbac yaml definition
3+
become: yes
4+
template:
5+
dest: "{{ configuration_temp_directory }}/{{ rabbitmq_service_name }}-rbac-{{ namespace_name }}.yml"
6+
src: rabbitmq/rabbitmq-rbac.yml.j2
7+
owner: "{{ admin_user.name }}"
8+
group: "{{ admin_user.name }}"
9+
mode: 0644
10+
11+
- name: Apply rbac
12+
shell: kubectl apply --kubeconfig=/home/{{ admin_user.name }}/.kube/config -f {{ configuration_temp_directory }}/{{ rabbitmq_service_name }}-rbac-{{ namespace_name }}.yml
13+
become_user: "{{ admin_user.name }}"
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
---
2+
- name: Upload RabbitMQ service yaml
3+
become: yes
4+
template:
5+
dest: "{{ configuration_temp_directory }}/{{ rabbitmq_service_name }}-{{ namespace_name }}.yml"
6+
src: rabbitmq/rabbitmq.yml.j2
7+
owner: "{{ admin_user.name }}"
8+
group: "{{ admin_user.name }}"
9+
mode: 0644
10+
11+
- name: Apply RabbitMQ deployment
12+
shell: kubectl apply --kubeconfig=/home/{{ admin_user.name }}/.kube/config -f {{ configuration_temp_directory }}/{{ rabbitmq_service_name }}-{{ namespace_name }}.yml
13+
become_user: "{{ admin_user.name }}"
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
---
2+
- name: Include variables setup
3+
include_tasks: "set-variables.yml"
4+
5+
- name: Create temp directory for files
6+
file:
7+
path: "{{ configuration_temp_directory }}"
8+
state: directory
9+
become_user: "{{ admin_user.name }}"
10+
11+
- name: Include namespace creation
12+
include_tasks: "create-namespace.yml"
13+
14+
- name: Include rbac creation
15+
include_tasks: "create-rbac.yml"
16+
17+
- name: Include erlang cookie handling
18+
include_tasks: "set-erlang-cookie.yml"
19+
20+
- name: Include service creation
21+
include_tasks: "create-service.yml"
22+
23+
- name: Include cleanup tasks
24+
include_tasks: "cleanup.yml"

0 commit comments

Comments
 (0)