Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reorganize Documentation For a Better Learning Journey #612

Merged
merged 151 commits into from
Jun 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
151 commits
Select commit Hold shift + click to select a range
ce5e0e8
reorganize sidebar to help the user on their journey
osterman Jun 1, 2024
3c4d585
Another big sweep of reorganization
osterman Jun 1, 2024
e31d927
wording
osterman Jun 1, 2024
58ab1c9
Refactor content for vendoring
osterman Jun 2, 2024
6c0b558
fix colors of admonitons, add page for validating
osterman Jun 2, 2024
0105c23
use a blueish info bg
osterman Jun 2, 2024
cffbed9
fix wording
osterman Jun 2, 2024
c860eff
add latest atmos version to nav bar. fix broken links
osterman Jun 2, 2024
ec4f7f5
Add community pages
osterman Jun 2, 2024
af13d72
Add a pillbox component. Correct usage of className.
osterman Jun 3, 2024
5e7f91f
auto collapse sidebar. fix mobile menu background filter
osterman Jun 3, 2024
bab79c5
reorganize documentation for integrations
osterman Jun 5, 2024
8a48db9
consolidate pages
osterman Jun 5, 2024
ff33fdc
wip simple tutorial
osterman Jun 6, 2024
5c71f2e
add key points to simple quickstart
osterman Jun 6, 2024
748873d
Refactor valdiation into OPA/JSON schema. Refactor CSS into component…
osterman Jun 7, 2024
c641ea1
document why atmos
osterman Jun 8, 2024
12bd2f9
Add more content about the stages of terraform adoption
osterman Jun 8, 2024
3fd0dae
more best practices
osterman Jun 8, 2024
aaac4d5
fix links, add diagram to explain concepts
osterman Jun 9, 2024
b1d9681
styling mermaid. add some more diagrams
osterman Jun 10, 2024
5d4aaea
fill out more content
osterman Jun 10, 2024
794b534
add intros
osterman Jun 10, 2024
ea120de
add intros
osterman Jun 11, 2024
f61c071
clean up
osterman Jun 11, 2024
49c29aa
fix broken links. add component for definitions so we can explain imp…
osterman Jun 11, 2024
fc204d8
add demos (wip)
osterman Jun 11, 2024
c43e016
add demo components and stubs
osterman Jun 11, 2024
269f381
add localstack demo
osterman Jun 12, 2024
e7262c6
updates
aknysh Jun 12, 2024
b5f7e72
working localstack demo
osterman Jun 12, 2024
0749b5d
add devcontainer
osterman Jun 12, 2024
3d3d14e
add codespace badge
osterman Jun 12, 2024
46e27bb
add codespace badge
osterman Jun 12, 2024
d07bca6
add startup file
osterman Jun 12, 2024
dcfe010
add envrc
osterman Jun 12, 2024
e0f3fea
install terraform and direnv
osterman Jun 12, 2024
263c416
fix deprecation;
osterman Jun 12, 2024
f8a39b8
Improve startup experience
osterman Jun 12, 2024
72cd540
Add README
osterman Jun 12, 2024
582fd91
move back to bash
osterman Jun 12, 2024
7882817
go back to zsh
osterman Jun 12, 2024
7fcd33a
add starship
osterman Jun 12, 2024
db3a492
tune settings
osterman Jun 13, 2024
ca85a5b
customize title. start composition
osterman Jun 13, 2024
34fb3b5
get docker socket working
osterman Jun 13, 2024
bf01e31
try to get yaml schema validation working
osterman Jun 13, 2024
75aeec0
finally fix yaml.schema
osterman Jun 13, 2024
5013370
try to fix docker compose
osterman Jun 13, 2024
70737f2
add missing executable bit
osterman Jun 13, 2024
0c1516a
Unset AWS_PROFILE
osterman Jun 13, 2024
ddc466f
eliminate warnings
osterman Jun 13, 2024
cf77fc7
switch to docker compose from single docker build
osterman Jun 13, 2024
444d057
use links
osterman Jun 13, 2024
897fd25
change workspace path
osterman Jun 13, 2024
ed1e941
test a basic setup
osterman Jun 13, 2024
b85593f
remove orphans
osterman Jun 13, 2024
b2fe353
enhance docker compose for ux
osterman Jun 13, 2024
4db8c91
fix command invocation
osterman Jun 13, 2024
4301ec0
add a working k3s
osterman Jun 14, 2024
49133ab
Add CTAs
osterman Jun 14, 2024
741b2f6
rebuild readme
osterman Jun 14, 2024
23f678b
rebuild readme
osterman Jun 14, 2024
b19a847
rebuild readme
osterman Jun 14, 2024
0b1bda5
rebuild readme
osterman Jun 14, 2024
4cb8f11
attempt restore terminals
osterman Jun 14, 2024
a3f1f2d
abandoned the restore terminals approach
osterman Jun 14, 2024
b37f60d
celebrate in zshrc instead. use screen to detach processes and hopefu…
osterman Jun 14, 2024
1ebd5ba
install screen, always celebraet
osterman Jun 14, 2024
9fdc68b
install screen
osterman Jun 14, 2024
28e7e3a
fixes for k3s
osterman Jun 14, 2024
08ea737
set log files
osterman Jun 14, 2024
4a53b16
fix host routing
osterman Jun 14, 2024
261f1ba
helmfile values
osterman Jun 14, 2024
b27c76a
semi-working helmfile. atmos needs tweaks so it is not EKS specific
osterman Jun 14, 2024
6f03245
add example on context provider
osterman Jun 14, 2024
1ec01d9
wip github tests of demos
osterman Jun 15, 2024
99ce6dd
use latest artifact action, set better job names, chmod
osterman Jun 15, 2024
6e9ca68
fix upload artifact version
osterman Jun 15, 2024
d0221dc
lint demos
osterman Jun 15, 2024
ff62abd
fix formatting
osterman Jun 15, 2024
32a79ae
implement tests for demo-component-versions
osterman Jun 15, 2024
232afe3
reduce tests
osterman Jun 15, 2024
4a820ee
add demo-atlantis
osterman Jun 15, 2024
0bda061
add tests to demo-context
osterman Jun 15, 2024
13d2dfd
fix linting problem
osterman Jun 15, 2024
b991ce9
update tests
osterman Jun 15, 2024
65c61ff
add missing schema
osterman Jun 15, 2024
91f2c5f
odd, kustomize exists already
osterman Jun 15, 2024
45797c3
add missing schema
osterman Jun 15, 2024
bde4dfb
add missing schema
osterman Jun 15, 2024
fff4ad8
upgrade dependencies
osterman Jun 15, 2024
d45fd4d
disable schema validation for helmfile
osterman Jun 15, 2024
47bbce4
enable state backend for localstack. write a default aws profile.
osterman Jun 15, 2024
6212562
add missing directory
osterman Jun 15, 2024
ea2db77
fix case sensitive import
osterman Jun 15, 2024
0159a93
switch to local state
osterman Jun 15, 2024
9604d77
test service
osterman Jun 15, 2024
a08f5ef
remove github action
osterman Jun 15, 2024
5f15ac0
attempt to run k3s as a service
osterman Jun 15, 2024
24a0a8c
attempt to run k3s as a service
osterman Jun 15, 2024
c3f9ca6
attempt to run k3s as a service
osterman Jun 15, 2024
5bd8cf6
fix entrypoint
osterman Jun 15, 2024
770aa05
fix entrypoint
osterman Jun 15, 2024
5594e71
find kubeconfig
osterman Jun 15, 2024
35b3b87
find kubeconfig
osterman Jun 15, 2024
0e1adf0
find kubeconfig
osterman Jun 15, 2024
e9d080b
find kubeconfig
osterman Jun 15, 2024
25ece1f
find kubeconfig
osterman Jun 15, 2024
d5da63f
find kubeconfig
osterman Jun 15, 2024
a0fc111
use docker compose instead
osterman Jun 15, 2024
f41fbcd
use docker compose instead
osterman Jun 15, 2024
30b70f6
find kubeconfig
osterman Jun 15, 2024
bf05302
use docker compose instead
osterman Jun 15, 2024
f8aacfb
use docker compose instead
osterman Jun 15, 2024
cf8d4d8
fix broken links
osterman Jun 16, 2024
2c91696
implemnet action cards, fix broken links
osterman Jun 16, 2024
bb67d22
fix slides
osterman Jun 16, 2024
d5a5b89
clean up docs for data sources and functions
osterman Jun 17, 2024
5918d9d
clean up docs for data sources and functions
osterman Jun 17, 2024
0660f8c
refactor templating content
osterman Jun 17, 2024
9981747
relocate mixins
osterman Jun 17, 2024
9078378
rebuild readme
osterman Jun 17, 2024
3d8d23c
update installation instructions
osterman Jun 17, 2024
515c988
reformat design patterns and github actions, add missing page for dri…
osterman Jun 18, 2024
d03acb6
Updated project docs
osterman Jun 19, 2024
284aadf
add action cards
osterman Jun 19, 2024
3614d3a
fix grammar
osterman Jun 19, 2024
44e0c91
trim trailing whitespace
osterman Jun 19, 2024
6f5498a
fix grammar
osterman Jun 19, 2024
35c5f78
fix grammar
osterman Jun 19, 2024
e0ef8f8
Incremental update
osterman Jun 19, 2024
c9c4be8
Incremental update
osterman Jun 19, 2024
6c7fe5e
content updates
osterman Jun 20, 2024
a022e83
add missing remediation doc
osterman Jun 20, 2024
caeda42
start embedding examples
osterman Jun 20, 2024
d1b785a
reorganize quickstarts
osterman Jun 20, 2024
91cbae2
remove `<br/>` tags
osterman Jun 20, 2024
8b11b67
remove `<br/>` tags
osterman Jun 20, 2024
8dd1573
clean up
osterman Jun 20, 2024
b5f70d2
explain how to share data
osterman Jun 21, 2024
58e0279
fix toc line height
osterman Jun 21, 2024
77efea1
animate command when passed
osterman Jun 21, 2024
803f217
Update CTAs for simple quick start
osterman Jun 21, 2024
5b5dff1
finish vendor documentation
osterman Jun 21, 2024
e59f9f4
Add PostHog
osterman Jun 21, 2024
09c68ee
install sentry
osterman Jun 21, 2024
0a84af3
disable helmfile test
osterman Jun 25, 2024
69e7bcc
fix helmfile test
osterman Jun 25, 2024
6ff7bbc
add debug log level
osterman Jun 25, 2024
410326e
change order of arguments
osterman Jun 25, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
51 changes: 51 additions & 0 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
FROM golang:1.22 AS confetty

