Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
76 changes: 0 additions & 76 deletions .drone.windows.yml

This file was deleted.

90 changes: 89 additions & 1 deletion .drone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -267,6 +267,93 @@ trigger:
depends_on:
- testing

---
kind: pipeline
type: ssh
name: windows-1809-amd64

platform:
os: windows

server:
host: windows.1809.amd64.plugins.drone.ci
password:
from_secret: windows_password
user:
from_secret: windows_username

steps:
- name: build
commands:
- go build -o release/windows/amd64/drone-s3.exe
- docker login -u $env:USERNAME -p $env:PASSWORD
- |
if (Test-Path env:DRONE_SEMVER_SHORT) {
docker build -f docker/Dockerfile.windows.1809 -t plugins/s3:$env:DRONE_SEMVER_SHORT-windows-1809-amd64 .
docker push plugins/s3:$env:DRONE_SEMVER_SHORT-windows-1809-amd64
} else {
docker build -f docker/Dockerfile.windows.1809 -t plugins/s3:windows-1809-amd64 .
docker push plugins/s3:windows-1809-amd64
}
environment:
CGO_ENABLED: "0"
USERNAME:
from_secret: docker_username
PASSWORD:
from_secret: docker_password

trigger:
event:
- push
- tag

depends_on:
- testing

---
kind: pipeline
type: ssh
name: windows-1903-amd64

platform:
os: windows

server:
host: windows.1903.amd64.plugins.drone.ci
password:
from_secret: windows_password
user:
from_secret: windows_username

steps:
- name: build
commands:
- echo $env:DRONE_SEMVER_SHORT
- go build -o release/windows/amd64/drone-s3.exe
- docker login -u $env:USERNAME -p $env:PASSWORD
- |
if (Test-Path env:DRONE_SEMVER_SHORT) {
docker build -f docker/Dockerfile.windows.1903 -t plugins/s3:$env:DRONE_SEMVER_SHORT-windows-1903-amd64 .
docker push plugins/s3:$env:DRONE_SEMVER_SHORT-windows-1903-amd64
} else {
docker build -f docker/Dockerfile.windows.1903 -t plugins/s3:windows-1903-amd64 .
docker push plugins/s3:windows-1903-amd64
}
environment:
CGO_ENABLED: "0"
USERNAME:
from_secret: docker_username
PASSWORD:
from_secret: docker_password

trigger:
event:
- push
- tag

depends_on:
- testing

---
kind: pipeline
name: notifications
Expand Down Expand Up @@ -305,5 +392,6 @@ depends_on:
- linux-amd64
- linux-arm64
- linux-arm

- windows-1809-amd64
- windows-1903-amd64
...
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
# escape=`
FROM plugins/base:windows-amd64
FROM mcr.microsoft.com/windows/nanoserver:1803
USER ContainerAdministrator

ENV GODEBUG=netdns=go

LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
org.label-schema.name="Drone S3" `
org.label-schema.vendor="Drone.IO Community" `
org.label-schema.schema-version="1.0"

ADD release\drone-s3.exe c:\drone-s3.exe
ENTRYPOINT [ "c:\\drone-s3.exe" ]
ADD release/windows/amd64/drone-s3.exe C:/drone-s3.exe
ENTRYPOINT [ "C:\\drone-s3.exe" ]
13 changes: 13 additions & 0 deletions docker/Dockerfile.windows.1809
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# escape=`
FROM mcr.microsoft.com/windows/nanoserver:1809
USER ContainerAdministrator

ENV GODEBUG=netdns=go

LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
org.label-schema.name="Drone S3" `
org.label-schema.vendor="Drone.IO Community" `
org.label-schema.schema-version="1.0"

ADD release/windows/amd64/drone-s3.exe C:/drone-s3.exe
ENTRYPOINT [ "C:\\drone-s3.exe" ]
13 changes: 13 additions & 0 deletions docker/Dockerfile.windows.1903
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# escape=`
FROM mcr.microsoft.com/windows/nanoserver:1903
USER ContainerAdministrator

ENV GODEBUG=netdns=go

LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
org.label-schema.name="Drone S3" `
org.label-schema.vendor="Drone.IO Community" `
org.label-schema.schema-version="1.0"

ADD release/windows/amd64/drone-s3.exe C:/drone-s3.exe
ENTRYPOINT [ "C:\\drone-s3.exe" ]
13 changes: 13 additions & 0 deletions docker/Dockerfile.windows.1909
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# escape=`
FROM mcr.microsoft.com/windows/nanoserver:1909
USER ContainerAdministrator

ENV GODEBUG=netdns=go

LABEL maintainer="Drone.IO Community <drone-dev@googlegroups.com>" `
org.label-schema.name="Drone S3" `
org.label-schema.vendor="Drone.IO Community" `
org.label-schema.schema-version="1.0"

ADD release/windows/amd64/drone-s3.exe C:/drone-s3.exe
ENTRYPOINT [ "C:\\drone-s3.exe" ]
10 changes: 8 additions & 2 deletions docker/manifest.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,14 @@ manifests:
os: linux
variant: v7
-
image: plugins/s3:{{#if build.tag}}{{trimPrefix build.tag "v"}}-{{/if}}windows-amd64
image: plugins/s3:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1809-amd64
platform:
architecture: amd64
os: windows
variant: 1809
version: 1809
-
image: plugins/s3:{{#if build.tag}}{{trimPrefix "v" build.tag}}-{{/if}}windows-1903-amd64
platform:
architecture: amd64
os: windows
version: 1903