Skip to content

Instantly share code, notes, and snippets.

View paveljurca's full-sized avatar
🎯
Focusing

Pavel paveljurca

🎯
Focusing
View GitHub Profile
# Copyright 2021 Google LLC
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
# https://www.apache.org/licenses/LICENSE-2.0
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,

Manage Windows Servers using Ansible

This is a real-time demo of how to set up your windows servers so they can be managed by ansible. I've created a YouTube companion video demo here: https://youtu.be/aPN18jLRkJI

Subscribe To Me On YouTube: https://bit.ly/lon_sub

The following is covered by this demo:

  • Setup a windows 2016 (or 2019/2021) server so ansible can manage it (over HTTPS)
  • Setup my Centos 8 server so it can manage windows servers using winrm

As a flat file CMS, Kirby stores all content in folders and files. This is not only true for pages, but also for files and user accounts, which are by default stored in the /site/accounts folder.

But in the same way as you can incorporate content from other sources like spreadsheets, feeds or databases to create (link: text: virtual pages in Kirby), you can also replace users stored in the file system with users stored in a database (or some other source).

In this recipe, we will see how we can achieve this. For this purpose, we will start with a simple read-only solution and then extend this basic setup step-by-step into a solution that lets us create and edit database users from the Panel, including multi-language user content.

Note that using users from a database as described in this recipe will **not** solve potential performance issues with thousands of users.
@kellyjonbrazil
kellyjonbrazil / tr2dot.py
Created August 3, 2021 22:23
Generate graphviz dot graph from traceroute command output
#!/usr/bin/env python3
#
# Convert traceroute command output to a graphviz DOT graph
# Use `jc` to convert `traceroute` output to JSON before piping to tr2dot.py
#
# Version 1.0
# Kelly Brazil (kellyjonbrazil@gmail.com)
#
# Requires graphviz (pip3 install graphviz)
#
@marcus-at-localhost
marcus-at-localhost / postman-pre-request.js
Created July 16, 2021 14:10 — forked from bcnzer/postman-pre-request.js
Postman pre-request script to automatically get a bearer token from Auth0 and save it for reuse
const echoPostRequest = {
url: 'https://<my url>.auth0.com/oauth/token',
method: 'POST',
header: 'Content-Type:application/json',
body: {
mode: 'application/json',
raw: JSON.stringify(
{
client_id:'<your client ID>',
client_secret:'<your client secret>',
@malarkey
malarkey / alt-styles.css
Last active October 28, 2023 19:42
A simpler approach to CSS styling using just one default style plus one alternative.
/* CSS Custom Properties */
:root {
--font-family-default: 'Merriweather', serif;
--font-family-alt: 'Merriweather Sans', sans-serif;
--font-color-default: #b1a18;
--font-color-alt: #f5f5f3;
--font-link-default: #a62339;
@marcus-at-localhost
marcus-at-localhost / alpine-js-fetch-data-on-x-init.markdown
Last active November 25, 2022 08:20
[Alpine.js fetch data on `x-init`] #js #alpinejs
@malarkey
malarkey / custom-properties-boilerplate.css
Created March 14, 2019 20:02
CSS Custom Properties boilerplate
/* CSS Custom Properties */
:root {
--font-family: 'Georgia', serif;
--font-family-alt: 'Helvetica', Arial, sans-serif;
--font-weight: 400;
--font-weight-bold: 700;
--font-weight-black: 900;
/* 3:4 perfect fourth scale */
@qoomon
qoomon / conventional_commit_messages.md
Last active May 4, 2024 21:21
Conventional Commit Messages

Conventional Commit Messages

See how a minor change to your commit message style can make a difference.

Tip

Have a look at git-conventional-commits , a CLI util to ensure these conventions and generate verion and changelogs

Commit Message Formats

Default

@Rich-Harris
Rich-Harris / what-is-svelte.md
Last active March 27, 2024 06:09
The truth about Svelte

I've been deceiving you all. I had you believe that Svelte was a UI framework — unlike React and Vue etc, because it shifts work out of the client and into the compiler, but a framework nonetheless.

But that's not exactly accurate. In my defense, I didn't realise it myself until very recently. But with Svelte 3 around the corner, it's time to come clean about what Svelte really is.

Svelte is a language.

Specifically, Svelte is an attempt to answer a question that many people have asked, and a few have answered: what would it look like if we had a language for describing reactive user interfaces?

A few projects that have answered this question: