Skip to content

Commit

Permalink
*: cleanup bazel rules
Browse files Browse the repository at this point in the history
This commit cleans up several Bazel rules to remove mentions of code
that was previously in the Track-1 flow of the Tectonic Installer.
  • Loading branch information
squat committed Mar 26, 2018
1 parent 7214caa commit d61abd4
Show file tree
Hide file tree
Showing 77 changed files with 117 additions and 2,597 deletions.
30 changes: 2 additions & 28 deletions BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,6 @@ package(
default_visibility = ["//visibility:public"],
)

template_files = glob([
"modules/**/*",
"platforms/**/*",
"steps/**/*",
])

config_setting(
name = "darwin",
values = {"cpu": "darwin"},
Expand Down Expand Up @@ -47,21 +41,6 @@ genrule(

exports_files(["config.tf"])

genrule(
name = "templates",
message = "Copying templates...",
output_to_bindir = 1,
srcs = template_files,
outs = ["templates/%s" % f for f in template_files],
cmd = '\n'.join([
"for tf_file in $(SRCS); do",
"target=\"$(@D)/templates/$$(dirname $${tf_file})\"",
"mkdir -p $${target}",
"cp $${tf_file} $${target}",
"done"
]),
)

load("@io_bazel_rules_go//go:def.bzl", "go_prefix")

go_prefix("github.com/coreos/tectonic-installer")
Expand Down Expand Up @@ -120,7 +99,7 @@ genrule(
pkg_tar(
name = "tarball_terraform_configuration",
mode = "0644",
srcs = glob(["modules/**"]) + glob(["platforms/**"]) + glob(["steps/**"]) + ["config.tf"],
srcs = glob(["modules/**"], exclude=["modules/update-payload/**"]) + glob(["steps/**"]) + ["config.tf"],
strip_prefix = ".",
)

Expand Down Expand Up @@ -166,24 +145,19 @@ pkg_tar(
srcs = ["@terraform_provider_matchbox_linux//:terraform-provider-matchbox"],
)

load("//:variables.bzl", "PLATFORMS")

pkg_tar(
name = "tarball_examples",
package_dir = "examples",
# As long as we are not auto-generating the tectonic cli configuration
# examples, make sure to add the manually created once to the tarball.
srcs = ["//examples:terraform.tfvars." + p for p in PLATFORMS] + ["//examples:tectonic_cli_configs"],
srcs = ["//examples:tectonic_cli_configs"],
)

filegroup(
name = "terraform_files",
srcs = glob(
["modules/**/*.tf"],
exclude_directories=1,
) + glob(
["platforms/**/*.tf"],
exclude_directories=1,
) + glob(
["steps/**/*.tf"],
exclude_directories=1,
Expand Down
14 changes: 0 additions & 14 deletions Documentation/BUILD.bazel

This file was deleted.

4 changes: 2 additions & 2 deletions Documentation/dev/build.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ tectonic
├── config.tf
├── examples
├── modules
├── platforms
├── steps
└── tectonic-installer
├── darwin
│   ├── tectonic
Expand All @@ -90,7 +90,7 @@ tectonic_1.2.3-beta
├── config.tf
├── examples
├── modules
├── platforms
├── steps
└── tectonic-installer
```

Expand Down
8 changes: 0 additions & 8 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -174,14 +174,6 @@ pipeline {
archiveArtifacts allowEmptyArchive: true, artifacts: 'tectonic.tar.gz'
}

withDockerContainer(params.builder_image) {
sh """#!/bin/bash -ex
mkdir -p \$(dirname $GO_PROJECT) && ln -sf $WORKSPACE $GO_PROJECT
cd $GO_PROJECT/
make structure-check
"""
}
withDockerContainer(tectonicSmokeTestEnvImage) {
sh"""#!/bin/bash -ex
cd tests/rspec
Expand Down
214 changes: 0 additions & 214 deletions Makefile

This file was deleted.

19 changes: 0 additions & 19 deletions WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -54,22 +54,3 @@ visibility = ["//visibility:public"]
strip_prefix = "terraform-provider-matchbox-v%s-%s-amd64/" % (provider_matchbox_version, platform),
url = "https://github.com/coreos/terraform-provider-matchbox/releases/download/v%s/terraform-provider-matchbox-v%s-%s-amd64.tar.gz" % (provider_matchbox_version, provider_matchbox_version, platform),
) for platform in supported_platforms]

# Import Go dependencies.
go_repository(
name = "com_github_hashicorp_hcl",
importpath = "github.com/hashicorp/hcl",
commit = "23c074d0eceb2b8a5bfdbb271ab780cde70f05a8",
)

go_repository(
name = "com_github_segmentio_terraform-docs",
importpath = "github.com/segmentio/terraform-docs",
tag = "v0.3.0",
)

go_repository(
name = "com_github_tj_docopt",
importpath = "github.com/tj/docopt",
tag = "v1.0.0",
)
21 changes: 0 additions & 21 deletions contrib/terraform-examples/BUILD.bazel

This file was deleted.

3 changes: 0 additions & 3 deletions contrib/terraform-examples/Gopkg.toml

This file was deleted.

8 changes: 0 additions & 8 deletions contrib/terraform-examples/README.md

This file was deleted.

Loading

0 comments on commit d61abd4

Please sign in to comment.