# Set the working directory
WORKDIR /app

# Install the confetty application
RUN go install github.com/maaslalani/confetty@latest

FROM mcr.microsoft.com/vscode/devcontainers/base:debian

# Copy the binary from the builder stage
COPY --from=confetty /go/bin/confetty /usr/local/bin/confetty

# Install Docker CLI and Docker Compose plugin
RUN apt-get update && \
apt-get install -y ca-certificates curl gnupg lsb-release apt-utils direnv screen && \
mkdir -p /etc/apt/keyrings && \
curl -fsSL https://download.docker.com/linux/debian/gpg | gpg --dearmor -o /etc/apt/keyrings/docker.gpg && \
echo \
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/debian \
$(lsb_release -cs) stable" | tee /etc/apt/sources.list.d/docker.list > /dev/null && \
apt-get update && \
apt-get install -y docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin && \
rm -rf /var/lib/apt/lists/*

# Ensure the vscode user can access the Docker socket, and change the shell to zsh
RUN usermod -aG docker vscode && \
chsh -s /bin/zsh vscode

# Install the starship prompt
RUN curl -sS https://starship.rs/install.sh | sh -s -- -y

# Install OpenTofu
RUN curl -1sSLf 'https://get.opentofu.org/install-opentofu.sh' | bash -s -- --root-method none --install-method deb

