Skip to content
Merged
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
1 change: 1 addition & 0 deletions changelog.d/3-bug-fixes/WPB-5064
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Updated `demo-smtp` Helm chart from deprecated docker image namshi/smtp to ixdotai/smtp
19 changes: 17 additions & 2 deletions charts/demo-smtp/values.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
fullnameOverride: demo-smtp
replicaCount: 1
image: "quay.io/wire/namshi-smtp:aa63b8"
image: "quay.io/wire/ixdotai-smtp:v0.5.2"

service:
port: 25
Expand All @@ -15,7 +15,7 @@ resources:

# Some relevant environment options can be
# passed to the SMTP docker image, check
# https://hub.docker.com/r/namshi/smtp/
# https://github.com/ix-ai/smtp#readme
# for more details
# NOTE: Without an empty dictionary, you will
# see warnings when overriding envVars
Expand All @@ -24,3 +24,18 @@ envVars: {}
# envVars:
# RELAY_NETWORKS: ":x.y.z.w/16"
#
# PORT: "25"
# NET_DEV: eth0
# OTHER_HOSTNAMES: other.example.com
# DISABLE_IPV6: 1
# BIND_IP: 0.0.0.0
# BIND_IP6: ::0
# MAILNAME: mail.example.com
# DKIM_KEY_PATH: /etc/exim4/dkim.key
# KEY_PATH: /path/to/key.crt
# CERTIFICATE_PATH: /path/to/certificate.crt
# SMARTHOST_ADDRESS: mail.example.com
# SMARTHOST_PORT: "587"
# SMARTHOST_USER: exampleuser
# SMARTHOST_PASSWORD: secret
# SMARTHOST_ALIASES: "*.example.com"
2 changes: 1 addition & 1 deletion deploy/dockerephemeral/build/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ MINIO_COMMIT ?= 118270d76fc90f1e54cd9510cee9688bd717250b
CASSANDRA_COMMIT ?= 064fb4e2682bf9c1909e4cb27225fa74862c9086

smtp/Dockerfile:
git clone https://github.com/namshi/docker-smtp.git smtp
git clone https://github.com/ix-ai/smtp.git smtp
cd smtp && git reset --hard $(SMTP_COMMIT)

dynamodb_local/Dockerfile:
Expand Down
3 changes: 1 addition & 2 deletions deploy/dockerephemeral/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,7 @@ services:

basic_smtp: # needed for demo setup
container_name: demo_wire_smtp
# image: namshi/smtp
image: julialongtin/smtp:0.0.9
image: ixdotai/smtp:v0.5.2
ports:
- 127.0.0.1:2500:25
networks:
Expand Down
16 changes: 8 additions & 8 deletions docs/src/developer/reference/make-docker-and-qemu.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,10 @@ I build a docker image from a Dockerfile, and I build other images from slightly

##### What does this look like?

All of us on the team are using AMD64 based machines, so in this example, we're going to build one image for AMD64, and one for it's predecessor architecture, I386. We're going to build the SMTP server image we depend on, from https://hub.docker.com/r/namshi/smtp. We're going to use a known safe git revision, and use some minor GNU sed to generate architecture dependent Dockerfiles from the Dockerfile in git. Everyone should be able to do this on your laptops.
All of us on the team are using AMD64 based machines, so in this example, we're going to build one image for AMD64, and one for it's predecessor architecture, I386. We're going to build the SMTP server image we depend on, from https://hub.docker.com/r/ixdotai/smtp. We're going to use a known safe git revision, and use some minor GNU sed to generate architecture dependent Dockerfiles from the Dockerfile in git. Everyone should be able to do this on your laptops.

```bash
$ git clone https://github.com/namshi/docker-smtp.git smtp
$ git clone https://github.com/ix-ai/smtp.git smtp
Cloning into 'smtp'...
remote: Enumerating objects: 4, done.
remote: Counting objects: 100% (4/4), done.
Expand All @@ -53,8 +53,8 @@ remote: Total 126 (delta 0), reused 0 (delta 0), pack-reused 122
Receiving objects: 100% (126/126), 26.57 KiB | 269.00 KiB/s, done.
Resolving deltas: 100% (61/61), done.
$ cd smtp
$ git reset --hard 8ad8b849855be2cb6a11d97d332d27ba3e47483f
HEAD is now at 8ad8b84 Merge pull request #48 from zzzsochi/master
$ git reset --hard 04460f5a1e795f223ca6d8a711b6c743908c8fec
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wouldn't checking out a tag be more descriptive/natural?

HEAD is now at 04460f5 Merge branch '30-check-keys' into 'master'
$ cat Dockerfile | sed "s/^\(MAINTAINER\).*/\1 Julia Longtin \"julia.longtin@wire.com\"/" | sed "s=^\(FROM \)\(.*\)$=\1i386/\2=" > Dockerfile-386
$ cat Dockerfile | sed "s/^\(MAINTAINER\).*/\1 Julia Longtin \"julia.longtin@wire.com\"/" | sed "s=^\(FROM \)\(.*\)$=\1\2=" > Dockerfile-amd64
$ docker build -t julialongtin/smtp:0.0.9-amd64 -f Dockerfile-amd64
Expand Down Expand Up @@ -83,10 +83,10 @@ The sed commands used above accomplished two things. One, they changed out the M
Docker creates manifest files, and stores them in your local docker. I haven't found a good way to remove them, so instead, I add --amend, so that if one already exists, docker overwrites the locally stored file, instead of just telling you one already exists, and exiting with an error.

###### What does a manifest file look like?
to look at a manifest file (local or remote), use 'docker manifest inspect'. for example, here's the original namshi/smtp manifest.
to look at a manifest file (local or remote), use 'docker manifest inspect'. for example, here's the original ixdotai/smtp manifest.

```bash
$ docker manifest inspect namshi/smtp
$ docker manifest inspect ixdotai/smtp
{
"schemaVersion": 2,
"mediaType": "application/vnd.docker.distribution.manifest.v2+json",
Expand Down Expand Up @@ -125,7 +125,7 @@ $ docker manifest inspect namshi/smtp
}
```

This shows us the layers for the image, but says nothing about architecture, as namshi/smtp is shipped only for AMD64. note that there is nothing indicating this is for AMD64, so docker users on other architectures will end up downloading it, trying to run it, and having horrible crashes, instead of the smtp server they are looking for.
This shows us the layers for the image, but says nothing about architecture, as ixdotai/smtp is shipped only for AMD64. note that there is nothing indicating this is for AMD64, so docker users on other architectures will end up downloading it, trying to run it, and having horrible crashes, instead of the smtp server they are looking for.

Now, let's look at the manifest for the image we just uploaded:
```
Expand Down Expand Up @@ -836,7 +836,7 @@ There are a lot of these, of various complexities, so let's start with the simpl
```bash
$ cat Makefile | sed -n -E '/^(smtp|dynamo|minio)/{:n;N;s/\n\t/\n /;tn;p}'
smtp/Dockerfile:
git clone https://github.com/namshi/docker-smtp.git smtp
git clone https://github.com/ix-ai/smtp.git smtp
cd smtp && git reset --hard $(SMTP_COMMIT)

dynamodb_local/Dockerfile:
Expand Down