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

added a new chart static-site that build and host static sites. #64

Merged
merged 13 commits into from
Mar 30, 2023

Conversation

laszlocph
Copy link
Contributor

@laszlocph laszlocph commented Mar 27, 2023

helm repo add onechart https://chart.onechart.dev

cat << EOF > values.yaml
gitCloneUrl: https://github.com/gimlet-io/hugo-site.git
buildImage: bitnami/git # the image must have git installed
buildTag: latest
buildScript: |
    # !/usr/bin/env bash
    # pre -reqs
    apt-get update && apt-get install -y wget
    # Setting up Hugo 
    wget https://github.com/gohugoio/hugo/releases/download/v0.111.3/hugo_0.111.3_Linux-64bit.tar.gz &&
    tar -xzf hugo_0.111.3_Linux-64bit.tar.gz &&
    chmod +x hugo
    ./hugo
builtAssets: public/ 
EOF

helm template my-static-site onechart/static-site -f values.yaml

charts/static-site/Chart.yaml Outdated Show resolved Hide resolved
charts/static-site/templates/hpa.yaml Outdated Show resolved Hide resolved
charts/static-site/templates/tests/test-connection.yaml Outdated Show resolved Hide resolved
charts/static-site/values.yaml Outdated Show resolved Hide resolved
charts/static-site/values.yaml Outdated Show resolved Hide resolved
gitCloneUrl: https://github.com/YoucefGuichi/hugo-site.git
buildImage: node
gitCloneUrl: https://github.com/gimlet-io/hugo-site.git
buildImage: node # the image must have git installed
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👏

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, can you find something smaller with git. This image is 999MB 😨

docker images | grep node
node                                          latest                                     0e0ab07dbedd   4 days ago      999MB

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

using alpine/git now,

➜  ~ git:(main) ✗ docker images | grep alpine
alpine/git                    latest         9793ee61fc75   4 months ago   43.4MB

Copy link
Contributor Author

@laszlocph laszlocph Mar 28, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not bad. I actually fear that alpine is harming usability. Noone knows how to use alpine images.. at least even after 7 years of using them occasionally I still have to look up stuff and curse everytime. Can you find an alternative.. some debian or ubuntu. 200-300MB is a good upper limit.

charts/static-site/values.yaml Show resolved Hide resolved
charts/static-site/templates/deployment.yaml Outdated Show resolved Hide resolved
@laszlocph laszlocph merged commit 00becd0 into master Mar 30, 2023
@laszlocph laszlocph deleted the one-024 branch March 30, 2023 11:54
lalyos pushed a commit to lalyos/onechart that referenced this pull request Dec 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants