aboutsummaryrefslogtreecommitdiffstats
path: root/.drone.yml
blob: 01cd46dc7a97ec59fce10f88017012fac4f959b7 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
---
kind: pipeline
type: docker
name: default

steps:
  - name: docker
    image: docker:stable-dind
    privileged: true
    detach: true
    command: [ "dockerd", "--host=tcp://0.0.0.0:2375" ]

  - name: test
    image: ezkrg/buildx:latest
    environment:
      USER:
        from_secret: DHU
      PASSWORD:
        from_secret: DHP
      DOCKER_HOST: tcp://docker:2375
    commands:
    - sleep 20
    - docker buildx create --use --name docker --node docker --platform linux/amd64 --driver docker-container $DOCKER_HOST
    - echo $PASSWORD | docker login --username $USER --password-stdin
    - docker buildx build --load --cache-from ezkrg/cache:bitlbee-libpurple --cache-to ezkrg/cache:bitlbee-libpurple -t ezkrg/bitlbee-libpurple:test .
    - docker push ezkrg/bitlbee-libpurple:test

  - name: release
    image: docker:stable
    environment:
      USER:
        from_secret: DHU
      PASSWORD:
        from_secret: DHP
      DOCKER_HOST: tcp://docker:2375
    commands:
    - docker tag ezkrg/bitlbee-libpurple:test ezkrg/bitlbee-libpurple:$DRONE_TAG
    - docker push ezkrg/bitlbee-libpurple:$DRONE_TAG
    - docker tag ezkrg/bitlbee-libpurple:test ezkrg/bitlbee-libpurple:latest
    - docker push ezkrg/bitlbee-libpurple:latest
    when:
      event:
      - tag

---
kind: signature
hmac: 278f412caada0637ac07903f423d5929b8fad6a58e38add30f4ddbed7e1d800d

...