Skip to content

Commit

Permalink
refactor projcet root
Browse files Browse the repository at this point in the history
Signed-off-by: ozkanonur <work@onurozkan.dev>
  • Loading branch information
onur-ozkan committed Mar 27, 2023
1 parent 759d180 commit dd51568
Show file tree
Hide file tree
Showing 81 changed files with 38 additions and 683 deletions.
2 changes: 1 addition & 1 deletion Dockerfile → .docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
# docker build --tag mm2 .

# NB: The version here was picked to match the one tested in our CI. The latest Travis has (as of 2018-11) is Xenial.
FROM ubuntu:xenial
FROM docker.io/ubuntu:xenial

RUN \
apt-get update &&\
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:16.04
FROM docker.io/ubuntu:16.04

RUN apt-get update && \
apt-get install -y --no-install-recommends \
Expand All @@ -23,7 +23,7 @@ RUN apt-get update && \
libc6-dev-i386 && \
apt-get clean

COPY android-ndk.sh /
COPY ./scripts/ci/android-ndk.sh /
RUN bash /android-ndk.sh arm64 21
ENV PATH=$PATH:/android-ndk/bin
ENV RUSTFMT=rustfmt
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:16.04
FROM docker.io/ubuntu:16.04

RUN apt-get update && \
apt-get install -y --no-install-recommends \
Expand All @@ -23,7 +23,7 @@ RUN apt-get update && \
libc6-dev-i386 && \
apt-get clean

COPY android-ndk.sh /
COPY ./scripts/ci/android-ndk.sh /
RUN bash /android-ndk.sh arm 21
ENV PATH=$PATH:/android-ndk/bin
ENV RUSTFMT=rustfmt
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM rustembedded/cross:armv7-unknown-linux-gnueabihf-0.2.1
FROM docker.io/rustembedded/cross:armv7-unknown-linux-gnueabihf-0.2.1
RUN dpkg --add-architecture armhf
RUN apt-get update && apt-get install -y llvm-3.9-dev libclang-3.9-dev clang-3.9 libc6-dev-i386 libssl-dev:armhf && apt-get install -y g++-arm-linux-gnueabihf && apt-get clean
ENV CMAKE_FORCE_C_COMPILER=arm-linux-gnueabihf-gcc \
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.dev-release → .docker/Dockerfile.dev-release
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM debian:stable-slim
FROM docker.io/debian:stable-slim
WORKDIR /mm2
COPY target/ci/mm2 /usr/local/bin/mm2
EXPOSE 7783
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:16.04
FROM docker.io/ubuntu:16.04

RUN apt-get update && \
apt-get install -y --no-install-recommends \
Expand All @@ -23,7 +23,7 @@ RUN apt-get update && \
libc6-dev-i386 && \
apt-get clean

COPY android-ndk.sh /
COPY ./scripts/ci/android-ndk.sh /
RUN bash /android-ndk.sh x86 21
ENV PATH=$PATH:/android-ndk/bin
ENV RUSTFMT=rustfmt
Expand Down
6 changes: 3 additions & 3 deletions Dockerfile.parity.dev → .docker/Dockerfile.parity.dev
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# Setup Ethereum dev blockchain with pre-deployed swap contract and ERC20 token.
# For more info check Parity docs: https://wiki.parity.io/Private-development-chain and chain config file: parity.dev.chain.json
# Usage example:
# docker build . -f Dockerfile.parity.dev -t artempikulin/parity_dev_node
# docker build . -f .docker/Dockerfile.parity.dev -t artempikulin/parity_dev_node
# docker run -p 8545:8545 artempikulin/parity_dev_node
FROM parity/parity:beta
COPY parity.dev.chain.json /home/parity/.local/share/io.parity.ethereum/chain.json
FROM docker.io/parity/parity:beta
COPY .docker/parity.dev.chain.json /home/parity/.local/share/io.parity.ethereum/chain.json
USER root
RUN chmod -R 777 /home/parity/.local/share/io.parity.ethereum
USER parity
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.release → .docker/Dockerfile.release
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM debian:stable-slim
FROM docker.io/debian:stable-slim
WORKDIR /mm2
COPY target/release/mm2 /usr/local/bin/mm2
EXPOSE 7783
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.ubuntu.ci → .docker/Dockerfile.ubuntu.ci
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:xenial-20151218.1
FROM docker.io/ubuntu:xenial-20151218.1

