latest
This commit is contained in:
1 parent
5eeed7568c
commit
f6f6546c5f
9 files changed
+76
-3195
No files matched your search
@@ -0,0 +1,6 @@
|
||||
# Note: You can use any Debian/Ubuntu based image you want.
|
||||
FROM mcr.microsoft.com/devcontainers/base:bullseye
|
||||
|
||||
# [Optional] Uncomment this section to install additional OS packages.
|
||||
# RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \
|
||||
# && apt-get -y install --no-install-recommends <your-package-list-here>
|
||||
@@ -1,21 +1,19 @@
|
||||
// For format details, see https://aka.ms/devcontainer.json. For config options, see the
|
||||
// README at: https://github.com/devcontainers/templates/tree/main/src/alpine
|
||||
// README at: https://github.com/devcontainers/templates/tree/main/src/docker-outside-of-docker-compose
|
||||
{
|
||||
"name": "HomeLab",
|
||||
"image": "mcr.microsoft.com/devcontainers/base:bullseye",
|
||||
"runArgs": ["--network=host"],
|
||||
"name": "Docker from Docker Compose",
|
||||
"dockerComposeFile": "docker-compose.yml",
|
||||
"service": "app",
|
||||
"workspaceFolder": "/workspaces/${localWorkspaceFolderBasename}",
|
||||
"remoteEnv": {
|
||||
"LOCAL_WORKSPACE_FOLDER": "${localWorkspaceFolder}"
|
||||
},
|
||||
"features": {
|
||||
"ghcr.io/devcontainers/features/docker-outside-of-docker:1": {
|
||||
"moby": true,
|
||||
"version": "latest",
|
||||
"dockerDashComposeVersion": "v2"
|
||||
"enableNonRootDocker": "true",
|
||||
"moby": "true"
|
||||
},
|
||||
"ghcr.io/devcontainers/features/kubectl-helm-minikube:1": {
|
||||
"version": "latest",
|
||||
"helm": "latest",
|
||||
"minikube": "latest"
|
||||
},
|
||||
"./local-features/tweaks": {},
|
||||
"ghcr.io/devcontainers/features/common-utils:2": {
|
||||
"installZsh": true,
|
||||
"configureZshAsDefaultShell": true,
|
||||
@@ -25,6 +23,11 @@
|
||||
"userUid": "automatic",
|
||||
"userGid": "automatic"
|
||||
},
|
||||
"ghcr.io/devcontainers/features/kubectl-helm-minikube:1": {
|
||||
"version": "latest",
|
||||
"helm": "latest",
|
||||
"minikube": "none"
|
||||
},
|
||||
"ghcr.io/mpriscella/features/helm-chart-testing:1": {
|
||||
"version": "latest"
|
||||
},
|
||||
@@ -36,8 +39,9 @@
|
||||
"yqVersion": "latest",
|
||||
"gojqVersion": "latest"
|
||||
},
|
||||
"ghcr.io/dhoeric/features/act:1": {},
|
||||
"ghcr.io/rio/features/k3d:1": {}
|
||||
},
|
||||
"postCreateCommand": ".devcontainer/postCreateCommand.sh",
|
||||
"mounts": [
|
||||
{
|
||||
"source": "${env:HOME}${env:USERPROFILE}/.kube",
|
||||
@@ -64,4 +68,4 @@
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
version: '3'
|
||||
|
||||
services:
|
||||
app:
|
||||
network_mode: host
|
||||
build:
|
||||
context: .
|
||||
dockerfile: Dockerfile
|
||||
|
||||
volumes:
|
||||
# Forwards the local Docker socket to the container.
|
||||
- /var/run/docker.sock:/var/run/docker-host.sock
|
||||
# Update this to wherever you want VS Code to mount the folder of your project
|
||||
- ../..:/workspaces:cached
|
||||
|
||||
# Overrides default command so things don't shut down after the process ends.
|
||||
entrypoint: /usr/local/share/docker-init.sh
|
||||
command: sleep infinity
|
||||
# Uncomment the next four lines if you will use a ptrace-based debuggers like C++, Go, and Rust.
|
||||
# cap_add:
|
||||
# - SYS_PTRACE
|
||||
# security_opt:
|
||||
# - seccomp:unconfined
|
||||
|
||||
# Use "forwardPorts" in **devcontainer.json** to forward an app port locally.
|
||||
# (Adding the "ports" property to this file will not forward from a Codespace.)
|
||||
@@ -1,11 +0,0 @@
|
||||
{
|
||||
"id": "tweaks",
|
||||
"name": "Additional tweaks to the devcontainer",
|
||||
"options": {
|
||||
"username": {
|
||||
"type": "string",
|
||||
"default": "",
|
||||
"description": "Enter name of non-root user to configure or blank to use remoteUser"
|
||||
}
|
||||
}
|
||||
}
|
||||
Regular → Executable
+2
-5
@@ -1,14 +1,11 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
|
||||
USERNAME="${USERNAME:-"${_REMOTE_USER}"}"
|
||||
|
||||
cat >> /home/${USERNAME}/.zshrc <<- EOM
|
||||
cat >> /home/vscode/.zshrc <<- EOM
|
||||
source <(kubectl completion zsh)
|
||||
alias k=kubectl
|
||||
complete -o default -F __start_kubectl k
|
||||
source <(minikube completion zsh)
|
||||
source <(k3d completion zsh)
|
||||
source <(helm completion zsh)
|
||||
source <(argocd completion zsh)
|
||||
EOM
|
||||
-3140
File diff suppressed because it is too large.
Load diff
Vendored
+3
-3
@@ -6,7 +6,7 @@
|
||||
{
|
||||
"label": "Dev Server - Start",
|
||||
"type": "shell",
|
||||
"command": "minikube start",
|
||||
"command": "k3d cluster create -c k3d-default.yaml && docker logs -f k3d-k3s-default-server-0",
|
||||
"icon": {
|
||||
"id": "play-circle"
|
||||
}
|
||||
@@ -14,7 +14,7 @@
|
||||
{
|
||||
"label": "Dev Server - Logs",
|
||||
"type": "shell",
|
||||
"command": "docker logs -f minikube",
|
||||
"command": "docker logs -f k3d-k3s-default-server-0",
|
||||
"icon": {
|
||||
"id": "tree-filter-on-type-off"
|
||||
}
|
||||
@@ -22,7 +22,7 @@
|
||||
{
|
||||
"label": "Stop Dev Server",
|
||||
"type": "shell",
|
||||
"command": "minikube stop",
|
||||
"command": "k3d cluster delete -c k3d-default.yaml",
|
||||
"icon": {
|
||||
"id": "stop-circle"
|
||||
}
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
---
|
||||
apiVersion: k3d.io/v1alpha4
|
||||
kind: Simple
|
||||
metadata:
|
||||
name: k3s-default
|
||||
servers: 1
|
||||
agents: 1
|
||||
image: docker.io/rancher/k3s:v1.25.6-k3s1
|
||||
kubeAPI:
|
||||
hostPort: "6443"
|
||||
ports:
|
||||
- port: 80:80
|
||||
nodeFilters:
|
||||
- loadbalancer
|
||||
- port: 443:443
|
||||
nodeFilters:
|
||||
- loadbalancer
|
||||
options:
|
||||
kubeconfig:
|
||||
updateDefaultKubeconfig: true
|
||||
switchCurrentContext: true
|
||||
@@ -1,22 +0,0 @@
|
||||
{{- if .Values.selfapp.enabled -}}
|
||||
---
|
||||
apiVersion: argoproj.io/v1alpha1
|
||||
kind: Application
|
||||
metadata:
|
||||
name: contour
|
||||
namespace: "{{ .Release.Namespace }}"
|
||||
spec:
|
||||
project: default
|
||||
source:
|
||||
chart: contour
|
||||
repoURL: https://charts.bitnami.com/bitnami
|
||||
targetRevision: "11.0.0"
|
||||
helm:
|
||||
releaseName: contour
|
||||
destination:
|
||||
server: "https://kubernetes.default.svc"
|
||||
namespace: contour
|
||||
syncPolicy:
|
||||
syncOptions:
|
||||
- CreateNamespace=true
|
||||
{{- end -}}
|
||||
Reference in new issue
Block a user