Skip to content

Instantly share code, notes, and snippets.

@alexeagle
Created January 25, 2022 15:09
Show Gist options
  • Save alexeagle/2001e9e58e261c07461fb05e47a95454 to your computer and use it in GitHub Desktop.
Save alexeagle/2001e9e58e261c07461fb05e47a95454 to your computer and use it in GitHub Desktop.
diff --git a/WORKSPACE b/WORKSPACE
index 78a36aa..96cacc6 100644
--- a/WORKSPACE
+++ b/WORKSPACE
@@ -35,9 +35,9 @@ yarn_install(
# https://github.com/bazelbuild/rules_docker/releases
http_archive(
name = "io_bazel_rules_docker",
- sha256 = "59536e6ae64359b716ba9c46c39183403b01eabfbd57578e84398b4829ca499a",
- strip_prefix = "rules_docker-0.22.0",
- urls = ["https://github.com/bazelbuild/rules_docker/releases/download/v0.22.0/rules_docker-v0.22.0.tar.gz"],
+ sha256 = "a81d4ffb9464efd0e5b7c1eea53ecac569df2e31d6da91f9e8eec823302c8c76",
+ strip_prefix = "rules_docker-c27194b35f56a1bea6e37f58e549230823653dc3",
+ urls = ["https://github.com/bazelbuild/rules_docker/archive/c27194b35f56a1bea6e37f58e549230823653dc3.zip"],
)
load(
diff --git a/app/BUILD.bazel b/app/BUILD.bazel
index fb2abc8..e6afc13 100644
--- a/app/BUILD.bazel
+++ b/app/BUILD.bazel
@@ -14,6 +14,7 @@ ts_config(
ts_project(
name = "lib",
srcs = glob(["**/*.ts"]),
+ deps = ["@npm//@types/node"],
declaration = True,
tsconfig = "tsconfig",
)
@@ -27,7 +28,8 @@ nodejs_binary(
nodejs_image(
name = "base_image",
binary = "server",
- node_repository_name = "nodejs",
+ include_node_repo_args = False,
+ node_repository_name = "nodejs_linux_amd64",
)
container_image(
diff --git a/package.json b/package.json
index 6d36cac..51c05bc 100644
--- a/package.json
+++ b/package.json
@@ -3,6 +3,7 @@
"devDependencies": {
"@bazel/bazelisk": "^1.11.0",
"@bazel/typescript": "^5.0.1",
+ "@types/node": "^17.0.12",
"typescript": "^4.5.5"
}
}
diff --git a/yarn.lock b/yarn.lock
index 93ec029..65f2bd4 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -88,6 +88,11 @@
resolved "https://registry.yarnpkg.com/@types/node/-/node-10.17.60.tgz#35f3d6213daed95da7f0f73e75bcc6980e90597b"
integrity sha512-F0KIgDJfy2nA3zMLmWGKxcH2ZVEtCZXHHdOQs2gSaQ27+lNeEfGxzkIw90aXswATX7AZ33tahPbzy6KAfUreVw==
+"@types/node@^17.0.12":
+ version "17.0.12"
+ resolved "https://registry.yarnpkg.com/@types/node/-/node-17.0.12.tgz#f7aa331b27f08244888c47b7df126184bc2339c5"
+ integrity sha512-4YpbAsnJXWYK/fpTVFlMIcUIho2AYCi4wg5aNPrG1ng7fn/1/RZfCIpRCiBX+12RVa34RluilnvCqD+g3KiSiA==
+
buffer-from@^1.0.0:
version "1.1.2"
resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.2.tgz#2b146a6fd72e80b4f55d255f35ed59a3a9a41bd5"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment