Skip to content

Commit

Permalink
chore(zk): clean volumes directory from container to fix permissions …
Browse files Browse the repository at this point in the history
…on linux (matter-labs#673)

## What ❔

Currently zk init may fail on linux due to docker creating files with
root permissions.

## Checklist

<!-- Check your PR fulfills the following items. -->
<!-- For draft PRs check the boxes as you complete them. -->

- [ ] PR title corresponds to the body of PR (we generate changelog
entries from PRs).
- [ ] Tests for the changes have been added / updated.
- [ ] Documentation comments have been added / updated.
- [ ] Code has been formatted via `zk fmt` and `zk lint`.
- [ ] Spellcheck has been run via `cargo spellcheck
--cfg=./spellcheck/era.cfg --code 1`.
  • Loading branch information
montekki authored Dec 13, 2023
1 parent 985c737 commit a6a6a90
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion infrastructure/zk/src/down.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import * as utils from './utils';
export async function down() {
await utils.spawn('docker compose down -v');
await utils.spawn('docker compose rm -s -f -v');
await utils.spawn('rm -rf ./volumes/');
await utils.spawn('docker run --rm -v ./volumes:/volumes postgres:14 bash -c "rm -rf /volumes/*"');
}

export const command = new Command('down').description('stop development containers').action(down);

0 comments on commit a6a6a90

Please sign in to comment.