cwielenb/CNCF-Dataset huggingface dataset:
Project: Chef InSpec (Provisioning / Security & Compliance)
File: google_compute_instance_templates.md

+++ title = "googlecomputeinstance_templates resource" draft = false gh_repo = "inspec" platform = "gcp" [menu] [menu.inspec] title = "googlecomputeinstance_templates" identifier = "inspec/resources/gcp/googlecomputeinstancetemplates.md googlecomputeinstancetemplates resource" parent = "inspec/resources/gcp" +++ A `googlecomputeinstance_templates` is used to test a Google InstanceTemplate resource This resource has beta fields available. To retrieve these fields, include `beta: true` in the constructor for the resource ```ruby describe googlecomputeinstance_templates(project: 'chef-gcp-inspec') do its('names') { should include 'inspec-gcp-instance-template' } end ``` Properties that can be accessed from the `googlecomputeinstance_templates` resource: See the resource for more information. `creation_timestamps` : an array of `googlecomputeinstancetemplate` creationtimestamp `descriptions` : an array of `googlecomputeinstance_template` description `ids` : an array of `googlecomputeinstance_template` id `names` : an array of `googlecomputeinstance_template` name `properties` : an array of `googlecomputeinstance_template` properties This resource supports all of the above properties as filter criteria, which can be used with `where` as a block or a method. Ensure the is enabled for the current project.
Project: Open Policy Agent (OPA) (Provisioning / Security & Compliance)
File: TROUBLESHOOTING.md

The most common reason for this issue is improper use of struct tags (eg. `yaml` or `json`). Viper uses under the hood for unmarshaling values which uses `mapstructure` tags by default. Please refer to the library's documentation for using other struct tags. Viper installation seems to fail a lot lately with the following (or a similar) error: ``` cannot find package "github.com/hashicorp/hcl/tree/hcl1" in any of: /usr/local/Cellar/go/1.15.7_1/libexec/src/github.com/hashicorp/hcl/tree/hcl1 (from $GOROOT) /Users/user/go/src/github.com/hashicorp/hcl/tree/hcl1 (from $GOPATH) ``` As the error message suggests, Go tries to look up dependencies in `GOPATH` mode (as it's commonly called) from the `GOPATH`. Viper opted to use to manage its dependencies. While in many cases the two methods are interchangeable, once a dependency releases new (major) versions, `GOPATH` mode is no longer able to decide which version to use, so it'll either use one that's already present or pick a version (usually the `master` branch). The solution is easy: switch to using Go Modules. Please refer to the on how to do that. tl;dr* `export GO111MODULE=on` This is a YAML 1.1 feature according to . Potential solutions are: Quoting values resolved as boolean Upgrading to YAML v3 (for the time being this is possible by passing the `viper_yaml3` tag to your build)
Project: YugabyteDB (App Definition and Development / Database)
File: ddl_drop_aggregate.md

title: DROP AGGREGATE statement [YSQL] headerTitle: DROP AGGREGATE linkTitle: DROP AGGREGATE description: Use the DROP AGGREGATE statement to remove an aggregate. menu: v2.18: identifier: ddldropaggregate parent: statements type: docs Use the `DROP AGGREGATE` statement to remove an aggregate. {{%ebnf%}} drop_aggregate, aggregate_signature {{%/ebnf%}} See the semantics of each option in the . Basic example. ```plpgsql yugabyte=# CREATE AGGREGATE newcnt(*) ( sfunc = int8inc, stype = int8, initcond = '0', parallel = safe ); yugabyte=# DROP AGGREGATE newcnt(*); ``` `IF EXISTS` example. ```plpgsql yugabyte=# DROP AGGREGATE IF EXISTS newcnt(*); yugabyte=# CREATE AGGREGATE newcnt(*) ( sfunc = int8inc, stype = int8, initcond = '0', parallel = safe ); yugabyte=# DROP AGGREGATE IF EXISTS newcnt(*); ``` `CASCADE` and `RESTRICT` example. ```plpgsql yugabyte=# CREATE AGGREGATE newcnt(*) ( sfunc = int8inc, stype = int8, initcond = '0', parallel = safe ); yugabyte=# CREATE VIEW cascade_view AS SELECT newcnt(*) FROM pg_aggregate; yugabyte=# -- The following should error: yugabyte=# DROP AGGREGATE newcnt(*) RESTRICT; yugabyte=# -- The following should error: yugabyte=# DROP AGGREGATE newcnt(*); yugabyte=# DROP AGGREGATE newcnt(*) CASCADE; ```
Project: YugabyteDB (App Definition and Development / Database)
File: drop_user.diagram.md

