Skip to content
This repository has been archived by the owner on Jan 28, 2022. It is now read-only.

Commit

Permalink
Remove postcreatecommand. Doc cache reset
Browse files Browse the repository at this point in the history
  • Loading branch information
lawrencegripper committed Dec 4, 2019
1 parent 21398ff commit 1fd82ba
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 3 deletions.
1 change: 0 additions & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
"workspaceFolder": "/workspace",
"context": "..",
"workspaceMount": "src=${localWorkspaceFolder},dst=/workspace,type=bind",
"postCreateCommand": "make set-kindcluster",
"runArgs": [
// Mount the env file
"--env-file", "${localWorkspaceFolder}/.devcontainer/.env",
Expand Down
19 changes: 17 additions & 2 deletions docs/contributing.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,15 +51,30 @@ If you are using Visual Studio Code with [Remote - Containers](https://marketpla
```
7. Once your kind cluster has been created, you can now start testing your Azure Databicks Operator within your own local kubernetes environment!

## Advanced: DevContainer Cache

To speedup start times for the `devcontainer` and reduce the requirement for internet connectivity when starting we cache the `.vscodeserver` and `/go/pkg` folder to docker volumes. The [VSCode docs cover this topic here](https://code.visualstudio.com/docs/remote/containers-advanced#_avoiding-extension-reinstalls-on-container-rebuild).

The downside is that changes to the `extension` list in `devcontainer.json` won't automatically be picked up. To clear the cache run `docker volume rm dboperator-vscodecache -f`.

If an instance of the `devcontainer` is currently running you'll need to stop that before clearing the cache using `docker ps` and then locating the container with a name `vsc-azure-databricks-operator-*` and using `docker rm -f CONTAINER-NAME-HERE` to remove it.

In `bash` the following will automate the process:

```
docker ps | grep vsc-azure-databricks | awk '{print $1}' | xargs docker rm -f
docker volume rm dboperator-vscodecache -f
docker volume rm dboperator-gomodcache -f
```

# Building and Running the operator

## Basics
The scaffolding for the project is generated using `Kubebuilder`. It is a good idea to become familiar with this [project](https://github.com/kubernetes-sigs/kubebuilder). The [quick start](https://book.kubebuilder.io/quick-start.html) guide is also quite useful.

See `Makefile` at the root directory of the project. By default, executing `make` will build the project and produce an executable at `./bin/manager`

For example, to quick start
>this assumes dependencies have been downloaded and existing CRDs have been installed. See next section
For example, to quick start this assumes dependencies have been downloaded and existing CRDs have been installed. See next section
```
$ git clone https://github.com/microsoft/azure-databricks-operator.git
$ cd azure-databricks-operator
Expand Down

0 comments on commit 1fd82ba

Please sign in to comment.