fix(ci): cleanup prev release; TODO to issues #12
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build and Release Mainnet | |
on: | |
workflow_dispatch: | |
push: | |
branches: [ "stagenet" ] | |
jobs: | |
deploy_image: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up docker buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: Login to docker hub | |
run: docker login -u atletanetwork -p ${{ secrets.REGISTRYPASS }} docker.io | |
- name: Set timestamp variables | |
run: | | |
TIMESTAMP=$(date +%d%m%y-%H%M%S) | |
echo "TIMESTAMP: $TIMESTAMP" | |
- name: Build and push docker image | |
run: | | |
docker build --build-arg BUILD_FEATURES=mainnet-runtime --tag docker.io/atletanetwork/atleta-node:mainnet-${TIMESTAMP} . | |
docker tag docker.io/atletanetwork/atleta-node:mainnet-${TIMESTAMP} docker.io/atletanetwork/atleta-node:mainnet-latest | |
docker push docker.io/atletanetwork/atleta-node:mainnet-${TIMESTAMP} | |
docker push docker.io/atletanetwork/atleta-node:mainnet-latest |