Skip to content

Commit

Permalink
Overwrite the hosts file to avoid getting random hostname
Browse files Browse the repository at this point in the history
Signed-off-by: Islam Amer <islam.amer@jollamobile.com>
  • Loading branch information
Islam Amer committed Dec 9, 2014
1 parent fab9b08 commit b9acdaa
Show file tree
Hide file tree
Showing 10 changed files with 57 additions and 0 deletions.
6 changes: 6 additions & 0 deletions sb2-tools-aarch64.spec
Expand Up @@ -76,6 +76,12 @@ mkdir -p %buildroot/etc/
touch %buildroot/etc/securetty
mkdir -p %buildroot/var/cache/ldconfig/
mkdir -p %buildroot/var/lock/subsys
#overwite hosts file to avoid getting a random hostname
cat > %{buildroot}/etc/hosts << EOF
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
EOF

shellquote()
{
for arg; do
Expand Down
6 changes: 6 additions & 0 deletions sb2-tools-armv6l.spec
Expand Up @@ -76,6 +76,12 @@ mkdir -p %buildroot/etc/
touch %buildroot/etc/securetty
mkdir -p %buildroot/var/cache/ldconfig/
mkdir -p %buildroot/var/lock/subsys
#overwite hosts file to avoid getting a random hostname
cat > %{buildroot}/etc/hosts << EOF
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
EOF

shellquote()
{
for arg; do
Expand Down
6 changes: 6 additions & 0 deletions sb2-tools-armv7hl.spec
Expand Up @@ -76,6 +76,12 @@ mkdir -p %buildroot/etc/
touch %buildroot/etc/securetty
mkdir -p %buildroot/var/cache/ldconfig/
mkdir -p %buildroot/var/lock/subsys
#overwite hosts file to avoid getting a random hostname
cat > %{buildroot}/etc/hosts << EOF
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
EOF

shellquote()
{
for arg; do
Expand Down
6 changes: 6 additions & 0 deletions sb2-tools-armv7l.spec
Expand Up @@ -76,6 +76,12 @@ mkdir -p %buildroot/etc/
touch %buildroot/etc/securetty
mkdir -p %buildroot/var/cache/ldconfig/
mkdir -p %buildroot/var/lock/subsys
#overwite hosts file to avoid getting a random hostname
cat > %{buildroot}/etc/hosts << EOF
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
EOF

shellquote()
{
for arg; do
Expand Down
6 changes: 6 additions & 0 deletions sb2-tools-armv7thl.spec
Expand Up @@ -76,6 +76,12 @@ mkdir -p %buildroot/etc/
touch %buildroot/etc/securetty
mkdir -p %buildroot/var/cache/ldconfig/
mkdir -p %buildroot/var/lock/subsys
#overwite hosts file to avoid getting a random hostname
cat > %{buildroot}/etc/hosts << EOF
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
EOF

shellquote()
{
for arg; do
Expand Down
6 changes: 6 additions & 0 deletions sb2-tools-armv7tnhl.spec
Expand Up @@ -76,6 +76,12 @@ mkdir -p %buildroot/etc/
touch %buildroot/etc/securetty
mkdir -p %buildroot/var/cache/ldconfig/
mkdir -p %buildroot/var/lock/subsys
#overwite hosts file to avoid getting a random hostname
cat > %{buildroot}/etc/hosts << EOF
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
EOF

shellquote()
{
for arg; do
Expand Down
6 changes: 6 additions & 0 deletions sb2-tools-i486.spec
Expand Up @@ -76,6 +76,12 @@ mkdir -p %buildroot/etc/
touch %buildroot/etc/securetty
mkdir -p %buildroot/var/cache/ldconfig/
mkdir -p %buildroot/var/lock/subsys
#overwite hosts file to avoid getting a random hostname
cat > %{buildroot}/etc/hosts << EOF
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
EOF

shellquote()
{
for arg; do
Expand Down
6 changes: 6 additions & 0 deletions sb2-tools-mipsel.spec
Expand Up @@ -76,6 +76,12 @@ mkdir -p %buildroot/etc/
touch %buildroot/etc/securetty
mkdir -p %buildroot/var/cache/ldconfig/
mkdir -p %buildroot/var/lock/subsys
#overwite hosts file to avoid getting a random hostname
cat > %{buildroot}/etc/hosts << EOF
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
EOF

shellquote()
{
for arg; do
Expand Down
3 changes: 3 additions & 0 deletions sb2-tools-template.changes
@@ -1,3 +1,6 @@
* Wed Dec 10 2014 Islam Amer <islam.amer@jolla.com> - 1.0
- Overwrite the hosts file to avoid getting a random hostname

* Mon Aug 25 2014 Islam Amer <islam.amer@jolla.com> - 1.0
- New util-linux splits off libmount and libsmartcols so add them explicitly

Expand Down
6 changes: 6 additions & 0 deletions sb2-tools-template.spec
Expand Up @@ -76,6 +76,12 @@ mkdir -p %buildroot/etc/
touch %buildroot/etc/securetty
mkdir -p %buildroot/var/cache/ldconfig/
mkdir -p %buildroot/var/lock/subsys
#overwite hosts file to avoid getting a random hostname
cat > %{buildroot}/etc/hosts << EOF
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
EOF

shellquote()
{
for arg; do
Expand Down

0 comments on commit b9acdaa

Please sign in to comment.