Skip to content

Commit 37ca891

Browse files
authored
Merge pull request #1949 from hirosystems/develop
Merge develop into beta
2 parents db9ad23 + fc2ac03 commit 37ca891

15 files changed

+1228
-4926
lines changed

.github/workflows/ci.yml

Lines changed: 4 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -851,13 +851,6 @@ jobs:
851851

852852
build-publish:
853853
runs-on: ubuntu-latest
854-
needs:
855-
- lint
856-
- lint-docs
857-
- test
858-
- test-bns
859-
- test-rosetta
860-
- test-rosetta-cli-construction
861854
steps:
862855
- uses: actions/checkout@v3
863856
with:
@@ -886,6 +879,9 @@ jobs:
886879
@semantic-release/[email protected]
887880
888881
882+
- name: Set up QEMU
883+
uses: docker/setup-qemu-action@v3
884+
889885
- name: Set up Docker Buildx
890886
uses: docker/setup-buildx-action@v3
891887

@@ -903,20 +899,6 @@ jobs:
903899
type=semver,pattern={{major}}.{{minor}},value=${{ steps.semantic.outputs.new_release_version }},enable=${{ steps.semantic.outputs.new_release_version != '' }}
904900
type=raw,value=latest,enable={{is_default_branch}}
905901
906-
- name: Docker Standalone Meta
907-
id: meta_standalone
908-
uses: docker/metadata-action@v5
909-
with:
910-
images: |
911-
blockstack/${{ github.event.repository.name }}-standalone
912-
hirosystems/${{ github.event.repository.name }}-standalone
913-
tags: |
914-
type=ref,event=branch
915-
type=ref,event=pr
916-
type=semver,pattern={{version}},value=${{ steps.semantic.outputs.new_release_version }},enable=${{ steps.semantic.outputs.new_release_version != '' }}
917-
type=semver,pattern={{major}}.{{minor}},value=${{ steps.semantic.outputs.new_release_version }},enable=${{ steps.semantic.outputs.new_release_version != '' }}
918-
type=raw,value=latest,enable={{is_default_branch}}
919-
920902
- name: Login to DockerHub
921903
uses: docker/login-action@v3
922904
with:
@@ -927,23 +909,12 @@ jobs:
927909
uses: docker/build-push-action@v5
928910
with:
929911
context: .
912+
platforms: ${{ (github.ref == 'refs/heads/master' || github.ref == 'refs/heads/beta') && 'linux/amd64,linux/arm64' || 'linux/amd64' }}
930913
tags: ${{ steps.meta.outputs.tags }}
931914
labels: ${{ steps.meta.outputs.labels }}
932915
# Only push if (there's a new release on main branch, or if building a non-main branch) and (Only run on non-PR events or only PRs that aren't from forks)
933916
push: ${{ (github.ref != 'refs/heads/master' || steps.semantic.outputs.new_release_version != '') && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository) }}
934917

935-
- name: Build/Tag/Push Standalone Image
936-
uses: docker/build-push-action@v5
937-
with:
938-
context: .
939-
build-args: |
940-
STACKS_API_VERSION=${{ github.head_ref || github.ref_name }}
941-
file: docker/rosetta.Dockerfile
942-
tags: ${{ steps.meta_standalone.outputs.tags }}
943-
labels: ${{ steps.meta_standalone.outputs.labels }}
944-
# Only push if (there's a new release on main branch, or if building a non-main branch) and (Only run on non-PR events or only PRs that aren't from forks)
945-
push: ${{ (github.ref != 'refs/heads/master' || steps.semantic.outputs.new_release_version != '') && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository) }}
946-
947918
- name: API Discord notification
948919
if: steps.semantic.outputs.new_release_version != ''
949920
uses: Ilshidur/action-discord@master

README.md

Lines changed: 13 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -7,44 +7,38 @@
77

88
## Quick start
99

10-
A self-contained Docker image is provided, which starts a Stacks 2.05 blockchain and API instance.
10+
### Local
1111

12-
Ensure Docker is installed, then run the command:
12+
This service requires `postgres`, `stacks-node`, `bitcoind`, and a few other components in order to run.
13+
The [`clarinet`](https://github.com/hirosystems/clarinet) project provides an easy way to spin up the API and all these services:
14+
> clarinet devnet - a local standalone development environment that simulates Bitcoin, Stacks node and other helpful components, similar to a staging environment.
1315
14-
```shell
15-
docker run -p 3999:3999 hirosystems/stacks-blockchain-api-standalone
16-
```
16+
Get started at https://docs.hiro.so/clarinet/getting-started
1717

18-
Similarly, a "mocknet" instance can be started. This runs a local node, isolated from the testnet/mainnet:
18+
### Production
1919

20-
```shell
21-
docker run -p 3999:3999 -e STACKS_NETWORK=mocknet hirosystems/stacks-blockchain-api-standalone
22-
```
20+
The docker image `hirosystems/stacks-blockchain-api` is recommended when running the API in a mainnet or testnet environment.
21+
22+
Note that this image cannot be ran standalone. Other services need to be configured correctly and running. For more information see https://docs.hiro.so/stacks-blockchain-api/how-to-guides/how-to-run-api-node
2323

24-
Once the blockchain has synced with the network, the API will be available at:
25-
[http://localhost:3999](http://localhost:3999)
2624

2725
## Development quick start
2826

2927
First, ensure Docker is installed on your machine.
3028

3129
Clone repo and install dependencies with `npm install`.
3230

33-
Run `npm run dev:integrated`.
31+
VSCode is recommended for development. Pre-configured "run and debug" configurations are included. Run using `Launch: w/ postgres`.
3432

35-
This command will concurrently start the API server app and the service dependencies.
33+
Alternatively, use the command `npm run dev:integrated` -- this command will concurrently start the API server app and the service dependencies.
3634

3735
Check to see if the server started successfully by visiting http://localhost:3999/extended/v1/status
3836

3937
## Local Development
4038

41-
### Setup Services
42-
43-
Then run `npm run devenv:deploy`, which uses docker-compose to deploy the service dependencies (e.g., PostgreSQL, Stacks core node, etc.)
44-
45-
### Running the server
39+
To run the server, run `npm run dev:integrated`, which uses docker-compose to deploy the service dependencies (e.g., PostgreSQL, Stacks core node, etc.).
4640

47-
To run the server in 'watch' mode (restart for every code change), run `npm run dev:watch`. You'll have a server on port 3999.
41+
You'll have a server on port 3999.
4842

4943
# Architecture
5044

config/token-metadata-image-cache-imgix.js

Lines changed: 0 additions & 7 deletions
This file was deleted.

0 commit comments

Comments
 (0)