RUN \
apt-get update &&\
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:16.04
FROM docker.io/ubuntu:16.04

RUN apt-get update && \
apt-get install -y --no-install-recommends \
Expand All @@ -24,7 +24,7 @@ RUN apt-get update && \
libc6-dev-i386 && \
apt-get clean

COPY android-ndk.sh /
COPY ./scripts/ci/android-ndk.sh /
RUN bash /android-ndk.sh x86_64 21
ENV PATH=$PATH:/android-ndk/bin
ENV RUSTFMT=rustfmt
Expand Down
File renamed without changes.
6 changes: 3 additions & 3 deletions .github/workflows/dev-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ jobs:
if: github.event_name != 'pull_request'
run: |
CONTAINER_TAG="dev-$COMMIT_HASH"
docker build -t komodoofficial/atomicdexapi:"$CONTAINER_TAG" -t komodoofficial/atomicdexapi:dev-latest -f Dockerfile.dev-release .
docker build -t komodoofficial/atomicdexapi:"$CONTAINER_TAG" -t komodoofficial/atomicdexapi:dev-latest -f .docker/Dockerfile.dev-release .
docker push komodoofficial/atomicdexapi:"$CONTAINER_TAG"
docker push komodoofficial/atomicdexapi:dev-latest
Expand Down Expand Up @@ -296,7 +296,7 @@ jobs:
rustup target add aarch64-linux-android
- name: Setup NDK
run: ./android-ndk.sh x86 21
run: ./scripts/ci/android-ndk.sh x86 21

- name: Calculate commit hash for PR commit
if: github.event_name == 'pull_request'
Expand Down Expand Up @@ -344,7 +344,7 @@ jobs:
rustup target add armv7-linux-androideabi
- name: Setup NDK
run: ./android-ndk.sh x86 21
run: ./scripts/ci/android-ndk.sh x86 21

- name: Calculate commit hash for PR commit
if: github.event_name == 'pull_request'
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/release-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ jobs:
- name: Build and push container image
run: |
export CONTAINER_TAG=$(./target/release/mm2 --version | awk '{print $3}')
docker build -t komodoofficial/atomicdexapi:"$CONTAINER_TAG" -t komodoofficial/atomicdexapi:main-latest -f Dockerfile.release .
docker build -t komodoofficial/atomicdexapi:"$CONTAINER_TAG" -t komodoofficial/atomicdexapi:main-latest -f .docker/Dockerfile.release .
docker push komodoofficial/atomicdexapi:"$CONTAINER_TAG"
docker push komodoofficial/atomicdexapi:main-latest
Expand Down Expand Up @@ -291,7 +291,7 @@ jobs:
rustup target add aarch64-linux-android
- name: Setup NDK
run: ./android-ndk.sh x86 21
run: ./scripts/ci/android-ndk.sh x86 21

- name: Calculate commit hash for PR commit
if: github.event_name == 'pull_request'
Expand Down Expand Up @@ -339,7 +339,7 @@ jobs:
rustup target add armv7-linux-androideabi
- name: Setup NDK
run: ./android-ndk.sh x86 21
run: ./scripts/ci/android-ndk.sh x86 21