<svg class="rrdiagram" version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns="http://www.w3.org/2000/svg" width="436" height="80" viewbox="0 0 436 80"><path class="connector" d="M0 52h15m53 0h10m53 0h30m32 0h10m64 0h20m-141 0q5 0 5 5v8q0 5 5 5h116q5 0 5-5v-8q0-5 5-5m5 0h30m-5 0q-5 0-5-5v-20q0-5 5-5h35m24 0h35q5 0 5 5v20q0 5-5 5m-5 0h35"/><polygon points="0,59 5,52 0,45" style="fill:black;stroke-width:0"/><rect class="literal" x="15" y="35" width="53" height="25" rx="7"/><text class="text" x="25" y="52">DROP</text><rect class="literal" x="78" y="35" width="53" height="25" rx="7"/><text class="text" x="88" y="52">USER</text><rect class="literal" x="161" y="35" width="32" height="25" rx="7"/><text class="text" x="171" y="52">IF</text><rect class="literal" x="203" y="35" width="64" height="25" rx="7"/><text class="text" x="213" y="52">EXISTS</text><rect class="literal" x="347" y="5" width="24" height="25" rx="7"/><text class="text" x="357" y="22">,</text><a xlink:href="../../../syntaxresources/grammardiagrams#role-name"><rect class="rule" x="317" y="35" width="84" height="25"/><text class="text" x="327" y="52">role_name</text></a><polygon points="432,59 436,59 436,45 432,45" style="fill:black;stroke-width:0"/></svg>
Project: Hazelcast IMDG (App Definition and Development / Database)
File: TypeMapping.md

Type mapping in MongoDB SQL Connector. ===== The type system in MongoDB and SQL is not exactly the same. That leads to potential confusions and the need of type coercion. Type mapping | BSON Type | SQL Type | Java type | ||-|--| | double | double | double | | string | varchar | String | | object | object | org.bson.Document | | array | object | List | | binData | - | - | | undefined | - | - | | ObjectId | object | org.bson.ObjectId | | bool | boolean | boolean | | date | date_time or timestamp | LocalDateTime | | timestamp | date_time or timestamp | LocalDateTime | | null | | | | regex | OBJECT | org.bson.BsonRegularExpression | | dbPointer | - | - | | javascript | varchar | String | | javascriptWithScope | object | org.bson.CodeWithScope | | symbol | - | - | | int (32 bit) | int | int | | long (64 bit) | bigint | long | | decimal (128 bit) | decimal | BigDecimal | | minKey | object | org.bson.MinKey | | maxKey | object | org.bson.MaxKey | `*` - Type `date` in BSON represents seconds from Unix epoch in UTC timezone. Therefore it's not mapped to pure `DATE` SQL type nor `LocalDate` in Java (nor any formats with timezones). The "Java Type" column represents an object returned by SQL query if the object put into the collection is of given BSON type. Bare in mind, that, while we are able to convert MongoDB type to requested SQL type in the projection, the argument binding will not always work the same due to technical limitations. For example: you can have object with type `timestamp` represented as `DATE_TIME`, that in SELECT will give you LocalDateTime. However, binding LocalDateTime as an argument won't work, as only native MongoDB types will work for arguments. Same for e.g. having BSON column of type "string" mapped to "integer" in SQL. Type coercion Below is the table with possible and supported type coercions. All the default mappings from previous chapter are always valid. | Type of provided argument | Resolved insertion type | |-|-| | LocalDateTime | BsonDateTime | | OffsetDateTime | BsonDateTime | | HazelcastJsonValue (json column) | Document |
Project: Beam (App Definition and Development / Streaming & Messaging)
File: PROTOBUF.md

<!-- Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you 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 http://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, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. --> If you make changes to .proto files, you will need to rebuild the generated Go code. You may also need to rebuild the generated code if the required versions of the or modules defined in change. First, follow this one-time setup: Download . The simplest approach is to download one of the prebuilt binaries (named `protoc`) and extract it somewhere in your machine's `$PATH`. To generate the code: Navigate to this directory (`pkg/beam/model`). Check and make note of which versions of and are required. Verify the versions in ../../../scripts/genproto.sh are correct `go generate` If the generated .pb.go code contains build errors, it indicates a version mismatch somewhere between the packages required in go.mod, the installed Go executables, and the prebuilt `protoc` binary (which should match the google.golang.org/protobuf version). Following the steps above with matching version numbers should fix the error.
Project: RabbitMQ (App Definition and Development / Streaming & Messaging)
File: 3.12.9.md

