aws configure set preview.efs true
aws efs describe-file-systems --profile TEST --region us-east-2
{
The goal is to provide a dynamic (wildcard) route that should match on all nested routes that starts from some string.
The main issue is that Drupal routing system, does not provide a clean way to describe a wildcard routes that should match some kind of pattern, like /UserGuide
, /UserGuide/Development_Notes
or /UserGuide/Release_Notes/3.0.x
etc.
Initial idea is to use dynamic routes, that will work in case when routes are known or could be generated by some pattern, like /UserGuide/node/1
, /UserGuide/node/2
etc. Otherwise this is not possible, like when the route could consist from the multiple undefined parts.
As one possible solution, I decided to try the inbound path processor to catch destination path to redirect to the page controller, and pass an origin
var key = <my key>, | |
secret = <my secret>, | |
https = require("https"), | |
https_options = { | |
"host": <host>, | |
"path": <path>, | |
"port": <port>, | |
"method": <method>, | |
"headers": { | |
"Authorization": "Basic " + new Buffer(key + ":" + secret, "utf8").toString("base64") |
<?php | |
// | |
// ATTENTION! | |
// This method of resizing field data TRUNCATES the information present in the field. | |
// This is heavily based on the solution available at https://github.com/evolvingweb/custom_field_resize | |
// with only a minor tweak to truncate field data before resizing the field, so we don't get an SQL error. | |
// | |
apt-get update | |
apt-get install -y ruby | |
wget https://aws-codedeploy-us-east-1.s3.amazonaws.com/releases/codedeploy-agent_1.0-1.1597_all.deb | |
mkdir codedeploy-agent_1.0-1.1597_ubuntu20 | |
dpkg-deb -R codedeploy-agent_1.0-1.1597_all.deb codedeploy-agent_1.0-1.1597_ubuntu20 | |
sed 's/2.0/2.7/' -i ./codedeploy-agent_1.0-1.1597_ubuntu20/DEBIAN/control | |
dpkg-deb -b codedeploy-agent_1.0-1.1597_ubuntu20 | |
dpkg -i codedeploy-agent_1.0-1.1597_ubuntu20.deb | |
systemctl start codedeploy-agent | |
systemctl enable codedeploy-agent |
<?php | |
declare(strict_types=1); | |
namespace Drupal\mymodule\StackMiddleware; | |
use Symfony\Component\HttpFoundation\InputBag; | |
use Symfony\Component\HttpFoundation\Request; | |
use Symfony\Component\HttpFoundation\Response; | |
use Symfony\Component\HttpKernel\HttpKernelInterface; |
See discussion at https://www.drupal.org/project/drupal/issues/937442
This workaround is based on code from "Address" contrib module: https://www.drupal.org/project/address Thanks to @bojanz who initially wrote it here: https://git.drupalcode.org/project/address/-/blob/8.x-1.x/address.install
#!/bin/bash | |
rm -f content | |
rm *.enc | |
rm *.pem | |
rm keyfile | |
rm *.b64 | |
rm *.dec | |
echo "generate: data-key for this content transfer" |
openssl key pair generate | |
//client - using meteor.js | |
const nodersa = Npm.require('node-rsa'); | |
import { HTTP } from 'meteor/http'; | |
const syncPost = Meteor.wrapAsync( HTTP.post, HTTP ); | |
encryptStringWithRsaPublicKey( data ) { | |
const absolutePath = Assets.absoluteFilePath( "public.key" ); //public key file path | |
const publicKey = fs.readFileSync( absolutePath, "utf8" ); |