Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
auguwu committed Feb 2, 2024
0 parents commit 7742cc0
Show file tree
Hide file tree
Showing 32 changed files with 1,592 additions and 0 deletions.
44 changes: 44 additions & 0 deletions .charted.hcl
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# 🐻‍❄️🪻 helm-charts: Helm Charts available for Noelware's charted project
# Copyright (c) 2023-2024 Noelware, LLC. <[email protected]>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in all
# copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.

charted {
# view https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#tilde-requirements
# to see what `~` is meant since `charted-helm-plugin` uses Cargo's SemVer implementation.
version = "~ 0.1-beta"
helm = "~ 3.12"
}

registry "default" {
version = 1
url = "https://charts.noelware.org/api"
}

repository "charted-server" {
registry = registry.default
source = "${cwd}/charts/charted"
path = "charted/server"
}

repository "charted-emails" {
registry = registry.default
source = "${cwd}/charts/emails"
path = "charted/emails"
}
20 changes: 20 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"name": "charted-server",
"remoteUser": "noel",
"image": "ghcr.io/auguwu/coder-images/base",
"containerUser": "noel",
"customizations": {
"vscode": {
"extensions": ["redhat.vscode-yaml", "hashicorp.hcl"],
"settings": {
"dotfiles.installCommand": "bootstrap.sh",
"dotfiles.repository": "https://github.com/auguwu/.dotfiles"
}
}
},
"features": {
"ghcr.io/devcontainers/features/sshd:1": {
"version": "latest"
}
}
}
35 changes: 35 additions & 0 deletions .envrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# 🐻‍❄️🪻 helm-charts: Helm Charts available for Noelware's charted project
# Copyright (c) 2023-2024 Noelware, LLC. <[email protected]>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in all
# copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.

if ! has nix_direnv_version || ! nix_direnv_version 2.3.0; then
source_url "https://raw.githubusercontent.com/nix-community/nix-direnv/2.3.0/direnvrc" "sha256-Dmd+j63L84wuzgyjITIfSxSD57Tx7v51DMxVZOsiUD8="
fi

# make .direnv if it doesn't exist
mkdir -p "$(direnv_layout_dir)"

watch_file shell.nix
watch_file flake.nix
watch_file flake.lock

# try to use flakes, if it fails use normal nix (ie. shell.nix)
use flake || use nix
eval "$shellHook"
1 change: 1 addition & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* @auguwu @IceeMC @spotlightishere
76 changes: 76 additions & 0 deletions .github/CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
# Contributor Covenant Code of Conduct

## Our Pledge

In the interest of fostering an open and welcoming environment, we as
contributors and maintainers pledge to making participation in our project and
our community a harassment-free experience for everyone, regardless of age, body
size, disability, ethnicity, sex characteristics, gender identity and expression,
level of experience, education, socio-economic status, nationality, personal
appearance, race, religion, or sexual identity and orientation.

## Our Standards

Examples of behavior that contributes to creating a positive environment
include:

- Using welcoming and inclusive language
- Being respectful of differing viewpoints and experiences
- Gracefully accepting constructive criticism
- Focusing on what is best for the community
- Showing empathy towards other community members

Examples of unacceptable behavior by participants include:

- The use of sexualized language or imagery and unwelcome sexual attention or
advances
- Trolling, insulting/derogatory comments, and personal or political attacks
- Public or private harassment
- Publishing others' private information, such as a physical or electronic
address, without explicit permission
- Other conduct which could reasonably be considered inappropriate in a
professional setting

## Our Responsibilities

Project maintainers are responsible for clarifying the standards of acceptable
behavior and are expected to take appropriate and fair corrective action in
response to any instances of unacceptable behavior.

Project maintainers have the right and responsibility to remove, edit, or
reject comments, commits, code, wiki edits, issues, and other contributions
that are not aligned to this Code of Conduct, or to ban temporarily or
permanently any contributor for other behaviors that they deem inappropriate,
threatening, offensive, or harmful.

## Scope

This Code of Conduct applies both within project spaces and in public spaces
when an individual is representing the project or its community. Examples of
representing a project or community include using an official project e-mail
address, posting via an official social media account, or acting as an appointed
representative at an online or offline event. Representation of a project may be
further defined and clarified by project maintainers.