RabbitMQ `3.12.9` is a maintenance release in the `3.12.x` . Please refer to the upgrade section from the if upgrading from a version prior to 3.12.0. This release requires Erlang 25 and supports Erlang versions up to `26.1.x`. has more details on Erlang version requirements for RabbitMQ. As of 3.12.0, RabbitMQ requires Erlang 25. Nodes will fail to start on older Erlang releases. Users upgrading from 3.11.x (or older releases) on Erlang 25 to 3.12.x on Erlang 26 (both RabbitMQ and Erlang are upgraded at the same time) must consult the first. Release notes can be found on GitHub at . When a topic permission was deleted, an of type `permission.deleted` was emitted in some cases, instead of `topic.permission.deleted`. Investigated by @bedia. GitHub issue: Shovels on `3.12.8` nodes failed during a rolling cluster upgrade due to internal identifier format changes. Starting with this release, both old and new formats are supported for upgrade safety. GitHub issue: are now available in the dashboard. Contributed by @johanrhodin (CloudAMQP) GitHub issue: Avoids an unnecessary warning in the logs. GitHub issue: `rabbitmq-diagnostics listpoliciesthat_match [queue name]` is a new command that simplifies troubleshooting of policy conflicts. GitHub issue: Nodes that have OAuth 2 enabled now redirect the user to the original landing page (if any) after successful login with the IDP. Contributed by @dukex. GitHub issue: None in this release. To obtain source code of the entire distribution, please download the archive named `rabbitmq-server-3.12.9.tar.xz` instead of the source tarball produced by GitHub.
Project: Vitess (App Definition and Development / Database)
File: STEERING.md

This document outlines the mission, scope, and objectives of the Vitess Steering Committee. The Steering Committee exists as the overall governing body of the Vitess project, providing the project values, operations and structure. The Steering Committee has a set of rights and responsibilities including the following: Charter for Steering Committee. Define and evolve project governance structures and policies, including how contributors become maintainers. Define Steering Committee structure, terms and elections. Decide, for the purpose of elections, who can vote. Logo/landing page/marketing. Maintain relationships with CNCF in conjunction with the technical lead and community advocate Define, evolve, and defend the vision, values, mission, and scope of the project. Establish processes regarding, and provide a final escalation path for any contested project governance related decision. Establish processes regarding other project resources/assets, including artifact repositories, build and test infrastructure, web sites and their domains, blogs, social-media accounts, etc. Request funds and other support from the CNCF (e.g. marketing, press, etc.). Delegate appropriate authority to trusted individuals. Committee structure will initially be determined by a bootstrap steering committee (see below). Beyond that the steering committee can itself decide to change the committee structure if necessary. We will form a bootstrap Steering Committee to serve for one year. The responsibilities of the bootstrap committee will be as follows. Charter for Steering Committee. Define Steering Committee structure, terms and elections. Decide, for the purpose of elections, who can vote. Conduct elections to form the next Steering Committee. Rafael Chacon @rafael Michael Demmer @demmer Paul Hemberger @pH14 Derek Perkins @derekperkins Deepthi Sigireddi @deepthi Sugu Sougoumarane @sougou, Chair This document was inspired by https://github.com/open-telemetry/community/blob/master/governance-charter.md https://github.com/kubernetes/steering/blob/master/charter.md https://github.com/todogroup/governance/blob/master/CHARTER.adoc
Project: Vault (Provisioning / Key Management)
File: generate-declaration.md

To generate a declaration file run `yarn tsc <javascript file to declare> --declaration --allowJs --emitDeclarationOnly --outDir <type file location>` For example, the following command generates a declaration file called base.d.ts for the pki certificate base.js model: `yarn tsc ./app/models/pki/certificate/base.js --declaration --allowJs --emitDeclarationOnly --outDir types/vault/models/pki/certificate`
Project: ShardingSphere (App Definition and Development / Database)
File: readwirte-splitting-rule.en.md

+++ title = "Readwrite_splitting" weight = 2 +++ ```sql REGISTER STORAGE UNIT write_ds ( HOST="127.0.0.1", PORT=3306, DB="ds_0", USER="root", PASSWORD="root" ),read_ds ( HOST="127.0.0.1", PORT=3307, DB="ds_0", USER="root", PASSWORD="root" ); ``` Create readwrite_splitting rule ```sql CREATE READWRITESPLITTING RULE group0 ( WRITESTORAGEUNIT=write_ds, READSTORAGEUNITS(read_ds), TYPE(NAME="random") ); ``` Alter readwrite_splitting rule ```sql ALTER READWRITESPLITTING RULE group0 ( WRITESTORAGEUNIT=write_ds, READSTORAGEUNITS(read_ds), TYPE(NAME="random",PROPERTIES("read_weight"="2:0")) ); ``` Drop readwrite_splitting rule ```sql DROP READWRITESPLITTING RULE group0; ``` Unregister storage unit ```sql UNREGISTER STORAGE UNIT writeds,readds; ``` Drop distributed database ```sql DROP DATABASE readwritesplittingdb; ```
Project: Beam (App Definition and Development / Streaming & Messaging)
File: kvswap.md

