Skip to content

Commit

Permalink
Fix: github pages build (#195)
Browse files Browse the repository at this point in the history
* fixing the github pages to use readme

* fixing getting started to point to the readme

* removing empty lines

* adding raw and endraw tags

* fixing mkdocs file

* fixing ci file to install deps

* fixing syntax error in the pip install

* adding back the index file

* fixing broken link

* fixing github org

* adding gatekeeper to a dedicated addon module

* adding the Kubernetes and Control Plane dashboards

* adding the argocd pod monitor

* adjusting podmonitor to servicemonitor
  • Loading branch information
edgarsilva948 authored Jun 3, 2024
1 parent 042adab commit f126c12
Show file tree
Hide file tree
Showing 8 changed files with 100 additions and 16 deletions.
9 changes: 7 additions & 2 deletions .github/workflows/publish-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,13 @@ jobs:
python -m pip install --upgrade pip
python -m pip install mkdocs-material==9.5.21 \
mkdocs-include-markdown-plugin==6.0.6 \
mkdocs-awesome-pages-plugin==2.9.2
mkdocs-awesome-pages-plugin==2.9.2 \
mkdocs-glightbox==0.1.0 \
mkdocs-minify-plugin==0.8.0 \
mkdocs-material-extensions==1.3.1 \
pillow==10.3.0 \
cairosvg==2.7.1
- name: git config
run: |
git config --local user.email "action@github.com"
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,5 @@ kubeconfig_*
*.tfplan

cluster-keys.json

.vscode
30 changes: 23 additions & 7 deletions bootstrap/terraform/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -159,12 +159,6 @@ module "eks_blueprints_addons" {
crossplane_kubernetes_provider_enable = local.kubernetes_provider.enable
})]
}
enable_gatekeeper = true
gatekeeper = {
wait = true
wait_for_jobs = true
timeout = "600"
}

enable_metrics_server = true
enable_aws_load_balancer_controller = true
Expand All @@ -180,6 +174,26 @@ module "eks_blueprints_addons" {
depends_on = [module.eks.eks_managed_node_groups]
}

#---------------------------------------------------------------
# Gatekeeper
#---------------------------------------------------------------
module "gatekeeper" {
source = "aws-ia/eks-blueprints-addon/aws"
version = "1.1.1"

name = "gatekeeper"
description = "A Helm chart to deploy gatekeeper project"
namespace = "gatekeeper-system"
create_namespace = true
chart = "gatekeeper"
chart_version = "3.16.3"
repository = "https://open-policy-agent.github.io/gatekeeper/charts"
wait = true
timeout = "600"

depends_on = [module.eks_blueprints_addons]
}

#---------------------------------------------------------------
# Crossplane
#---------------------------------------------------------------
Expand All @@ -194,9 +208,11 @@ module "crossplane" {
chart = "crossplane"
chart_version = "1.16.0"
repository = "https://charts.crossplane.io/stable/"
wait = true
timeout = "600"
values = [file("${path.module}/values/crossplane.yaml")]

depends_on = [module.eks.eks_managed_node_groups]
depends_on = [module.eks_blueprints_addons]
}