## Enforcement

Instances of abusive, harassing, or otherwise unacceptable behavior may be
reported by contacting the project team at **[email protected]**. All
complaints will be reviewed and investigated and will result in a response that
is deemed necessary and appropriate to the circumstances. The project team is
obligated to maintain confidentiality with regard to the reporter of an incident.
Further details of specific enforcement policies may be posted separately.

Project maintainers who do not follow or enforce the Code of Conduct in good
faith may face temporary or permanent repercussions as determined by other
members of the project's leadership.

## Attribution

This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html

[homepage]: https://www.contributor-covenant.org

For answers to common questions about this code of conduct, see
https://www.contributor-covenant.org/faq
1 change: 1 addition & 0 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
coming soon near a gay dog
98 changes: 98 additions & 0 deletions .github/workflows/CI.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
# 🐻‍❄️🪻 helm-charts: Helm Charts available for Noelware's charted project
# Copyright (c) 2023-2024 Noelware, LLC. <[email protected]>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in all
# copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.

name: CI
on:
workflow_dispatch: {}
push:
branches:
- 'issues/gh-**'
- 'feat/**'
- main
paths-ignore:
- '.github/**'
- '.coder/**'
- '.devcontainer/**'
- '.vscode/**'
- 'docs/**'
- 'scripts/**'
- '.*ignore'
- '**.md'
- renovate.json
- LICENSE
pull_request:
types: [opened, synchronize]
branches:
- main
paths-ignore:
- '.coder/**'
- '.devcontainer/**'
- '.vscode/**'
- 'docs/**'
- '.*ignore'
- '**.md'
- renovate.json
- LICENSE
jobs:
ci:
name: helm test [${{matrix.chart}}; Kubernetes ${{matrix.kubernetes}}]
runs-on: ubuntu-latest
strategy:
fail-fast: true
matrix:
chart: [charted, emails]
kubernetes: [v1.26.13, v1.28.6, v1.29.1]
steps:
- name: Checkout source code
uses: actions/checkout@v4

- name: Setup Helm
uses: Azure/setup-helm@v3

- name: Setup Minikube cluster
uses: medyagh/[email protected]
with:
kubernetes-version: ${{matrix.kubernetes}}
container-runtime: containerd
minikube-version: 1.32.0
start-args: '--delete-on-failure --profile=helm-test'
memory: 4000m
addons: ingress
cache: true
cpus: 4
wait: true
cni: bridge

- name: Lint
working-directory: ./charts/${{matrix.chart}}
run: helm lint

# - name: Install chart
# working-directory: ./charts/${{matrix.chart}}
# run: helm install ${{matrix.chart}} --namespace ci --create-namespace --wait --atomic

# - name: Test
# working-directory: ./charts/${{matrix.chart}}
# run: helm test

- name: Delete cluster (since we're done)
if: ${{ always() }}
run: minikube delete --profile=helm-test
52 changes: 52 additions & 0 deletions .github/workflows/UpdateValues.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# 🐻‍❄️🪻 helm-charts: Helm Charts available for Noelware's charted project
# Copyright (c) 2023-2024 Noelware, LLC. <[email protected]>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in all
# copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.

name: Update Values
on:
workflow_dispatch: {}
push:
paths:
- './charts/**/values.yaml'
jobs:
update-values:
name: Update README.md for `values.yaml` parameters
runs-on: ubuntu-latest
steps:
- name: Checkout source code
uses: actions/checkout@v4

- name: Setup Bun
uses: oven-sh/setup-bun@v1

- name: Write values.yaml into README
run: ./scripts/emit-values

- name: Prettier!
run: bunx prettier --config=${GITHUB_WORKSPACE}/.prettierrc.json --write charts/**/README.md

- name: Commit!
uses: EndBug/add-and-commit@v9
with:
author_name: Noel[bot]
default_author: user_info
author_email: [email protected]
message: '[skip ci] :sparkles: Update Protobufs in repository'
push: true
Loading

0 comments on commit 7742cc0

Please sign in to comment.