# Install Kustomize binary (required by Helmfile)
RUN curl -1sSLf "https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh" | bash -s -- /usr/local/bin

# Install the cloudposse Debian repository
RUN curl -1sLf 'https://dl.cloudsmith.io/public/cloudposse/packages/cfg/setup/bash.deb.sh' | bash

RUN apt-get -y install atmos terraform kubectl helmfile helm k9s stern && \
su - vscode -c "helm plugin install https://github.com/databus23/helm-diff"

# Install the rootfs/ configurations
COPY rootfs/ /

# Direnv permissions
RUN chown -R vscode:vscode /home/vscode/.config && \
chmod -R 755 /home/vscode/.config && \
chmod 644 /home/vscode/.config/direnv/direnvrc
80 changes: 80 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
{
"name": "Atmos Demo Lab",
"forwardPorts": [80, 443],
"portsAttributes": {
"80": {
"label": "Kubernetes Ingress"
},
"443": {
"label": "Kubernetes Ingress (TLS)"
}
},
"security.workspace.trust.emptyWindow": true,
"security.workspace.trust.untrustedFiles": "prompt",
"security.workspace.trust.domain": {
"*.github.com": true,
"*.app.github.dev": true,
"localhost": true
},
"build": {
"dockerfile": "Dockerfile",
"context": "."
},
"hostRequirements": {
"cpus": 8,
"memory": "16gb",
"storage": "32gb"
},
"runArgs": ["-v", "/var/run/docker.sock:/var/run/docker.sock"],
"postCreateCommand": "/workspace/.devcontainer/post-create.sh",
"service": "localstack",
"features": {
"ghcr.io/devcontainers/features/docker-outside-of-docker": {},
/*"ghcr.io/devcontainers/features/go:1": {
"version": "1.22"
},*/
},
"workspaceFolder": "/workspace/examples",
"workspaceMount": "source=${localWorkspaceFolder},target=/workspace,type=bind",

"customizations": {
"vscode": {
"extensions": [
"ms-azuretools.vscode-docker",
"bierner.github-markdown-preview",
"tomasdahlqvist.markdown-admonitions",
"HashiCorp.terraform",
"redhat.vscode-yaml",
"casualjim.gotemplate",
"EditorConfig.EditorConfig"
],
"settings": {
"git.openRepositoryInParentFolders": "always",
"git.autofetch": true,
"git.showProgress": true,
"workbench.startupEditor": "readme",
"workbench.editor.autoLockGroups": {
"readme": "/welcome.md"
},
"workbench.editorAssociations": {
"*.md": "vscode.markdown.preview.editor"
},
"terminal.integrated.tabs.title": "Atmos (${process})",
"terminal.integrated.tabs.description": "${task}${separator}${local}${separator}${cwdFolder}",
"terminal.integrated.shell.linux": "/bin/zsh",
"terminal.integrated.allowWorkspaceConfiguration": true,
"terminal.integrated.commandsToSkipShell": [],
"yaml.schemaStore.enable": true,
"json.schemas": [
],
"yaml.schemas": {
"https://atmos.tools/schemas/atmos/atmos-manifest/1.0/atmos-manifest.json": [
"**/stacks/**/*.yaml",
"!**/stacks/workflows/**/*.yaml",
"!**/stacks/schemas/**/*.yaml"
]
}
}
}
}
}
28 changes: 28 additions & 0 deletions .devcontainer/post-create.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
#!/bin/zsh