resource "kubectl_manifest" "environmentconfig" {
Expand Down
18 changes: 18 additions & 0 deletions bootstrap/terraform/values/prometheus.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,16 @@ prometheus:
podMetricsEndpoints:
- port: "metrics"
selector: {}
additionalServiceMonitors:
- name: "argocd"
namespaceSelector:
matchNames:
- "argocd"
endpoints:
- port: "metrics"
selector:
matchLabels:
prometheus.io/scrape: "true"
grafana:
service:
type: "LoadBalancer"
Expand Down Expand Up @@ -56,3 +66,11 @@ grafana:
gnetId: 14584
revision: 1
datasource: prometheusdatasource
eks:
gnetId: 14623
revision: 1
datasource: prometheusdatasource
ekscontrolplane:
gnetId: 21192
revision: 1
datasource: prometheusdatasource
4 changes: 1 addition & 3 deletions docs/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,7 @@ Ensure that you have installed the following tools locally:

### terraform

1. For consuming Crossplane Blueprints, please see the [Getting Started](https://awslabs.github.io/crossplane-on-eks/#getting-started) section. For exploring and trying out the patterns provided, please
clone the project locally to quickly get up and running with a pattern. After cloning the project locally, `cd` into the pattern
directory of your choice.
1. For consuming Crossplane Blueprints, please see the [Getting Started](https://awslabs.github.io/crossplane-on-eks/getting-started/) section. For exploring and trying out the patterns provided, please clone the project locally to quickly get up and running with a pattern. After cloning the project locally, `cd` into the pattern directory of your choice.

2. To provision the pattern, the typical steps of execution are as follows:

Expand Down
2 changes: 1 addition & 1 deletion docs/index.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{%
include-markdown "../README.md"
%}
%}
3 changes: 3 additions & 0 deletions docs/patterns/vault-integration.md
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,7 @@ vault write auth/kubernetes/role/crossplane \
For our test cases to work, we need to configure additional Vault policy and role. Run the following commands in your vault pod or VM.

```bash
# {% raw %}
# create policy and role for applications to use.
ACCESSOR=$(vault auth list | grep kubernetes | tr -s ' ' | cut -d ' ' -f3)

Expand All @@ -142,6 +143,8 @@ vault write auth/kubernetes/role/k8s-application \
bound_service_account_namespaces="*" \
policies=k8s-application \
ttl=1h

# {% endraw %}
```

## Install and configure Crossplane
Expand Down
48 changes: 45 additions & 3 deletions mkdocs.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
site_name: Amazon Crossplane Blueprints
docs_dir: docs/
docs_dir: docs
copyright: Copyright © Amazon 2024
site_author: AWS
site_url: https://awslabs.github.io/crossplane-on-eks/
Expand All @@ -13,8 +13,20 @@ theme:
font:
text: ember
palette:
primary: orange
accent: orange
- media: "(prefers-color-scheme: light)"
scheme: default
toggle:
icon: material/weather-night
name: Switch to dark mode
primary: orange
accent: orange
- media: "(prefers-color-scheme: dark)"
scheme: slate
toggle:
icon: material/weather-sunny
name: Switch to light mode
primary: orange
accent: orange
icon:
repo: fontawesome/brands/github
admonition:
Expand All @@ -31,13 +43,32 @@ theme:
example: octicons/beaker-16
quote: octicons/quote-16
features:
- header.autohide
- navigation.tabs.sticky
- navigation.instant
- navigation.sections
- navigation.top
- search.highlight
- search.share
- search.suggest
- content.code.annotate
- content.tooltips
- content.tabs.link
- content.code.copy
highlightjs: true
hljs_languages:
- yaml
- json
- bash

plugins:
- glightbox
- minify:
minify_html: true
- social:
cards: true
cards_layout_options:
font_family: Roboto
- include-markdown
- search:
lang:
Expand All @@ -47,6 +78,9 @@ plugins:
extra:
version:
provider: mike
social:
- icon: fontawesome/brands/github-alt
link: https://github.com/awslabs/crossplane-on-eks

markdown_extensions:
- attr_list
Expand All @@ -63,5 +97,13 @@ markdown_extensions:
- pymdownx.inlinehilite
- pymdownx.snippets
- pymdownx.superfences
- pymdownx.tasklist:
custom_checkbox: true
- toc:
permalink: true
- pymdownx.emoji:
emoji_index: !!python/name:materialx.emoji.twemoji
emoji_generator: !!python/name:materialx.emoji.to_svg

extra_javascript:
- https://cdn.jsdelivr.net/npm/@glidejs/glide

0 comments on commit f126c12

Please sign in to comment.