diff --git a/.buildkite/pipeline.yml b/.buildkite/pipeline.yml deleted file mode 100644 index 501410e0..00000000 --- a/.buildkite/pipeline.yml +++ /dev/null @@ -1,20 +0,0 @@ -agents: - queue: "aws-v3-build-node-common" -steps: - - label: "Build" - command: | - docker compose run --build --rm builder echo Done - plugins: - - hasura/smooth-secrets#v1.3.2: - secrets: - - strategy: aws-secrets-manager - key: github-user-keys/hasura-ci - type: ssh - region: us-east-2 - - hasura/smooth-checkout#v4.3.2: - repos: - - config: - - url: git@github.com:hasura/ndc-hub.git - delete_checkout: true - # The following option makes sure that we get a unique folder to perform our CI build everytime - interpolate_checkout_path: "$BUILDKITE_BUILD_CHECKOUT_PATH/$BUILDKITE_BUILD_ID/$BUILDKITE_JOB_ID" \ No newline at end of file diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml new file mode 100644 index 00000000..63553c79 --- /dev/null +++ b/.github/workflows/build.yaml @@ -0,0 +1,24 @@ +name: build + +on: + push: + +jobs: + cargo-build: + name: cargo build + runs-on: ubuntu-latest + env: + CARGO_NET_GIT_FETCH_WITH_CLI: "true" + RUSTFLAGS: "-D warnings" # fail on warnings + steps: + - uses: actions/checkout@v4 + + - name: install tools + run: | + rustup show + + - uses: Swatinem/rust-cache@v2 + + - name: build + run: | + cargo build --release --all-targets --all-features diff --git a/Dockerfile b/Dockerfile deleted file mode 100644 index 972c929d..00000000 --- a/Dockerfile +++ /dev/null @@ -1,26 +0,0 @@ -FROM rust:1.76.0-slim-buster AS build - -WORKDIR app - -RUN apt-get update \ - && DEBIAN_FRONTEND=noninteractive \ - apt-get install --no-install-recommends --assume-yes \ - lld protobuf-compiler libssl-dev ssh git pkg-config - -ENV CARGO_HOME=/app/.cargo -ENV RUSTFLAGS="-C link-arg=-fuse-ld=lld" - -COPY Cargo.lock . -COPY ./rust-connector-sdk . - -RUN cargo build --release - -FROM debian:buster-slim as connector -RUN set -ex; \ - apt-get update; \ - DEBIAN_FRONTEND=noninteractive \ - apt-get install --no-install-recommends --assume-yes \ - libssl-dev -COPY --from=build /app/target/release/ndc_hub_example ./ndc_hub_example -ENTRYPOINT [ "/ndc_hub_example" ] -CMD [ "serve", "--configuration", "/etc/connector" ] diff --git a/docker-compose.yaml b/docker-compose.yaml deleted file mode 100644 index 976f462a..00000000 --- a/docker-compose.yaml +++ /dev/null @@ -1,6 +0,0 @@ -version: '3.7' -services: - builder: - build: - target: build - context: . \ No newline at end of file diff --git a/rust-toolchain.toml b/rust-toolchain.toml new file mode 100644 index 00000000..2492ee58 --- /dev/null +++ b/rust-toolchain.toml @@ -0,0 +1,4 @@ +[toolchain] +channel = "1.76.0" +profile = "default" # see https://rust-lang.github.io/rustup/concepts/profiles.html +components = ["rust-analyzer", "rust-src"] # see https://rust-lang.github.io/rustup/concepts/components.html