Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
N
nebula
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
exchain
nebula
Commits
9c1ee08c
Commit
9c1ee08c
authored
Aug 23, 2023
by
Trajan0x
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
deprecate docker-compose
parent
cfa5e24a
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
20 additions
and
20 deletions
+20
-20
CONTRIBUTING.md
CONTRIBUTING.md
+9
-9
Makefile
Makefile
+3
-3
__init__.py
bedrock-devnet/devnet/__init__.py
+4
-4
README.md
indexer/README.md
+1
-1
README.md
indexer/ui/README.md
+1
-1
devnet.md
specs/meta/devnet.md
+2
-2
No files found.
CONTRIBUTING.md
View file @
9c1ee08c
...
@@ -119,7 +119,7 @@ Note that these environment variables significantly speed up build time.
...
@@ -119,7 +119,7 @@ Note that these environment variables significantly speed up build time.
cd
ops-bedrock
cd
ops-bedrock
export
COMPOSE_DOCKER_CLI_BUILD
=
1
export
COMPOSE_DOCKER_CLI_BUILD
=
1
export
DOCKER_BUILDKIT
=
1
export
DOCKER_BUILDKIT
=
1
docker
-
compose build
docker
compose build
```
```
Source code changes can have an impact on more than one container.
Source code changes can have an impact on more than one container.
...
@@ -127,9 +127,9 @@ Source code changes can have an impact on more than one container.
...
@@ -127,9 +127,9 @@ Source code changes can have an impact on more than one container.
```
bash
```
bash
cd
ops-bedrock
cd
ops-bedrock
docker
-
compose down
docker
compose down
docker
-
compose build
docker
compose build
docker
-
compose up
docker
compose up
```
```
**If a node process exits with exit code: 137**
you may need to increase the default memory limit of docker containers
**If a node process exits with exit code: 137**
you may need to increase the default memory limit of docker containers
...
@@ -141,18 +141,18 @@ cd optimism
...
@@ -141,18 +141,18 @@ cd optimism
pnpm clean
pnpm clean
pnpm build
pnpm build
cd
ops
cd
ops
docker
-
compose down
-v
docker
compose down
-v
docker
-
compose build
docker
compose build
docker
-
compose up
docker
compose up
```
```
#### Viewing docker container logs
#### Viewing docker container logs
By default, the
`docker
-
compose up`
command will show logs from all services, and that
By default, the
`docker
compose up`
command will show logs from all services, and that
can be hard to filter through. In order to view the logs from a specific service, you can run:
can be hard to filter through. In order to view the logs from a specific service, you can run:
```
bash
```
bash
docker
-
compose logs
--follow
<service name>
docker
compose logs
--follow
<service name>
```
```
### Running tests
### Running tests
...
...
Makefile
View file @
9c1ee08c
...
@@ -101,13 +101,13 @@ devnet-test:
...
@@ -101,13 +101,13 @@ devnet-test:
.PHONY
:
devnet-test
.PHONY
:
devnet-test
devnet-down
:
devnet-down
:
@
(
cd
./ops-bedrock
&&
GENESIS_TIMESTAMP
=
$(
shell
date
+%s
)
docker
-
compose stop
)
@
(
cd
./ops-bedrock
&&
GENESIS_TIMESTAMP
=
$(
shell
date
+%s
)
docker
compose stop
)
.PHONY
:
devnet-down
.PHONY
:
devnet-down
devnet-clean
:
devnet-clean
:
rm
-rf
./packages/contracts-bedrock/deployments/devnetL1
rm
-rf
./packages/contracts-bedrock/deployments/devnetL1
rm
-rf
./.devnet
rm
-rf
./.devnet
cd
./ops-bedrock
&&
docker
-
compose down
cd
./ops-bedrock
&&
docker
compose down
docker image
ls
'ops-bedrock*'
--format
=
'{{.Repository}}'
| xargs
-r
docker rmi
docker image
ls
'ops-bedrock*'
--format
=
'{{.Repository}}'
| xargs
-r
docker rmi
docker volume
ls
--filter
name
=
ops-bedrock
--format
=
'{{.Name}}'
| xargs
-r
docker volume
rm
docker volume
ls
--filter
name
=
ops-bedrock
--format
=
'{{.Name}}'
| xargs
-r
docker volume
rm
.PHONY
:
devnet-clean
.PHONY
:
devnet-clean
...
@@ -116,7 +116,7 @@ devnet-allocs:
...
@@ -116,7 +116,7 @@ devnet-allocs:
PYTHONPATH
=
./bedrock-devnet python3 ./bedrock-devnet/main.py
--monorepo-dir
=
.
--allocs
PYTHONPATH
=
./bedrock-devnet python3 ./bedrock-devnet/main.py
--monorepo-dir
=
.
--allocs
devnet-logs
:
devnet-logs
:
@
(
cd
./ops-bedrock
&&
docker
-
compose logs
-f
)
@
(
cd
./ops-bedrock
&&
docker
compose logs
-f
)
.PHONY: devnet-logs
.PHONY: devnet-logs
test-unit
:
test-unit
:
...
...
bedrock-devnet/devnet/__init__.py
View file @
9c1ee08c
...
@@ -93,7 +93,7 @@ def main():
...
@@ -93,7 +93,7 @@ def main():
return
return
log
.
info
(
'Building docker images'
)
log
.
info
(
'Building docker images'
)
run_command
([
'docker
-
compose'
,
'build'
,
'--progress'
,
'plain'
],
cwd
=
paths
.
ops_bedrock_dir
,
env
=
{
run_command
([
'docker
'
,
'
compose'
,
'build'
,
'--progress'
,
'plain'
],
cwd
=
paths
.
ops_bedrock_dir
,
env
=
{
'PWD'
:
paths
.
ops_bedrock_dir
'PWD'
:
paths
.
ops_bedrock_dir
})
})
...
@@ -173,7 +173,7 @@ def devnet_deploy(paths):
...
@@ -173,7 +173,7 @@ def devnet_deploy(paths):
],
cwd
=
paths
.
op_node_dir
)
],
cwd
=
paths
.
op_node_dir
)
log
.
info
(
'Starting L1.'
)
log
.
info
(
'Starting L1.'
)
run_command
([
'docker
-
compose'
,
'up'
,
'-d'
,
'l1'
],
cwd
=
paths
.
ops_bedrock_dir
,
env
=
{
run_command
([
'docker
'
,
'
compose'
,
'up'
,
'-d'
,
'l1'
],
cwd
=
paths
.
ops_bedrock_dir
,
env
=
{
'PWD'
:
paths
.
ops_bedrock_dir
'PWD'
:
paths
.
ops_bedrock_dir
})
})
wait_up
(
8545
)
wait_up
(
8545
)
...
@@ -196,7 +196,7 @@ def devnet_deploy(paths):
...
@@ -196,7 +196,7 @@ def devnet_deploy(paths):
addresses
=
read_json
(
paths
.
addresses_json_path
)
addresses
=
read_json
(
paths
.
addresses_json_path
)
log
.
info
(
'Bringing up L2.'
)
log
.
info
(
'Bringing up L2.'
)
run_command
([
'docker
-
compose'
,
'up'
,
'-d'
,
'l2'
],
cwd
=
paths
.
ops_bedrock_dir
,
env
=
{
run_command
([
'docker
'
,
'
compose'
,
'up'
,
'-d'
,
'l2'
],
cwd
=
paths
.
ops_bedrock_dir
,
env
=
{
'PWD'
:
paths
.
ops_bedrock_dir
'PWD'
:
paths
.
ops_bedrock_dir
})
})
wait_up
(
9545
)
wait_up
(
9545
)
...
@@ -208,7 +208,7 @@ def devnet_deploy(paths):
...
@@ -208,7 +208,7 @@ def devnet_deploy(paths):
log
.
info
(
f
'Using batch inbox {batch_inbox_address}'
)
log
.
info
(
f
'Using batch inbox {batch_inbox_address}'
)
log
.
info
(
'Bringing up everything else.'
)
log
.
info
(
'Bringing up everything else.'
)
run_command
([
'docker
-
compose'
,
'up'
,
'-d'
,
'op-node'
,
'op-proposer'
,
'op-batcher'
],
cwd
=
paths
.
ops_bedrock_dir
,
env
=
{
run_command
([
'docker
'
,
'
compose'
,
'up'
,
'-d'
,
'op-node'
,
'op-proposer'
,
'op-batcher'
],
cwd
=
paths
.
ops_bedrock_dir
,
env
=
{
'PWD'
:
paths
.
ops_bedrock_dir
,
'PWD'
:
paths
.
ops_bedrock_dir
,
'L2OO_ADDRESS'
:
l2_output_oracle
,
'L2OO_ADDRESS'
:
l2_output_oracle
,
'SEQUENCER_BATCH_INBOX_ADDRESS'
:
batch_inbox_address
'SEQUENCER_BATCH_INBOX_ADDRESS'
:
batch_inbox_address
...
...
indexer/README.md
View file @
9c1ee08c
...
@@ -16,7 +16,7 @@ All tests can be ran by running `make test` from the `/indexer` directory. This
...
@@ -16,7 +16,7 @@ All tests can be ran by running `make test` from the `/indexer` directory. This
-
install docker
-
install docker
-
`cp example.env .env`
-
`cp example.env .env`
-
fill in .env
-
fill in .env
-
run
`docker
-
compose up`
to start the indexer vs optimism goerli network
-
run
`docker
compose up`
to start the indexer vs optimism goerli network
### Run indexer with go
### Run indexer with go
...
...
indexer/ui/README.md
View file @
9c1ee08c
...
@@ -7,7 +7,7 @@ A simple UI for exploring the indexer DB using [Prisma studio](https://www.prism
...
@@ -7,7 +7,7 @@ A simple UI for exploring the indexer DB using [Prisma studio](https://www.prism
Included in the docker-compose file as
`ui`
service
Included in the docker-compose file as
`ui`
service
```
bash
```
bash
docker
-
compose up
docker
compose up
```
```
Prisma can be viewed at
[
localhost:5555
](
http://localhost:5555
)
Prisma can be viewed at
[
localhost:5555
](
http://localhost:5555
)
...
...
specs/meta/devnet.md
View file @
9c1ee08c
...
@@ -9,9 +9,9 @@
...
@@ -9,9 +9,9 @@
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
You can spin up a local devnet via
`docker
-
compose`
.
You can spin up a local devnet via
`docker
compose`
.
For convenience, we have defined
`make`
targets to start and stop the devnet with a single command.
For convenience, we have defined
`make`
targets to start and stop the devnet with a single command.
To run the devnet, you will need
`docker`
and
`docker-compose`
installed.
To run the devnet, you will need
`docker`
installed.
Then, as a precondition, make sure that you have compiled the contracts by
`cd`
ing into
`packages/contracts`
Then, as a precondition, make sure that you have compiled the contracts by
`cd`
ing into
`packages/contracts`
and running
`pnpm i`
followed by
`pnpm build`
. You'll only need to do this if you change the contracts in the future.
and running
`pnpm i`
followed by
`pnpm build`
. You'll only need to do this if you change the contracts in the future.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment