Skip to content

Instantly share code, notes, and snippets.

server {
server_name example.com;
root /var/www/drupal8; ## <-- Your only path reference.
location = /favicon.ico {
log_not_found off;
access_log off;
}
location = /robots.txt {
langcode: en
status: true
dependencies:
config:
- field.storage.node.field_categories
- node.type.apidoc
- taxonomy.vocabulary.api_category
id: node.apidoc.field_categories
field_name: field_categories
entity_type: node
@giteshk
giteshk / docker-compose.yaml
Last active December 6, 2023 02:08
Apigee Kickstart on GCE
# 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,
@giteshk
giteshk / apigeestaging.patch
Created March 8, 2023 17:04
ApigeeStaging
Index: src/ClientInterface.php
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
diff --git a/src/ClientInterface.php b/src/ClientInterface.php
--- a/src/ClientInterface.php (revision a6a24db85561a2cc2e4663f9000c084027af24a5)
+++ b/src/ClientInterface.php (revision abd2366dd65ee9fc664a853bd895aab4a47200cb)
@@ -62,7 +62,7 @@
*
apiVersion: apigeeregistry/v1
kind: API
metadata:
name: asyncapi-sample
labels:
apihub-lifecycle: concept
apihub-style: apihub-asyncapi
annotations:
apihub-primary-contact: asyncapi-team@example.com
apihub-primary-contact-description: Async API Team
@giteshk
giteshk / petstore-example.yaml
Last active August 25, 2022 01:58
API definition for Apigee API hub
apiVersion: apigeeregistry/v1
kind: API
metadata:
name: petstore-example
labels:
apihub-lifecycle: concept
apihub-style: apihub-openapi
apihub-target-users: public
data:
displayName: Petstore Example API
sudo su -
$endpoint=$(curl -s http://metadata.google.internal/computeMetadata/v1/instance/attributes/FORWARD_IPADDRESS -H "Metadata-Flavor: Google")
if [ -x /bin/firewall-cmd ]
then
sysctl -w net.ipv4.ip_forward=1
firewall-cmd --permanent --add-masquerade
firewall-cmd --permanent --add-forward-port=port=443:proto=tcp:toaddr=$endpoint
else
public TypeCardType CardTypeLookup(string strPAN)
{
string strCardType = "";
/*
* NOTE : "NotSet" TypeCardType is not a valid card type to transmit in the BankcardTransaction Object. If returned the
* validation checks did not find a match. The software should log a message that it was unable to
* match as the CardTypeLookup may need additional validation logic added to it. Never log the PAN as this would
* be a PCI violation.
*/