{"id":16430169,"url":"https://github.com/its-alex/bitwarden-setup-for-developer-environment-example","last_synced_at":"2025-02-25T08:18:36.002Z","repository":{"id":169114293,"uuid":"645011874","full_name":"Its-Alex/bitwarden-setup-for-developer-environment-example","owner":"Its-Alex","description":"This repository aims to guide developers on setting up Bitwarden locally as a vault in their development environment.","archived":false,"fork":false,"pushed_at":"2023-06-07T12:47:33.000Z","size":22,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-02-23T11:12:28.529Z","etag":null,"topics":["bitwarden","environment","example","playground","setup"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Its-Alex.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-05-24T18:18:20.000Z","updated_at":"2024-05-27T09:49:21.000Z","dependencies_parsed_at":null,"dependency_job_id":"418cf3f4-94b1-4676-ac23-90e0f002898f","html_url":"https://github.com/Its-Alex/bitwarden-setup-for-developer-environment-example","commit_stats":{"total_commits":4,"total_committers":2,"mean_commits":2.0,"dds":0.25,"last_synced_commit":"8b480d1f7e208631bfb13e0f6b964920d94fe6a6"},"previous_names":["its-alex/bitwarden-setup-for-developer-environment"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Its-Alex%2Fbitwarden-setup-for-developer-environment-example","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Its-Alex%2Fbitwarden-setup-for-developer-environment-example/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Its-Alex%2Fbitwarden-setup-for-developer-environment-example/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Its-Alex%2Fbitwarden-setup-for-developer-environment-example/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Its-Alex","download_url":"https://codeload.github.com/Its-Alex/bitwarden-setup-for-developer-environment-example/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240627959,"owners_count":19831600,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bitwarden","environment","example","playground","setup"],"created_at":"2024-10-11T08:25:57.558Z","updated_at":"2025-02-25T08:18:35.966Z","avatar_url":"https://github.com/Its-Alex.png","language":"Shell","readme":"## Bitwarden setup for Developer environment\n\nThis documentation aims to guide developers on setting up Bitwarden locally as\na vault in their development environment.\n\nBy using Docker, we can launch a local Bitwarden instance and automatically\nconnect to it whenever we enter the folder of this repository. Additionally, we\nwill automatically load secrets into the environment.\n\nThis approach allows developers to share secrets and use them locally on a\nday-to-day basis.\n\n### Why it matters\n\n1. Increased productivity: When a development environment launches quickly, developers can start working more promptly. This avoids frustrating waiting times and allows developers to focus on the task at hand without interruptions. Increased productivity means projects can be delivered more swiftly.\n1. Reduced errors: Automated development environments ensure that all the required configurations for the project are set up consistently. This prevents human errors associated with manually configuring the environment. Incorrect configuration can lead to bugs or compatibility issues that slow down development. An automated environment reduces these risks by providing a consistent working environment for all developers.\n1. Collaboration ease: When all members of a development team use the same automated development environment, collaboration becomes easier. Each developer has access to the same tools and configurations, facilitating code sharing, issue resolution, and communication. Automated development environments foster a consistent approach to development and enable more efficient collaboration.\n1. Flexibility and scalability: Automated development environments can be easily replicated and expanded as project needs evolve. If new developers join the team or if additional resources are required, the automated environment can be quickly provisioned. This allows for flexibility in scaling the development environment to accommodate changing project requirements.\n\n\n\n## Requirements\n\n- [`rtx`](https://github.com/jdxcode/rtx)\n- [`docker`](https://www.docker.com/)\n\nTo integrate `rtx` and `direnv` with your shell login, you need to add hooks:\n\n- [`rtx hooks`](https://github.com/jdxcode/rtx#quickstart)\n- [`direnv hooks`](https://direnv.net/docs/hook.html)\n\nFollow the steps below to add the hooks:\n\nIf you use **bash**, execute:\n```sh\n$ echo 'eval \"$(~/bin/rtx activate bash)\"' \u003e\u003e ~/.bashrc\n$ echo -e \"\\neval \"\\$(direnv hook bash)\"\" \u003e\u003e ~/.bashrc\n```\nIf you use **zsh**, execute:\n```sh\n$ echo 'eval \"$(~/bin/rtx activate zsh)\"' \u003e\u003e ~/.zshrc\n$ echo -e \"\\neval \"\\$(direnv hook zsh)\"\" \u003e\u003e ~/.zshrc\n```\nThen, to apply the configuration, restart your terminal or simply execute this command:\n\n**Bash**\n```sh\n$ source ~/.bashrc\n```\n\n**Zsh**\n```sh\n$ source ~/.zshrc\n```\n\nTo set up the required tools, you need to install them locally. When you are in\nthe folder of the repository, use the following command:\n\n```sh\n$ rtx install\n```\n\n## Getting Started\n\nFor this example, Bitwarden will be launched locally. To launch it, run the\nfollowing command:\n\n```sh\n$ ./scripts/setup.sh\n[+] Building 0.0s (0/0)\n[+] Running 1/0\n ✔ Container bitwarden-vaultwarden-1  Running\nWaiting for vaultwarden:80  .  up!\nEverything is up\nSaved setting `config`.\n\n\nBitwarden is automatically setup, default login are:\n\nemail: admin@example.com\npassword: master_password\n```\n\nNext, we will configure the .envrc file to load automatically each time we enter\nthis repository, in order to load secrets. You will be prompted to enter your\nemail and password:\n\n```sh\n$ direnv allow\ndirenv: loading ~/bitwarden/.envrc\ndirenv: using rtx\n? Email address: admin@example.com\n? Master password: [input is hidden] direnv: ([/usr/bin/direnv export zsh]) is taking a while to execute. Use CTRL-C to give up.\n? Master password: [hidden]\nSyncing complete.\ndirenv: export +BW_SESSION +TEST_PASSWORD +TEST_USERNAME\n```\n\nYou can now verify that environment variables are loaded:\n\n```sh\n$ echo \"${TEST_USERNAME} ${TEST_PASSWORD}\"\ntest password\n```\n## Uninstall\n\nTo remove the bitwarden instance use:\n\n```sh\n$ docker-compose down\n[+] Running 2/2\n ✔ Container bitwarden-vaultwarden-1  Removed\n ✔ Network bitwarden_default          Removed\n```\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fits-alex%2Fbitwarden-setup-for-developer-environment-example","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fits-alex%2Fbitwarden-setup-for-developer-environment-example","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fits-alex%2Fbitwarden-setup-for-developer-environment-example/lists"}