# Let's not show what commands the script is running
set +x

# Display a different welcome message for Codespaces
mv /workspace/examples/welcome.md /workspace/examples/README.md

# Use screen to run the following commands in the background so they don’t block startup time
# Note that this also means errors won’t fail the bootstrapping of the container, which can mask issues.

# Install a .envrc file in each example directory (it's ignored in .gitignore)
screen -L -Logfile /tmp/direnv.log -S direnv-setup -dm \
sh -c "find /workspace/examples -mindepth 1 -type d -exec sh -c 'echo show_readme > {}/.envrc' \;"

# Start localstack in the background, since it can take a little bit to start up
cd /workspace/examples/demo-localstack
screen -L -Logfile /tmp/localstack.log -S localstack -dm sh -c 'docker compose up'

# Start k3s in the background, since it can take a little bit to start up
# Note, it will mount . to the container and write the kubeconfig.yaml file
# This should used as the file for KUBECONFIG
cd /workspace/examples/demo-helmfile
screen -L -Logfile /tmp/k3s.log -S k3s -dm sh -c 'docker compose up'

# Since we cannot mount volumes inside of compose, we need to copy the kubeconfig.yaml file to the workspace
export KUBECONFIG=${KUBECONFIG:-/workspace/examples/demo-helmfile/kubeconfig.yaml}
screen -L -Logfile /tmp/kubeconfig.log -S kubeconfig -dm sh -c 'until test -f ${KUBECONFIG}; do docker cp demo-helmfile-server-1:/output/kubeconfig.yaml ${KUBECONFIG}; sleep 1; done; chmod 600 ${KUBECONFIG}'
11 changes: 11 additions & 0 deletions .devcontainer/rootfs/home/vscode/.config/direnv/direnvrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
show_readme() {
if [ -f "./README.md" ]; then
# Check if the README.md file has been touched in the last 60 seconds
last_modified=$(stat -c %Y "./README.md")
current_time=$(date +%s)
if [ $((current_time - last_modified)) -gt 60 ]; then
code "./README.md"
touch "./README.md"
fi
fi
}
48 changes: 48 additions & 0 deletions .devcontainer/rootfs/home/vscode/.config/starship.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
format = """
$username\
$hostname\
$directory\
$git_branch\
$git_state\
$git_status\
$cmd_duration\
$line_break\
$python\
$character"""

