Code Monkey home page Code Monkey logo

kubedon's Introduction

Kubedon

A Mastodon conf for Kubernetes / Google Container Engine.

Prerequisite: Generating Secrets

CloudSQL

Enable the Cloud SQL Administration API.

Create a Cloud SQL PostgreSQL instance.

Create the secrets for the proxy as described in Connecting from Google Container Engine. Note that we also add instance_connection_name to cloudsql-secrets. Furthermore take note of the PostgreSQL proxy user credentials, as they will be referred to as PROXY_USER and PROXY_PASSWORD later.

$ kubectl create secret generic cloudsql-secrets \
  --from-file=credentials.json=[PROXY_KEY_FILE_PATH] \
  --from-literal=instance_connection_name=[INSTANCE_CONNECTION_NAME]

Mastodon Conf Secrets

$ kubectl create secret generic mastodon-secrets \
  --from-literal=PAPERCLIP_SECRET=[FIRST_RANDOM_STRING] \
  --from-literal=SECRET_KEY_BASE=[SECOND_RANDOM_STRING] \
  --from-literal=OTP_SECRET=[THIRD_RANDOM_STRING] \
  --from-literal=LOCAL_DOMAIN=[YOUR_DOMAIN] \
  --from-literal=DB_USER=[PROXY_USER] \
  --from-literal=DB_PASS=[PROXY_PASSWORD]

Let's Encrypt Certs

Generate Let's Encrypt Certs.

$ kubectl create secret generic web-certificates \
  --from-file=fullchain.pem \
  --from-file=privkey.pem

Run Migration

TBD

Somehow run RAILS_ENV=production bundle exec rails db:migrate on a container that has been seeded with the same env variables as the web container.

Apply Conf

$ kubectl apply -f .

kubedon's People

Contributors

jviide avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.