- name: Calculate commit hash for PR commit
if: github.event_name == 'pull_request'
Expand Down
13 changes: 6 additions & 7 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,12 @@ DB/*

.env.client
.env.seed
etomic_build/client/DB
etomic_build/client/stats.log
etomic_build/client/unparsed.txt
etomic_build/seed/DB
etomic_build/seed/stats.log
etomic_build/seed/unparsed.txt
iguana/exchanges/manychains
scripts/mm2/client/DB
scripts/mm2/client/stats.log
scripts/mm2/client/unparsed.txt
scripts/mm2/seed/DB
scripts/mm2/seed/stats.log
scripts/mm2/seed/unparsed.txt

/marketmaker_depends
/x64
Expand Down
110 changes: 0 additions & 110 deletions .gitlab-ci.yml

This file was deleted.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ Refer to the [Komodo Developer Docs](https://developers.komodoplatform.com/basic

## Additional docs for developers

- [Contribution guide](./CONTRIBUTING.md)
- [Contribution guide](./docs/CONTRIBUTING.md)
- [Setting up the environment to run the full tests suite](./docs/DEV_ENVIRONMENT.md)
- [Git flow and general workflow](./docs/GIT_FLOW_AND_WORKING_PROCESS.md)
- [Komodo Developer Docs](https://developers.komodoplatform.com/basic-docs/atomicdex/introduction-to-atomicdex.html)
Expand Down
8 changes: 4 additions & 4 deletions docs/ANDROID.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,19 +27,19 @@ The [Android NDK installer](https://github.com/rust-embedded/cross/tree/master/d

#### armeabi-v7a ABI Docker image

(cd supernet && docker build --tag armv7-linux-androideabi-aga -f Dockerfile.armv7-linux-androideabi .)
(cd supernet && docker build --tag armv7-linux-androideabi-aga -f .docker/Dockerfile.armv7-linux-androideabi .)

#### arm64-v8a ABI Docker image

(cd supernet && docker build --tag aarch64-linux-android-aga -f Dockerfile.aarch64-linux-android .)
(cd supernet && docker build --tag aarch64-linux-android-aga -f .docker/Dockerfile.aarch64-linux-android .)

### x86 ABI Docker image

(cd supernet && docker build --tag i686-linux-android-aga -f Dockerfile.i686-linux-android .)
(cd supernet && docker build --tag i686-linux-android-aga -f .docker/Dockerfile.i686-linux-android .)

### x86_64 ABI Docker image

(cd supernet && docker build --tag x86_64-linux-android-aga -f Dockerfile.x86_64-linux-android .)
(cd supernet && docker build --tag x86_64-linux-android-aga -f .docker/Dockerfile.x86_64-linux-android .)

### Setup the NDK_HOME variable

Expand Down
2 changes: 1 addition & 1 deletion docs/ANDROID_CROSS_ON_M1_MAC.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

1. Ensure that your terminal is added to `Developer tools` in MacOS Security & Privacy settings.
2. The cross-compilation requires Android NDK version 21. Custom brew cask file is located at the root of this repo.
3. Install android-ndk by `brew install --cask android-ndk.rb` or other preferred way.
3. Install android-ndk by `brew install --cask ./scripts/ci/android-ndk.rb` or other preferred way.
4. Add Android targets via rustup
```shell
rustup target add armv7-linux-androideabi
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion docs/RASPBERRY_PI4_CROSS.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@ rustup install nightly
rustup default nightly
```
2. Install cross: `cargo install cross`.
3. Build the Docker image for cross compilation: `docker build -f Dockerfile.armv7-unknown-linux-gnueabihf -t mm2-armv7-unknown-linux-gnueabihf .`
3. Build the Docker image for cross compilation: `docker build -f .docker/Dockerfile.armv7-unknown-linux-gnueabihf -t mm2-armv7-unknown-linux-gnueabihf .`
4. Build mm2: `cross build --target armv7-unknown-linux-gnueabihf` or `cross build --target armv7-unknown-linux-gnueabihf --release` for release build.
5. The binary path will be `target/armv7-unknown-linux-gnueabihf/debug/mm2` or `target/armv7-unknown-linux-gnueabihf/release/mm2` for release build.
3 changes: 3 additions & 0 deletions examples/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# AtomicDEX-API Examples

This directory contains example implementation/use cases of AtomicDEX-API
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading

0 comments on commit dd51568

Please sign in to comment.