command_timeout = 2000

[directory]
style = "blue"

[character]
success_symbol = "[❯](purple)"
error_symbol = "[❯](red)"
vimcmd_symbol = "[❮](green)"

[git_branch]
format = "[$branch]($style)"
style = "bright-black"

[git_status]
format = "[[(*$conflicted$untracked$modified$staged$renamed$deleted)](218) ($ahead_behind$stashed)]($style)"
style = "cyan"
conflicted = "​"
untracked = "​"
modified = "​"
staged = "​"
renamed = "​"
deleted = "​"
stashed = "≡"

[git_state]
format = '\([$state( $progress_current/$progress_total)]($style)\) '
style = "bright-black"

[cmd_duration]
format = "[$duration]($style) "
style = "yellow"

[python]
format = "[$virtualenv]($style) "
style = "bright-black"
12 changes: 12 additions & 0 deletions .devcontainer/rootfs/home/vscode/.zsh_history
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
: 1640995200:0;atmos terraform plan myapp --stack dev
: 1640995201:0;atmos terraform plan myapp --stack staging
: 1640995202:0;atmos terraform plan myapp --stack prod
: 1640995203:0;atmos terraform apply myapp --stack dev
: 1640995204:0;atmos terraform apply myapp --stack staging
: 1640995205:0;atmos terraform apply myapp --stack prod
: 1640995206:0;atmos terraform plan myapp --stack dev
: 1640995207:0;atmos terraform plan myapp --stack staging
: 1640995208:0;atmos terraform plan myapp --stack prod
: 1640995209:0;atmos terraform deploy myapp --stack dev
: 1640995210:0;atmos terraform deploy myapp --stack staging
: 1640995211:0;atmos terraform deploy myapp --stack prod
37 changes: 37 additions & 0 deletions .devcontainer/rootfs/home/vscode/.zshrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
eval "$(direnv hook zsh)"

# VSCode shell integration
[[ "$TERM_PROGRAM" == "vscode" ]] && . "$(code --locate-shell-integration-path zsh)"

export KUBECONFIG=${KUBECONFIG:-/workspace/examples/demo-helmfile/kubeconfig.yaml}

export CODESPACE_HOSTNAME="${CODESPACE_NAME}-80.${GITHUB_CODESPACES_PORT_FORWARDING_DOMAIN}"
export CODESPACE_HTTP_HOSTNAME="${CODESPACE_NAME}-80.${GITHUB_CODESPACES_PORT_FORWARDING_DOMAIN}"
export CODESPACE_HTTPS_HOSTNAME="${CODESPACE_NAME}-443.${GITHUB_CODESPACES_PORT_FORWARDING_DOMAIN}"

export CODESPACE_URL="http://${CODESPACE_HOSTNAME}"
export CODESPACE_HTTP_URL="http://${CODESPACE_HTTP_HOSTNAME}"
export CODESPACE_HTTPS_URL="http://${CODESPACE_HTTPS_HOSTNAME}"

# Install atmos completion
eval $(atmos completion zsh)

# Setup some aliases
alias tree='tree -CAF --gitignore -I ".git" -I "terraform.tfstate*"'
alias bat='bat --style header,numbers --theme="GitHub"'

# Disable directory entry messages
export DIRENV_LOG_FORMAT=""

find /workspace/examples -name '.envrc' -execdir direnv allow \;

# Enable Starship prompt
eval "$(starship init zsh)"

# Celebrate! 🎉
if [ "${TERM}" != "screen.xterm-256color" ]; then
timeout --preserve-status 2 confetty
fi

# Show the version of atmos installed
atmos version
Loading
Loading