title: "KvSwap" <!-- 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 http://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, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. --> {{< localstorage language language-py >}} {{< button-pydoc path="apache_beam.transforms.util" class="KvSwap" >}} Takes a collection of key-value pairs and returns a collection of key-value pairs which has each key and value swapped. In the following example, we create a pipeline with a `PCollection` of key-value pairs. Then, we apply `KvSwap` to swap the keys and values. {{< playground height="700px" >}} {{< playgroundsnippet language="py" path="SDKPYTHON_KvSwap" show="kvswap" >}} {{< /playground >}} for extracting the key of each component. for extracting the value of each element. {{< button-pydoc path="apache_beam.transforms.util" class="KvSwap" >}}
Project: Tinkerbell (Provisioning / Automation & Configuration)
File: RELEASING.md

For version v0.x.y: Create the annotated tag > NOTE: To use your GPG signature when pushing the tag, use `SIGN_TAG=1 ./contrib/tag-release.sh v0.x.y` instead) `./contrib/tag-release.sh v0.x.y` Push the tag to the GitHub repository. This will automatically trigger a to create a release. > NOTE: `origin` should be the name of the remote pointing to `github.com/tinkerbell/tink` `git push origin v0.x.y` Review the release on GitHub. Releasing requires a particular set of permissions. Tag push access to the GitHub repository
Project: KICS (Provisioning / Security & Compliance)
File: 6e19193a-8753-436d-8a09-76dcff91bb03.md

