Skip to content

Commit

Permalink
fix(rules): add GCP DNS
Browse files Browse the repository at this point in the history
  • Loading branch information
bodinsamuel committed Aug 7, 2023
1 parent 849a31c commit bae5e74
Show file tree
Hide file tree
Showing 8 changed files with 22 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/common/techs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ export const list: TechItem[] = [
{ key: 'gcp', name: 'GCP', type: 'hosting' },
{ key: 'gcp.bigquery', name: 'Big Query', type: 'db' },
{ key: 'gcp.bigtable', name: 'Big Table', type: 'db' },
{ key: 'gcp.dns', name: 'DNS', type: 'network' },
{ key: 'gcp.datastore', name: 'Datastore', type: 'db' },
{ key: 'gcp.cloudrun', name: 'Cloud Run', type: 'hosting' },
{ key: 'gcp.pubsub', name: 'PubSub', type: 'messaging' },
Expand Down
1 change: 1 addition & 0 deletions src/rules/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import './db/index.js';
import './hosting/index.js';
import './js/index.js';
import './messaging/index.js';
import './network/index.js';
import './sass/index.js';
import './spec/index.js';
import './tool/index.js';
10 changes: 10 additions & 0 deletions src/rules/network/gcp.dns.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
import { register } from '../../rules.js';

register({
tech: 'gcp.dns',
dependencies: [
{ type: 'npm', name: '@google-cloud/dns' },
{ type: 'terraform.resource', name: 'google_dns_record_set' },
{ type: 'ruby', name: 'google-cloud-dns' },
],
});
1 change: 1 addition & 0 deletions src/rules/network/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
import './gcp.dns.js';
1 change: 1 addition & 0 deletions src/rules/spec/nodejs/__snapshots__/component.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ exports[`npm > should match everything 1`] = `
"gcp.bigtable",
"gcp.cloudrun",
"gcp.datastore",
"gcp.dns",
"gcp.gce",
"gcp.gcs",
"gcp.pubsub",
Expand Down
6 changes: 6 additions & 0 deletions src/rules/spec/ruby/__snapshots__/component.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ Set {
"oraclecloud",
"rabbitmq",
"gcp.pubsub",
"gcp.dns",
"algolia",
"auth0",
"datadog",
Expand Down Expand Up @@ -180,6 +181,11 @@ exports[`ruby (component) > should match everything 2`] = `
"google-cloud-datastore",
"1.0.0",
],
[
"ruby",
"google-cloud-dns",
"1.0.0",
],
[
"ruby",
"google-cloud-pubsub",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ exports[`terraform (resource) > should match everything 1`] = `
"gcp.bigtable",
"gcp.cloudrun",
"gcp.datastore",
"gcp.dns",
"gcp.gce",
"gcp.gcs",
"gcp.gke",
Expand Down
1 change: 1 addition & 0 deletions src/types/techs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ export type AllowedKeys =
| 'gcp.bigtable'
| 'gcp.cloudrun'
| 'gcp.datastore'
| 'gcp.dns'
| 'gcp.gce'
| 'gcp.gcs'
| 'gcp.gke'
Expand Down

0 comments on commit bae5e74

Please sign in to comment.