Skip to content

Commit 12c1934

Browse files
jkwluiJustinBeckwith
authored andcommitted
Add synth.py and update google-gax (#36)
1 parent 71cb968 commit 12c1934

13 files changed

Lines changed: 1927 additions & 1571 deletions

File tree

packages/google-cloud-oslogin/package-lock.json

Lines changed: 1741 additions & 1522 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/google-cloud-oslogin/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,13 +42,13 @@
4242
"cover": "nyc --reporter=lcov mocha --require intelli-espower-loader test/*.js && nyc report",
4343
"samples-test": "cd samples/ && npm link ../ && npm test && cd ../",
4444
"test-no-cover": "mocha test/*.js --no-timeouts",
45-
"lint": "eslint src/ samples/ system-test/ test/ smoke-test/",
45+
"lint": "eslint src/ samples/ system-test/ test/",
4646
"prettier": "prettier --write src/*.js src/*/*.js samples/*.js samples/*/*.js test/*.js test/*/*.js system-test/*.js system-test/*/*.js smoke-test/*.js",
4747
"docs": "jsdoc -c .jsdoc.js",
4848
"system-test": "mocha system-test/*.js smoke-test/*.js --timeout 600000"
4949
},
5050
"dependencies": {
51-
"google-gax": "^0.16.0",
51+
"google-gax": "^0.17.0",
5252
"lodash.merge": "^4.6.0"
5353
},
5454
"devDependencies": {
Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
// Copyright 2017 Google Inc.
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
syntax = "proto3";
16+
17+
package google.cloud.oslogin.common;
18+
19+
import "google/api/annotations.proto";
20+
21+
option csharp_namespace = "Google.Cloud.OsLogin.Common";
22+
option go_package = "google.golang.org/genproto/googleapis/cloud/oslogin/common;common";
23+
option java_outer_classname = "OsLoginProto";
24+
option java_package = "com.google.cloud.oslogin.common";
25+
option php_namespace = "Google\\Cloud\\OsLogin\\Common";
26+
27+
28+
// The POSIX account information associated with a Google account.
29+
message PosixAccount {
30+
// Only one POSIX account can be marked as primary.
31+
bool primary = 1;
32+
33+
// The username of the POSIX account.
34+
string username = 2;
35+
36+
// The user ID.
37+
int64 uid = 3;
38+
39+
// The default group ID.
40+
int64 gid = 4;
41+
42+
// The path to the home directory for this account.
43+
string home_directory = 5;
44+
45+
// The path to the logic shell for this account.
46+
string shell = 6;
47+
48+
// The GECOS (user information) entry for this account.
49+
string gecos = 7;
50+
51+
// System identifier for which account the username or uid applies to.
52+
// By default, the empty value is used.
53+
string system_id = 8;
54+
55+
// Output only. A POSIX account identifier.
56+
string account_id = 9;
57+
}
58+
59+
// The SSH public key information associated with a Google account.
60+
message SshPublicKey {
61+
// Public key text in SSH format, defined by
62+
// <a href="https://www.ietf.org/rfc/rfc4253.txt" target="_blank">RFC4253</a>
63+
// section 6.6.
64+
string key = 1;
65+
66+
// An expiration time in microseconds since epoch.
67+
int64 expiration_time_usec = 2;
68+
69+
// Output only. The SHA-256 fingerprint of the SSH public key.
70+
string fingerprint = 3;
71+
}

packages/google-cloud-oslogin/protos/google/cloud/oslogin/v1beta/oslogin.proto

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,17 +17,18 @@ syntax = "proto3";
1717
package google.cloud.oslogin.v1beta;
1818

1919
import "google/api/annotations.proto";
20-
import "google/cloud/oslogin/common.proto";
20+
import "google/cloud/oslogin/common/common.proto";
2121
import "google/protobuf/empty.proto";
2222
import "google/protobuf/field_mask.proto";
2323

24+
option csharp_namespace = "Google.Cloud.OsLogin.V1Beta";
2425
option go_package = "google.golang.org/genproto/googleapis/cloud/oslogin/v1beta;oslogin";
2526
option java_multiple_files = true;
2627
option java_outer_classname = "OsLoginProto";
2728
option java_package = "com.google.cloud.oslogin.v1beta";
28-
option csharp_namespace = "Google.Cloud.OsLogin.V1Beta";
2929
option php_namespace = "Google\\Cloud\\OsLogin\\V1beta";
3030

31+
3132
// Cloud OS Login API
3233
//
3334
// The Cloud OS Login API allows you to manage users and their associated SSH

packages/google-cloud-oslogin/src/v1beta/doc/google/cloud/oslogin/common/doc_common.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
// Copyright 2017, Google LLC All rights reserved.
1+
// Copyright 2018 Google LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.
55
// You may obtain a copy of the License at
66
//
7-
// http://www.apache.org/licenses/LICENSE-2.0
7+
// https://www.apache.org/licenses/LICENSE-2.0
88
//
99
// Unless required by applicable law or agreed to in writing, software
1010
// distributed under the License is distributed on an "AS IS" BASIS,
@@ -48,7 +48,7 @@
4848
*
4949
* @typedef PosixAccount
5050
* @memberof google.cloud.oslogin.common
51-
* @see [google.cloud.oslogin.common.PosixAccount definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/oslogin/common.proto}
51+
* @see [google.cloud.oslogin.common.PosixAccount definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/oslogin/common/common.proto}
5252
*/
5353
var PosixAccount = {
5454
// This is for documentation. Actual contents will be loaded by gRPC.
@@ -70,7 +70,7 @@ var PosixAccount = {
7070
*
7171
* @typedef SshPublicKey
7272
* @memberof google.cloud.oslogin.common
73-
* @see [google.cloud.oslogin.common.SshPublicKey definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/oslogin/common.proto}
73+
* @see [google.cloud.oslogin.common.SshPublicKey definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/oslogin/common/common.proto}
7474
*/
7575
var SshPublicKey = {
7676
// This is for documentation. Actual contents will be loaded by gRPC.

packages/google-cloud-oslogin/src/v1beta/doc/google/cloud/oslogin/v1beta/doc_oslogin.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
// Copyright 2017, Google LLC All rights reserved.
1+
// Copyright 2018 Google LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.
55
// You may obtain a copy of the License at
66
//
7-
// http://www.apache.org/licenses/LICENSE-2.0
7+
// https://www.apache.org/licenses/LICENSE-2.0
88
//
99
// Unless required by applicable law or agreed to in writing, software
1010
// distributed under the License is distributed on an "AS IS" BASIS,
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
// Copyright 2018 Google LLC
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// https://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
// Note: this file is purely for documentation. Any contents are not expected
16+
// to be loaded as the JS file.
17+
18+
/**
19+
* A generic empty message that you can re-use to avoid defining duplicated
20+
* empty messages in your APIs. A typical example is to use it as the request
21+
* or the response type of an API method. For instance:
22+
*
23+
* service Foo {
24+
* rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
25+
* }
26+
*
27+
* The JSON representation for `Empty` is empty JSON object `{}`.
28+
* @typedef Empty
29+
* @memberof google.protobuf
30+
* @see [google.protobuf.Empty definition in proto format]{@link https://github.com/google/protobuf/blob/master/src/google/protobuf/empty.proto}
31+
*/
32+
var Empty = {
33+
// This is for documentation. Actual contents will be loaded by gRPC.
34+
};

packages/google-cloud-oslogin/src/v1beta/doc/google/protobuf/doc_field_mask.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
// Copyright 2017, Google LLC All rights reserved.
1+
// Copyright 2018 Google LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.
55
// You may obtain a copy of the License at
66
//
7-
// http://www.apache.org/licenses/LICENSE-2.0
7+
// https://www.apache.org/licenses/LICENSE-2.0
88
//
99
// Unless required by applicable law or agreed to in writing, software
1010
// distributed under the License is distributed on an "AS IS" BASIS,

packages/google-cloud-oslogin/src/v1beta/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
// Copyright 2017, Google LLC All rights reserved.
1+
// Copyright 2018 Google LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.
55
// You may obtain a copy of the License at
66
//
7-
// http://www.apache.org/licenses/LICENSE-2.0
7+
// https://www.apache.org/licenses/LICENSE-2.0
88
//
99
// Unless required by applicable law or agreed to in writing, software
1010
// distributed under the License is distributed on an "AS IS" BASIS,

packages/google-cloud-oslogin/src/v1beta/os_login_service_client.js

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
// Copyright 2017, Google LLC All rights reserved.
1+
// Copyright 2018 Google LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.
55
// You may obtain a copy of the License at
66
//
7-
// http://www.apache.org/licenses/LICENSE-2.0
7+
// https://www.apache.org/licenses/LICENSE-2.0
88
//
99
// Unless required by applicable law or agreed to in writing, software
1010
// distributed under the License is distributed on an "AS IS" BASIS,
@@ -40,10 +40,10 @@ class OsLoginServiceClient {
4040
* @param {string} [options.credentials.client_email]
4141
* @param {string} [options.credentials.private_key]
4242
* @param {string} [options.email] - Account email address. Required when
43-
* usaing a .pem or .p12 keyFilename.
43+
* using a .pem or .p12 keyFilename.
4444
* @param {string} [options.keyFilename] - Full path to the a .json, .pem, or
4545
* .p12 key downloaded from the Google Developers Console. If you provide
46-
* a path to a JSON file, the projectId option above is not necessary.
46+
* a path to a JSON file, the projectId option below is not necessary.
4747
* NOTE: .pem and .p12 require you to specify options.email as well.
4848
* @param {number} [options.port] - The port on which to connect to
4949
* the remote host.
@@ -74,14 +74,14 @@ class OsLoginServiceClient {
7474
// Create a `gaxGrpc` object, with any grpc-specific options
7575
// sent to the client.
7676
opts.scopes = this.constructor.scopes;
77-
var gaxGrpc = gax.grpc(opts);
77+
var gaxGrpc = new gax.GrpcClient(opts);
7878

7979
// Save the auth object to the client, for use by other methods.
8080
this.auth = gaxGrpc.auth;
8181

8282
// Determine the client header string.
8383
var clientHeader = [
84-
`gl-node/${process.version.node}`,
84+
`gl-node/${process.version}`,
8585
`grpc/${gaxGrpc.grpcVersion}`,
8686
`gax/${gax.version}`,
8787
`gapic/${VERSION}`,
@@ -216,9 +216,9 @@ class OsLoginServiceClient {
216216
*
217217
* @example
218218
*
219-
* const oslogin = require('@google-cloud/oslogin');
219+
* const osLogin = require('@google-cloud/os-login');
220220
*
221-
* var client = new oslogin.v1beta.OsLoginServiceClient({
221+
* var client = new osLogin.v1beta.OsLoginServiceClient({
222222
* // optional auth parameters.
223223
* });
224224
*
@@ -256,9 +256,9 @@ class OsLoginServiceClient {
256256
*
257257
* @example
258258
*
259-
* const oslogin = require('@google-cloud/oslogin');
259+
* const osLogin = require('@google-cloud/os-login');
260260
*
261-
* var client = new oslogin.v1beta.OsLoginServiceClient({
261+
* var client = new osLogin.v1beta.OsLoginServiceClient({
262262
* // optional auth parameters.
263263
* });
264264
*
@@ -298,9 +298,9 @@ class OsLoginServiceClient {
298298
*
299299
* @example
300300
*
301-
* const oslogin = require('@google-cloud/oslogin');
301+
* const osLogin = require('@google-cloud/os-login');
302302
*
303-
* var client = new oslogin.v1beta.OsLoginServiceClient({
303+
* var client = new osLogin.v1beta.OsLoginServiceClient({
304304
* // optional auth parameters.
305305
* });
306306
*
@@ -346,9 +346,9 @@ class OsLoginServiceClient {
346346
*
347347
* @example
348348
*
349-
* const oslogin = require('@google-cloud/oslogin');
349+
* const osLogin = require('@google-cloud/os-login');
350350
*
351-
* var client = new oslogin.v1beta.OsLoginServiceClient({
351+
* var client = new osLogin.v1beta.OsLoginServiceClient({
352352
* // optional auth parameters.
353353
* });
354354
*
@@ -400,9 +400,9 @@ class OsLoginServiceClient {
400400
*
401401
* @example
402402
*
403-
* const oslogin = require('@google-cloud/oslogin');
403+
* const osLogin = require('@google-cloud/os-login');
404404
*
405-
* var client = new oslogin.v1beta.OsLoginServiceClient({
405+
* var client = new osLogin.v1beta.OsLoginServiceClient({
406406
* // optional auth parameters.
407407
* });
408408
*
@@ -462,9 +462,9 @@ class OsLoginServiceClient {
462462
*
463463
* @example
464464
*
465-
* const oslogin = require('@google-cloud/oslogin');
465+
* const osLogin = require('@google-cloud/os-login');
466466
*
467-
* var client = new oslogin.v1beta.OsLoginServiceClient({
467+
* var client = new osLogin.v1beta.OsLoginServiceClient({
468468
* // optional auth parameters.
469469
* });
470470
*

0 commit comments

Comments
 (0)