title: Yum Install Allows Manual Input hide: toc: true navigation: true <style> .highlight .hll { background-color: #ff171742; } .md-content { max-width: 1100px; margin: 0 auto; } </style> Query id: 6e19193a-8753-436d-8a09-76dcff91bb03 Query name: Yum Install Allows Manual Input Platform: Dockerfile Severity: <span style="color:#edd57e">Low</span> Category: Supply-Chain URL: Need to use -y to avoid manual input 'yum install -y <package>'<br> ```dockerfile title="Positive test num. 1 - dockerfile file" hl_lines="3 4" FROM alpine:3.5 RUN apk add --update py2-pip RUN sudo yum install bundler RUN ["sudo yum", "install", "bundler"] COPY requirements.txt /usr/src/app/ RUN pip install --no-cache-dir -r /usr/src/app/requirements.txt COPY app.py /usr/src/app/ COPY templates/index.html /usr/src/app/templates/ EXPOSE 5000 CMD ["python", "/usr/src/app/app.py"] ``` ```dockerfile title="Negative test num. 1 - dockerfile file" FROM alpine:3.5 RUN apk add --update py2-pip RUN sudo yum install -y bundler COPY requirements.txt /usr/src/app/ RUN pip install --no-cache-dir -r /usr/src/app/requirements.txt COPY app.py /usr/src/app/ COPY templates/index.html /usr/src/app/templates/ EXPOSE 5000 CMD ["python", "/usr/src/app/app.py"] ```
Project: FOSSA (Provisioning / Security & Compliance)
File: treecmd.md

This maven tactic uses native, `mvn dependency:tree` command to retrieve dependency information. Find `pom.xml` files, and treat those as maven projects. Skip all subdirectories. Executes `mvn dependency:tree -DoutputType=dot -DoutputFile=... --fail-at-end` Parse and analyze generated dot file for dependency analysis
Project: NomsDB (App Definition and Development / Database)
File: architectures.md

Decentralized &nbsp; | &nbsp;&nbsp; | Architectures&nbsp; | &nbsp;&nbsp; | &nbsp; <br><br> There are many possible ways to use Noms as part of a decentralized application. Noms can naturally be mixed and matched with other decentralized tools like blockchains, IPFS, etc. This page lists a few approaches we find promising. Noms can be used to implement apps in a peer-to-peer configuration. Each instance of the application (i.e., each "node") maintains a database locally with the data that is relevant to it. When a node creates new data, it commits that data to it's database and broadcasts a message to it's peers that contains the hash of it's lastest commit. Peers that are listening for these message can decide if that data is relevant to them. Those that are interested can pull the new data from the publisher. The two clients efficiently communicate so that only data that isn't present in the requesting client is transmitted (much the same way that one git client sends source changes to another). Peers can use a flow similar to the following in order to sync changes with one another: ```nohighlight for { listen for new message if new msg is relevant { if new msg is ancestor of current commit { // nothing to do continue } pull new data from sender of msg if current head is ancestor of new msg { // fast forward to the new commit set head of dataset to new commit continue } merge new with current head and commit publish new commit } } ``` Noms has a default that covers many classes of concurrent operations. If the application restricts itself to only operations that are mergeable by this policy, then Noms can automatically merge all concurrent changes. In this case, the entire database is effectively a CRDT. If this is not sufficient, then applications can create their own merge policies, implementing whatever merge is appropriate for their use case. Another potential architecture for decentralized apps uses a decentralized chunkstore (such as IPFS, Swarm, or Sia) rather than local databases. In this case, rather than each node maintaining a local datastore, Noms chunks are stored in a decentralized chunkstore. The underlying chunkstore is responsible for making chunks available when needed. The flow used by peers to sync with one another is similar to the peer-to-peer architecture. The main difference is data is not duplicated on local machines and doesn't have to be pulled during sync. Each app keeps track of it's latest commit in the chunk store. ```nohighlight for { listen for new message if new msg is relevant { if new msg is ancestor of current commit { // nothing to do continue } // No pull necessary if current head is ancestor of new msg { // fast forward to the new commit set head of dataset to new commit continue } merge new with current head and commit publish new commit } } ``` We have a prototype implementation of an IPFS-based chunkstore. If you are interested in pursuing this direction, let us know!
Project: Podman (App Definition and Development / Application Definition & Image Build)
File: podman-pod-pause.1.md

% podman-pod-pause 1 podman\-pod\-pause - Pause one or more pods podman pod pause [options] pod ... Pauses all the running processes in the containers of one or more pods. You may use pod IDs or names as input. Pause all pods. Instead of providing the pod name or ID, pause the last created pod. (This option is not available with the remote Podman client, including Mac and Windows (excluding WSL2) machines) Pause a pod with a given name: ``` podman pod pause mywebserverpod ``` Pause a pod with a given ID: ``` podman pod pause 860a4b23 ``` , , , July 2018, Originally compiled by Peter Hunt <pehunt@redhat.com>
Project: KICS (Provisioning / Security & Compliance)
File: b3de4e4c-14be-4159-b99d-9ad194365e4c.md

title: EC2 Instance Subnet Has Public IP Mapping On Launch hide: toc: true navigation: true <style> .highlight .hll { background-color: #ff171742; } .md-content { max-width: 1100px; margin: 0 auto; } </style> Query id: b3de4e4c-14be-4159-b99d-9ad194365e4c Query name: EC2 Instance Subnet Has Public IP Mapping On Launch Platform: CloudFormation Severity: <span style="color:#ff7213">Medium</span> Category: Networking and Firewall URL: EC2 Instance Subnet should not have MapPublicIpOnLaunch set to true<br> ```yaml title="Positive test num. 1 - yaml file" hl_lines="7" AWSTemplateFormatVersion: "2010-09-09" Description: A sample template Resources: mySubnet: Type: AWS::EC2::Subnet Properties: MapPublicIpOnLaunch: true VpcId: myVPC CidrBlock: 10.0.0.0/24 AvailabilityZone: "us-east-1a" Tags: Key: foo Value: bar ``` ```json title="Positive test num. 2 - json file" hl_lines="8" { "AWSTemplateFormatVersion": "2010-09-09", "Description": "A sample template", "Resources": { "mySubnet": { "Type": "AWS::EC2::Subnet", "Properties": { "MapPublicIpOnLaunch": true, "VpcId": "myVPC", "CidrBlock": "10.0.0.0/24", "AvailabilityZone": "us-east-1a", "Tags": [ { "Key": "foo", "Value": "bar" } ] } } } } ``` ```yaml title="Negative test num. 1 - yaml file" AWSTemplateFormatVersion: "2010-09-09" Description: A sample template Resources: mySubnet: Type: AWS::EC2::Subnet Properties: MapPublicIpOnLaunch: false VpcId: myVPC CidrBlock: 10.0.0.0/24 AvailabilityZone: "us-east-1a" Tags: Key: foo Value: bar ``` ```json title="Negative test num. 2 - json file" { "Resources": { "mySubnet": { "Type": "AWS::EC2::Subnet", "Properties": { "Tags": [ { "Key": "foo", "Value": "bar" } ], "MapPublicIpOnLaunch": false, "VpcId": "myVPC", "CidrBlock": "10.0.0.0/24", "AvailabilityZone": "us-east-1a" } } }, "AWSTemplateFormatVersion": "2010-09-09", "Description": "A sample template" } ```