JOSE is a comprehensive set of JWT, JWS, and JWE libraries.
go get github.com/SermoDigital/jose
<?php defined('SYSPATH') or die('No direct script access.'); | |
class Color { | |
public static function hex_to_rgb($hex){ | |
$pattern = '/^#?(\w{1,2})(\w{1,2})(\w{1,2})$/'; | |
preg_match($pattern, $hex, $matches); | |
$matches = array_slice($matches, 1); | |
if (!function_exists('map')){ | |
function map($value){ |
<?php | |
namespace tests\codeception\common\_support; | |
use Codeception\Exception\ModuleException; | |
/** | |
* | |
*/ | |
class AcceptanceHelper extends \Codeception\Module |
<?php | |
namespace App\Auth; | |
use Laravel\Passport\Bridge\AccessToken as BaseToken; | |
use Lcobucci\JWT\Builder; | |
use Lcobucci\JWT\Signer\Key; | |
use Lcobucci\JWT\Signer\Rsa\Sha256; | |
use League\OAuth2\Server\CryptKey; | |
use League\OAuth2\Server\Entities\ClientEntityInterface; |
import { Pipe, PipeTransform } from '@angular/core'; | |
const ordinals: string[] = ['th','st','nd','rd']; | |
/* | |
* Append ordinal to number (e.g. "1st" position) | |
* Usage: | |
* value | ordinal:keepNumber | |
* Example: | |
* {{ 23 | ordinal}} |
package istio | |
import ( | |
"time" | |
"github.com/micro/go-micro" | |
"github.com/micro/go-micro/client" | |
"github.com/micro/go-micro/selector" | |
gcli "github.com/micro/go-plugins/client/grpc" |
#!/usr/bin/env node | |
# run this before using: yarn add --dev node-pty semver | |
const os = require("os") | |
const pty = require("node-pty") | |
const semver = require("semver") | |
function semverComparator(a, b) { | |
if (semver.lt(a, b)) { |
File | Purpose |
---|---|
/etc/compose/docker-compose.yml |
Compose file describing what to deploy |
/etc/systemd/system/docker-compose-reload.service |
Executing unit to trigger reload on docker-compose.service |
/etc/systemd/system/docker-compose-reload.timer |
Timer unit to plan the reloads |
/etc/systemd/system/docker-compose.service |
Service unit to start and manage docker compose |
[Install] | |
WantedBy=multi-user.target | |
[Unit] | |
Description=Google Cloud Compute Engine SQL Proxy | |
Requires=networking.service | |
After=networking.service | |
[Service] | |
Type=simple |